/linux/drivers/md/bcache/ |
H A D | bset.c | 1 // SPDX-License-Identifier: GPL-2.0 23 struct bkey *k, *next; in bch_dump_bset() local 25 for (k = i->start; k < bset_bkey_last(i); k = next) { in bch_dump_bset() 26 next = bkey_next(k); in bch_dump_bset() 29 (unsigned int) ((u64 *) k - i->d), i->keys); in bch_dump_bset() 31 if (b->ops->key_dump) in bch_dump_bset() 32 b->ops->key_dump(b, k); in bch_dump_bset() 34 pr_cont("%llu:%llu\n", KEY_INODE(k), KEY_OFFSET(k)); in bch_dump_bset() 37 bkey_cmp(k, b->ops->is_extents ? in bch_dump_bset() 48 for (i = 0; i <= b->nsets; i++) in bch_dump_bucket() [all …]
|
/linux/drivers/video/logo/ |
H A D | pnmtologo.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * Convert a logo in ASCII PNM format to C source suitable for inclusion in 6 * (C) Copyright 2001-2003 by Geert Uytterhoeven <geert@linux-m68k.org> 100 val = 10*val+c-'0'; in get_number() 124 unsigned int i, j; in read_image() local 150 "Use pnmnoraw(1) to convert it to ASCII PNM\n", filename); in read_image() 174 for (j = 0; j < logo_width; j++) in read_image() 175 logo_data[i][j].red = logo_data[i][j].green = in read_image() 176 logo_data[i][j].blue = 255*(1-get_number(fp)); in read_image() 183 for (j = 0; j < logo_width; j++) in read_image() [all …]
|
/linux/drivers/gpu/drm/amd/display/dc/dml/dcn32/ |
H A D | display_mode_vba_32.c | 4 * Permission is hereby granted, free of charge, to any person obtaining a 6 * to deal in the Software without restriction, including without limitation 7 * the rights to use, copy, modify, merge, publish, distribute, sublicense, 8 * and/or sell copies of the Software, and to permit persons to whom the 9 * Software is furnished to do so, subject to the following conditions: 15 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 41 dml32_CalculateMaxDETAndMinCompressedBufferSize(mode_lib->vba.ConfigReturnBufferSizeInKByte, in dml32_recalculate() 42 mode_lib->vba.ROBBufferSizeInKByte, in dml32_recalculate() 44 false, //mode_lib->vba.override_setting.nomDETInKByteOverrideEnable, in dml32_recalculate() 45 0, //mode_lib->vba.override_setting.nomDETInKByteOverrideValue, in dml32_recalculate() [all …]
|
/linux/lib/ |
H A D | bch.c | 14 * this program; if not, write to the Free Software Foundation, Inc., 51 15 * Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 24 * Bose-Chaudhuri-Hocquenghem (BCH) codes. 26 * Call bch_init to get a pointer to a newly allocated bch_control structure for 30 * Call bch_encode to compute and store ecc parity bytes to a given buffer. 31 * Call bch_decode to detect and locate errors in received data. 34 * to bch_decode in order to skip certain steps. See bch_decode() documentation 37 * Option CONFIG_BCH_CONST_PARAMS can be used to force fixed values of 39 * better (up to 2x) encoding performance. Using this option makes sense when 50 * b. Error locator polynomial computation using Berlekamp-Massey algorithm [all …]
|
H A D | oid_registry.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 22 * look_up_OID - Find an OID registration for the specified data 31 unsigned i, j, k, hash; in look_up_OID() local 35 hash = datasize - 1; in look_up_OID() 47 k = OID__NR; in look_up_OID() 48 while (i < k) { in look_up_OID() 49 j = (i + k) / 2; in look_up_OID() 51 xhash = oid_search_table[j].hash; in look_up_OID() 53 k = j; in look_up_OID() 57 i = j + 1; in look_up_OID() [all …]
|
/linux/drivers/platform/x86/ |
H A D | uv_sysfs.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 20 #define INVALID_CNODE -1 33 static signed short uv_master_nasid = -1; 59 return -1; in ordinal_to_nasid() 77 return -1; in location_to_bpos() 90 if (!obj->f.fields.this_part && !obj->f.fields.is_shared) in cache_obj_to_cnode() 93 if (location_to_bpos(obj->location, &obj_rack, &obj_slot, &obj_blade)) in cache_obj_to_cnode() 94 return -1; in cache_obj_to_cnode() 102 prev_obj_to_cnode[obj->id] = cnode; in cache_obj_to_cnode() 123 return sysfs_emit(buf, "%s\n", hub_info->name); in hub_name_show() [all …]
|
/linux/drivers/media/platform/verisilicon/ |
H A D | hantro_vp8.c | 1 // SPDX-License-Identifier: GPL-2.0 35 * filter taps taken to 7-bit precision, 36 * reference RFC6386#Page-16, filters[8][6] 40 { 0, -6, 123, 12, -1, 0 }, 41 { 2, -11, 108, 36, -8, 1 }, 42 { 0, -9, 93, 50, -6, 0 }, 43 { 3, -16, 77, 77, -16, 3 }, 44 { 0, -6, 50, 93, -9, 0 }, 45 { 1, -8, 36, 108, -11, 2 }, 46 { 0, -1, 12, 123, -6, 0 } [all …]
|
H A D | hantro_vp9.c | 1 // SPDX-License-Identifier: GPL-2.0 9 #include <media/v4l2-mem2mem.h> 29 size = 24 * height32 * (MAX_NUM_TILE_COLS - 1); /* luma: 8, chroma: 8 + 8 */ in hantro_vp9_tile_filter_size() 41 return 16 * (height32 / 4) * (MAX_NUM_TILE_COLS - 1); in hantro_vp9_bsd_control_size() 71 static void *get_coeffs_arr(struct symbol_counts *cnts, int i, int j, int k, int l, int m) in get_coeffs_arr() argument 74 return &cnts->count_coeffs[j][k][l][m]; in get_coeffs_arr() 77 return &cnts->count_coeffs8x8[j][k][l][m]; in get_coeffs_arr() 80 return &cnts->count_coeffs16x16[j][k][l][m]; in get_coeffs_arr() 83 return &cnts->count_coeffs32x32[j][k][l][m]; in get_coeffs_arr() 88 static void *get_eobs1(struct symbol_counts *cnts, int i, int j, int k, int l, int m) in get_eobs1() argument [all …]
|
/linux/drivers/gpu/drm/amd/display/dc/dml/calcs/ |
H A D | dcn_calc_auto.c | 4 * Permission is hereby granted, free of charge, to any person obtaining a 6 * to deal in the Software without restriction, including without limitation 7 * the rights to use, copy, modify, merge, publish, distribute, sublicense, 8 * and/or sell copies of the Software, and to permit persons to whom the 9 * Software is furnished to do so, subject to the following conditions: 15 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 32 * This file is gcc-parseable HW gospel, coming straight from HW engineers. 34 * It doesn't adhere to Linux kernel style and sometimes will do things in odd 36 * remain as-is as it provides us with a guarantee from HW that it is correct. 42 int k; in scaler_settings_calculation() local [all …]
|
/linux/lib/raid6/ |
H A D | mktables.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 2 /* -*- linux-c -*- ------------------------------------------------------- * 4 * Copyright 2002-2007 H. Peter Anvin - All Rights Reserved 6 * ----------------------------------------------------------------------- */ 11 * Make RAID-6 tables. This is a host user space program to be run at 55 int i, j, k; in main() local 70 for (j = 0; j < 256; j += 8) { in main() 72 for (k = 0; k < 8; k++) in main() 73 printf("0x%02x,%c", gfmul(i, j + k), in main() 74 (k == 7) ? '\n' : ' '); in main() [all …]
|
/linux/sound/soc/sdca/ |
H A D | sdca_regmap.c | 1 // SPDX-License-Identifier: GPL-2.0 7 * https://www.mipi.org/mipi-sdca-v1-0-download 25 for (i = 0; i < function->num_entities; i++) in function_find_entity() 26 if (SDW_SDCA_CTL_ENT(reg) == function->entities[i].id) in function_find_entity() 27 return &function->entities[i]; in function_find_entity() 37 for (i = 0; i < entity->num_controls; i++) { in entity_find_control() 38 if (SDW_SDCA_CTL_CSEL(reg) == entity->controls[i].sel) in entity_find_control() 39 return &entity->controls[i]; in entity_find_control() 58 * sdca_regmap_readable - return if a given SDCA Control is readable 59 * @function: Pointer to the Function information. [all …]
|
/linux/drivers/gpu/drm/amd/display/dc/dml/ |
H A D | display_mode_vba.c | 4 * Permission is hereby granted, free of charge, to any person obtaining a 6 * to deal in the Software without restriction, including without limitation 7 * the rights to use, copy, modify, merge, publish, distribute, sublicense, 8 * and/or sell copies of the Software, and to permit persons to whom the 9 * Software is furnished to do so, subject to the following conditions: 15 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 33 * This file is gcc-parsable HW gospel, coming straight from HW engineers. 35 * It doesn't adhere to Linux kernel style and sometimes will do things in odd 37 * remain as-is as it provides us with a guarantee from HW that it is correct. 57 bool need_recalculate = memcmp(&mode_lib->soc, &mode_lib->vba.soc, sizeof(mode_lib->vba.soc)) != 0 in dml_get_voltage_level() [all …]
|
/linux/drivers/net/ethernet/freescale/fman/ |
H A D | fman_sp.c | 1 // SPDX-License-Identifier: BSD-3-Clause OR GPL-2.0-or-later 3 * Copyright 2008 - 2015 Freescale Semiconductor Inc. 15 int i = 0, j = 0, k = 0; in fman_sp_set_buf_pools_in_asc_order_of_buf_sizes() local 18 * to an ordered local array in fman_sp_set_buf_pools_in_asc_order_of_buf_sizes() 20 for (i = 0; i < fm_ext_pools->num_of_pools_used; i++) { in fman_sp_set_buf_pools_in_asc_order_of_buf_sizes() 22 buf_size = fm_ext_pools->ext_buf_pool[i].size; in fman_sp_set_buf_pools_in_asc_order_of_buf_sizes() 24 /* keep sizes in an array according to poolId in fman_sp_set_buf_pools_in_asc_order_of_buf_sizes() 27 sizes_array[fm_ext_pools->ext_buf_pool[i].id] = buf_size; in fman_sp_set_buf_pools_in_asc_order_of_buf_sizes() 29 /* save poolId in an ordered array according to size */ in fman_sp_set_buf_pools_in_asc_order_of_buf_sizes() 30 for (j = 0; j <= i; j++) { in fman_sp_set_buf_pools_in_asc_order_of_buf_sizes() [all …]
|
/linux/kernel/ |
H A D | range.c | 1 // SPDX-License-Identifier: GPL-2.0 54 (nr_range - (i + 1)) * sizeof(range[i])); in add_range_with_merge() 55 range[nr_range - 1].start = 0; in add_range_with_merge() 56 range[nr_range - 1].end = 0; in add_range_with_merge() 57 nr_range--; in add_range_with_merge() 58 i--; in add_range_with_merge() 61 /* Need to add it: */ in add_range_with_merge() 67 int i, j; in subtract_range() local 72 for (j = 0; j < az; j++) { in subtract_range() 73 if (!range[j].end) in subtract_range() [all …]
|
/linux/lib/reed_solomon/ |
H A D | decode_rs.c | 1 // SPDX-License-Identifier: GPL-2.0 8 * Adaption to the kernel by Thomas Gleixner (tglx@linutronix.de) 13 struct rs_codec *rs = rsc->codec; 15 int i, j, r, k, pad; variable 16 int nn = rs->nn; 17 int nroots = rs->nroots; 18 int fcr = rs->fcr; 19 int prim = rs->prim; 20 int iprim = rs->iprim; 21 uint16_t *alpha_to = rs->alpha_to; [all …]
|
/linux/drivers/acpi/acpica/ |
H A D | utownerid.c | 1 // SPDX-License-Identifier: BSD-3-Clause OR GPL-2.0 4 * Module Name: utownerid - Support for Table/Method Owner IDs 19 * PARAMETERS: owner_id - Where the new owner ID is returned 23 * DESCRIPTION: Allocate a table or method owner ID. The owner ID is used to 24 * track objects created by the table or method, to be deleted 31 u32 j; in acpi_ut_allocate_owner_id() local 32 u32 k; in acpi_ut_allocate_owner_id() local 37 /* Guard against multiple allocations of ID to the same location */ in acpi_ut_allocate_owner_id() 55 * may have to be scanned twice. in acpi_ut_allocate_owner_id() 57 for (i = 0, j = acpi_gbl_last_owner_id_index; in acpi_ut_allocate_owner_id() [all …]
|
/linux/drivers/usb/host/ |
H A D | xhci-mtk-sch.c | 1 // SPDX-License-Identifier: GPL-2.0 14 #include "xhci-mtk.h" 18 /* table 5-5. High-speed Isoc Transaction Limits in usb_20 spec */ 28 * max number of microframes for split transfer, assume extra-cs budget is 0 55 return "Can't schedule Start-Split in Y6"; in sch_error_string() 57 return "Can't find a suitable Start-Split location"; in sch_error_string() 59 return "The last Complete-Split is greater than 7"; in sch_error_string() 63 return "FIXME, to be resolved"; in sch_error_string() 78 struct usb_endpoint_descriptor *epd = &ep->desc; in decode_ep() 94 usb_endpoint_maxp(epd), epd->bInterval, interval, unit); in decode_ep() [all …]
|
/linux/drivers/staging/media/sunxi/cedrus/ |
H A D | cedrus_h265.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 13 #include <media/videobuf2-dma-contig.h> 22 * implementations, that were initially exposed in libvdpau-sunxi. 23 * Subsequent BSP implementations seem to double the neighbor info buffer size 24 * for the H6 SoC, which may be related to 10 bit H265 support. 48 * Vendor library additionally aligns width and height to 16, in cedrus_h265_2bit_size() 49 * but all capture formats are already aligned to that anyway, in cedrus_h265_2bit_size() 59 struct cedrus_dev *dev = ctx->dev; in cedrus_h265_irq_status() 74 struct cedrus_dev *dev = ctx->dev; in cedrus_h265_irq_clear() 81 struct cedrus_dev *dev = ctx->dev; in cedrus_h265_irq_disable() [all …]
|
/linux/arch/m68k/fpsp040/ |
H A D | srem_mod.S | 9 | ----- 10 | Double-extended value Y is pointed to by address in register 11 | A0. Double-extended value X is located in -12(A0). The values 17 | ------ 21 | --------- 28 | Step 2. Set L := expo(X)-expo(Y), k := 0, Q := 0. 30 | R := X, go to Step 4. 32 | R := 2^(-L)X, j := L. 36 | 3.1 If R = Y, go to Step 9. 37 | 3.2 If R > Y, then { R := R - Y, Q := Q + 1} [all …]
|
/linux/drivers/gpu/drm/amd/display/dc/dcn10/ |
H A D | dcn10_cm_common.c | 4 * Permission is hereby granted, free of charge, to any person obtaining a 6 * to deal in the Software without restriction, including without limitation 7 * the rights to use, copy, modify, merge, publish, distribute, sublicense, 8 * and/or sell copies of the Software, and to permit persons to whom the 9 * Software is furnished to do so, subject to the following conditions: 15 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 39 reg->shifts.field_name, reg->masks.field_name 49 for (cur_csc_reg = reg->csc_c11_c12; in cm_helper_program_color_matrices() 50 cur_csc_reg <= reg->csc_c33_c34; in cm_helper_program_color_matrices() 72 for (cur_csc_reg = reg->csc_c11_c12; in cm_helper_read_color_matrices() [all …]
|
/linux/lib/crypto/ |
H A D | gf128mul.c | 1 /* gf128mul.c - GF(2^128) multiplication functions 17 --------------------------------------------------------------------------- 32 3. the copyright holder's name is not used to endorse products 42 in respect of its properties, including, but not limited to, correctness 44 --------------------------------------------------------------------------- 95 * 16-bit value that must be XOR-ed into the low-degree end of the 96 * product to reduce it modulo the polynomial x^128 + x^7 + x^2 + x + 1. 99 * the "be" convention where the highest-order bit is the coefficient of 100 * the highest-degree polynomial term, and one for the "le" convention 101 * where the highest-order bit is the coefficient of the lowest-degree [all …]
|
/linux/sound/pci/emu10k1/ |
H A D | voice.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 4 * Lee Revell <rlrevell@joe-job.com> 8 * Routines for control of EMU10K1 chips - voice manager 19 * hardware requires stereo interleaved voices be aligned to an even/odd 21 * --rlrevel 28 int i, j, k, skip; voice_alloc() local 110 for (int j = 0; j < count; j++) snd_emu10k1_voice_alloc() local [all...] |
/linux/drivers/ata/pata_parport/ |
H A D | friq.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 5 * friq.c is a low-level protocol driver for the Freecom "IQ" 10 * CD-ROM drive. It is also used in LS-120 drives by 13 * The battery powered drive requires software support to 14 * control the power to the drive. This module enables the 17 * the friq module is built in to the kernel, the power 19 * used to conserve battery power. 41 * cont = 0 - access the IDE register file 42 * cont = 1 - access the IDE command set 71 int h, l, k, ph; in friq_read_block_int() local [all …]
|
/linux/drivers/gpu/drm/nouveau/nvkm/subdev/fb/ |
H A D | nv30.c | 5 * Permission is hereby granted, free of charge, to any person obtaining 7 * "Software"), to deal in the Software without restriction, including 8 * without limitation the rights to use, copy, modify, merge, publish, 9 * distribute, sublicense, and/or sell copies of the Software, and to 10 * permit persons to whom the Software is furnished to do so, subject to 18 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 35 tile->addr = (0 << 4); in nv30_fb_tile_init() 37 if (fb->func->tile.comp) /* z compression */ in nv30_fb_tile_init() 38 fb->func->tile.comp(fb, i, size, flags, tile); in nv30_fb_tile_init() 39 tile->addr = (1 << 4); in nv30_fb_tile_init() [all …]
|
/linux/tools/lib/perf/ |
H A D | cpumap.c | 1 // SPDX-License-Identifier: GPL-2.0-only 20 RC_CHK_ACCESS(map)->nr = nr_cpus; in perf_cpu_map__set_nr() 33 cpus->nr = nr_cpus; in perf_cpu_map__alloc() 34 refcount_set(&cpus->refcnt, 1); in perf_cpu_map__alloc() 44 RC_CHK_ACCESS(cpus)->map[0].cpu = -1; in perf_cpu_map__new_any_cpu() 98 RC_CHK_ACCESS(cpus)->map[i].cpu = i; in cpu_map__new_sysconf() 132 return cpu_a->cpu - cpu_b->cpu; in cmp_cpu() 137 return RC_CHK_ACCESS(cpus)->map[idx]; in __perf_cpu_map__cpu() 144 int i, j; in cpu_map__trim_new() local 147 memcpy(RC_CHK_ACCESS(cpus)->map, tmp_cpus, payload_size); in cpu_map__trim_new() [all …]
|