/linux/drivers/media/common/v4l2-tpg/ |
H A D | v4l2-tpg-core.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * v4l2-tpg-core.c - Test Pattern Generator 12 #include <media/tpg/v4l2-tpg.h> 54 * Sine table: sin[0] = 127 * sin(-180 degrees) 59 0, -4, -7, -11, -13, -18, -20, -22, -26, -29, -33, -35, -37, -41, -43, -48, 60 -50, -52, -56, -58, -62, -63, -65, -69, -71, -75, -76, -78, -82, -83, -87, -88, 61 -90, -93, -94, -97, -99, -101, -103, -104, -107, -108, -110, -111, -112, -114, -115, -117, 62 -118, -119, -120, -121, -122, -123, -123, -124, -125, -125, -126, -126, -127, -127, -127, -127, 63 -127, -127, -127, -127, -126, -126, -125, -125, -124, -124, -123, -122, -121, -120, -119, -118, 64 -117, -116, -114, -113, -111, -110, -109, -107, -105, -103, -101, -100, -97, -96, -93, -91, [all …]
|
/linux/drivers/gpu/ipu-v3/ |
H A D | ipu-ic-csc.c | 1 // SPDX-License-Identifier: GPL-2.0+ 11 #include "ipu-prv.h" 24 .offset = { 0, 0, 0, }, 29 * RGB full-range to RGB limited-range 41 .offset = { 64, 64, 64, }, 46 * RGB limited-range to RGB full-range 48 * R_full = 1.1644 * (R_lim - 16) 49 * G_full = 1.1644 * (G_lim - 16) 50 * B_full = 1.1644 * (B_lim - 16) 58 .offset = { -37, -37, -37, }, [all …]
|
H A D | ipu-cpmem.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 4 * Copyright 2005-2012 Freescale Semiconductor, Inc. All Rights Reserved. 11 #include "ipu-prv.h" 95 struct ipu_cpmem *cpmem = ch->ipu->cpmem_priv; in ipu_get_cpmem() 97 return cpmem->base + ch->num; in ipu_get_cpmem() 108 u32 mask = (1 << size) - 1; in ipu_ch_param_write_field() 113 val = readl(&base->word[word].data[i]); in ipu_ch_param_write_field() 116 writel(val, &base->word[word].data[i]); in ipu_ch_param_write_field() 118 if ((bit + size - 1) / 32 > i) { in ipu_ch_param_write_field() 119 val = readl(&base->word[word].data[i + 1]); in ipu_ch_param_write_field() [all …]
|
/linux/drivers/gpu/drm/i915/selftests/ |
H A D | i915_vma.c | 43 if (vma->vm != ctx->vm) { in assert_vma() 48 if (vma->size != obj->base.size) { in assert_vma() 50 vma->size, obj->base.size); in assert_vma() 54 if (vma->gtt_view.type != I915_GTT_VIEW_NORMAL) { in assert_vma() 56 vma->gtt_view.type); in assert_vma() 76 if (vma->vm != vm) { in checked_vma_instance() 78 vma->vm, vm); in checked_vma_instance() 90 return ERR_PTR(-EINVAL); in checked_vma_instance() 93 if (i915_vma_compare(vma, vma->vm, in checked_vma_instance() 94 i915_vma_is_ggtt(vma) ? &vma->gtt_view : NULL)) { in checked_vma_instance() [all …]
|
/linux/arch/x86/entry/syscalls/ |
H A D | Makefile | 1 # SPDX-License-Identifier: GPL-2.0 6 $(shell mkdir -p $(out) $(uapi)) 13 offset := macro 17 cmd_syshdr = $(CONFIG_SHELL) $(syshdr) --abis $(abis) --emit-nr \ 18 $(if $(offset),--offset $(offset)) \ 19 $(if $(prefix),--prefix $(prefix)) \ 22 cmd_systbl = $(CONFIG_SHELL) $(systbl) --abis $(abis) $< $@ 25 cmd_hypercalls = $(CONFIG_SHELL) '$<' $@ $(filter-out $<, $(real-prereqs)) 37 $(uapi)/unistd_x32.h: offset := __X32_SYSCALL_BIT macro 60 $(out)/xen-hypercalls.h: $(srctree)/scripts/xen-hypercalls.sh FORCE [all …]
|
/linux/drivers/gpu/drm/vkms/ |
H A D | vkms_formats.c | 1 // SPDX-License-Identifier: GPL-2.0+ 13 * packed_pixels_offset() - Get the offset of the block containing the pixel at coordinates x/y 17 * @y: The y coordinate of the wanted pixel in the buffer 19 * @offset: The returned offset inside the buffer of the block 21 * @rem_y: The returned Y coordinate of the requested pixel in the block 24 * pixels are not individually addressable. This function return 3 values: the offset of the 26 * For example, if the format is DRM_FORMAT_R1 and the requested coordinate is 13,5, the offset 32 static void packed_pixels_offset(const struct vkms_frame_info *frame_info, int x, int y, in packed_pixels_offset() argument 33 int plane_index, int *offset, int *rem_x, int *rem_y) in packed_pixels_offset() argument 35 struct drm_framebuffer *fb = frame_info->fb; in packed_pixels_offset() [all …]
|
/linux/drivers/gpu/drm/vmwgfx/ |
H A D | vmw_surface_cache.h | 1 /* SPDX-License-Identifier: GPL-2.0 OR MIT */ 4 * Copyright (c) 2021-2024 Broadcom. All Rights Reserved. The term 43 return (tmp > (uint64_t) ((u32) -1)) ? (u32) -1 : tmp; in clamped_umul32() 47 * vmw_surface_get_desc - Look up the appropriate SVGA3dSurfaceDesc for the 60 * vmw_surface_get_mip_size - Given a base level size and the mip level, 80 block_size->width = __KERNEL_DIV_ROUND_UP(pixel_size->width, in vmw_surface_get_size_in_blocks() 81 desc->blockSize.width); in vmw_surface_get_size_in_blocks() 82 block_size->height = __KERNEL_DIV_ROUND_UP(pixel_size->height, in vmw_surface_get_size_in_blocks() 83 desc->blockSize.height); in vmw_surface_get_size_in_blocks() 84 block_size->depth = __KERNEL_DIV_ROUND_UP(pixel_size->depth, in vmw_surface_get_size_in_blocks() [all …]
|
/linux/drivers/gpu/drm/i915/display/ |
H A D | skl_universal_plane.c | 1 // SPDX-License-Identifier: MIT 238 struct intel_display *display = &i915->display; in icl_nv12_y_plane_mask() 277 const struct drm_framebuffer *fb = plane_state->hw.fb; in glk_plane_ratio() 279 if (fb->format->cpp[0] == 8) { in glk_plane_ratio() 304 const struct drm_framebuffer *fb = plane_state->hw.fb; in skl_plane_ratio() 306 if (fb->format->cpp[0] == 8) { in skl_plane_ratio() 330 int cpp = fb->format->cpp[color_plane]; in skl_plane_max_width() 332 switch (fb->modifier) { in skl_plane_max_width() 338 * - Ytile (already limited to 4k) in skl_plane_max_width() 339 * - FP16 (already limited to 4k) in skl_plane_max_width() [all …]
|
H A D | intel_fb.c | 1 // SPDX-License-Identifier: MIT 6 #include <linux/dma-fence.h> 7 #include <linux/dma-resv.h> 23 #define check_array_bounds(i915, a, i) drm_WARN_ON(&(i915)->drm, (i) >= ARRAY_SIZE(a)) 28 * the cache-line pairs. The compression state of the cache-line pair 29 * is specified by 2 bits in the CCS. Each CCS cache-line represents 30 * an area on the main surface of 16 x16 sets of 128 byte Y-tiled 31 * cache-line-pairs. CCS is always Y tiled." 59 * Gen-12 compression uses 4 bits of CCS data for each cache line pair in the 60 * main surface. And each 64B CCS cache line represents an area of 4x1 Y-tiles [all …]
|
/linux/Documentation/devicetree/bindings/input/touchscreen/ |
H A D | edt-ft5x06.yaml | 1 # SPDX-License-Identifier: GPL-2.0 3 --- 4 $id: http://devicetree.org/schemas/input/touchscreen/edt-ft5x06.yaml# 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 7 title: FocalTech EDT-FT5x06 Polytouch 18 - Dmitry Torokhov <dmitry.torokhov@gmail.com> 21 - $ref: touchscreen.yaml# 22 - if: 27 - evervision,ev-ft5726 31 offset-x: true [all …]
|
/linux/drivers/media/platform/amphion/ |
H A D | vpu_malone.c | 1 // SPDX-License-Identifier: GPL-2.0 3 * Copyright 2020-2021 NXP 16 #include <media/videobuf2-v4l2.h> 17 #include <media/videobuf2-dma-contig.h> 49 //x means source data , y means destination data 50 #define STREAM_CONFIG_FORMAT_SET(x, y) CONFIG_SET(x, y, 0, 0x0000000F) argument 51 #define STREAM_CONFIG_STRBUFIDX_SET(x, y) CONFIG_SET(x, y, 8, 0x00000300) argument 52 #define STREAM_CONFIG_NOSEQ_SET(x, y) CONFIG_SET(x, y, 10, 0x00000400) argument 53 #define STREAM_CONFIG_DEBLOCK_SET(x, y) CONFIG_SET(x, y, 11, 0x00000800) argument 54 #define STREAM_CONFIG_DERING_SET(x, y) CONFIG_SET(x, y, 12, 0x00001000) argument [all …]
|
/linux/arch/m68k/mac/ |
H A D | misc.c | 1 // SPDX-License-Identifier: GPL-2.0 3 * Miscellaneous Mac68K-specific stuff 31 * Offset between Unix time (1970-based) and Mac time (1904-based). Cuda and PMU 33 * need to be changed to interpret wrapped times as post-2040. 42 static unsigned char cuda_pram_read_byte(int offset) in cuda_pram_read_byte() argument 47 (offset >> 8) & 0xFF, offset & 0xFF) < 0) in cuda_pram_read_byte() 54 static void cuda_pram_write_byte(unsigned char data, int offset) in cuda_pram_write_byte() argument 59 (offset >> 8) & 0xFF, offset & 0xFF, data) < 0) in cuda_pram_write_byte() 67 static unsigned char pmu_pram_read_byte(int offset) in pmu_pram_read_byte() argument 72 offset & 0xFF, 1) < 0) in pmu_pram_read_byte() [all …]
|
/linux/drivers/gpu/drm/omapdrm/ |
H A D | tcm-sita.c | 1 // SPDX-License-Identifier: GPL-2.0-only 9 * Copyright (C) 2012 Texas Instruments Incorporated - https://www.ti.com/ 50 *pos = num_bits - w; in r2l_b2t_1d() 55 if (bit - *pos >= w) { in r2l_b2t_1d() 62 search_count = num_bits - bit + w; in r2l_b2t_1d() 63 *pos = bit - w; in r2l_b2t_1d() 66 return (area_found) ? 0 : -ENOMEM; in r2l_b2t_1d() 72 * a = align in slots (mask, 2^n-1, 0 is unaligned) 73 * offset = offset in bytes from 4KiB 79 static int l2r_t2b(u16 w, u16 h, u16 a, s16 offset, in l2r_t2b() argument [all …]
|
H A D | tcm.h | 45 u16 y; member 60 unsigned int y_offset; /* offset to use for y coordinates */ 68 s16 offset, u16 slot_bytes, 99 * @return 0 on success, non-0 error value on error. The call 101 * even on failure. Some error codes: -ENODEV: invalid 107 tcm->deinit(tcm); in tcm_deinit() 116 * @param align Alignment requirement for top-left corner of area. Not 120 * @param offset Offset requirement, in bytes. This is the offset 125 * @return 0 on success. Non-0 error code on failure. Also, 127 * failure. Some error codes: -ENODEV: invalid manager, [all …]
|
/linux/tools/testing/selftests/powerpc/stringloops/ |
H A D | memcmp.c | 1 // SPDX-License-Identifier: GPL-2.0 32 vmx_count--; in exit_vmx_ops() 40 unsigned long offset, size; in test_one() local 42 for (offset = 0; offset < max_offset; offset++) { in test_one() 43 for (size = size_start; size < (max_size - offset); size++) { in test_one() 44 int x, y; in test_one() local 47 y = memcmp(s1+offset, s2+offset, size); in test_one() 48 x = test_memcmp(s1+offset, s2+offset, size); in test_one() 50 if (((x ^ y) < 0) && /* Trick to compare sign */ in test_one() 51 ((x | y) != 0)) { /* check for zero */ in test_one() [all …]
|
H A D | strlen.c | 1 // SPDX-License-Identifier: GPL-2.0 17 unsigned long offset; in test_one() local 19 for (offset = 0; offset < SIZE; offset++) { in test_one() 20 int x, y; in test_one() local 23 y = strlen(s + offset); in test_one() 24 x = test_strlen(s + offset); in test_one() 26 if (x != y) { in test_one() 27 printf("strlen() returned %d, should have returned %d (%p offset %ld)\n", x, y, s, offset); in test_one() 29 for (i = offset; i < SIZE; i++) in test_one() 48 …len %3.3d : time = %.6f\n", test_strlen(s), ts_end.tv_sec - ts_start.tv_sec + (ts_end.tv_nsec - ts… in bench_test() [all …]
|
/linux/drivers/hid/bpf/progs/ |
H A D | Wacom__ArtPen.bpf.c | 1 // SPDX-License-Identifier: GPL-2.0-only 20 * - when used on some Wacom devices (see the list of attached PIDs), this pen 22 * - to solve that, given that we know that the next event will be the same as 30 * <Tip switch 0> <X 0> <Y 0> <Pressure 0 > <Tooltype 0x0804> 31 * <Tip switch 1> <X 1> <Y 1> <Pressure 100 > <Tooltype 0x0804> 32 * <Tip switch 1> <X 2> <Y 2> <Pressure 100 > <Tooltype 0x0804> 33 * <Tip switch 1> <X 3> <Y 3> <Pressure 200 > <Tooltype 0x0804> 34 * <Tip switch 1> <X 4> <Y 4> <Pressure 200 > <Tooltype 0x0804> 35 * <Tip switch 0> <X 5> <Y 5> <Pressure 0 > <Tooltype 0x0804> 38 * <Tip switch 0> <X 0> <Y 0> <Pressure 0 > <Tooltype 0x0804> [all …]
|
/linux/drivers/hid/ |
H A D | hid-udraw-ps3.c | 1 // SPDX-License-Identifier: GPL-2.0-only 11 #include "hid-ids.h" 21 * https://vvvv.org/contribution/udraw-hid 26 * - the touch area which works as a touchpad 27 * - the tablet area which works as a touchpad/drawing tablet 28 * - a joypad with a d-pad, and 7 buttons 29 * - an accelerometer device 47 * in order, X, Y and Z 66 #define MAX_PRESSURE (255 - PRESSURE_OFFSET) 76 * The device's two-finger support is pretty unreliable, as [all …]
|
/linux/drivers/gpu/drm/amd/display/dc/dcn10/ |
H A D | dcn10_cm_common.c | 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() 73 cur_csc_reg <= reg->csc_c33_c34; cur_csc_reg++) { in cm_helper_read_color_matrices() 93 REG_SET_2(reg->start_cntl_b, 0, in cm_helper_program_xfer_func() 94 exp_region_start, params->corner_points[0].blue.custom_float_x, in cm_helper_program_xfer_func() 96 REG_SET_2(reg->start_cntl_g, 0, in cm_helper_program_xfer_func() 97 exp_region_start, params->corner_points[0].green.custom_float_x, in cm_helper_program_xfer_func() 99 REG_SET_2(reg->start_cntl_r, 0, in cm_helper_program_xfer_func() [all …]
|
/linux/drivers/gpu/drm/amd/display/dc/dcn30/ |
H A D | dcn30_cm_common.c | 37 ctx //dpp->base.ctx 41 reg->shifts.field_name, reg->masks.field_name 51 REG_SET_2(reg->start_cntl_b, 0, in cm_helper_program_gamcor_xfer_func() 52 exp_region_start, params->corner_points[0].blue.custom_float_x, in cm_helper_program_gamcor_xfer_func() 54 REG_SET_2(reg->start_cntl_g, 0, in cm_helper_program_gamcor_xfer_func() 55 exp_region_start, params->corner_points[0].green.custom_float_x, in cm_helper_program_gamcor_xfer_func() 57 REG_SET_2(reg->start_cntl_r, 0, in cm_helper_program_gamcor_xfer_func() 58 exp_region_start, params->corner_points[0].red.custom_float_x, in cm_helper_program_gamcor_xfer_func() 61 REG_SET(reg->start_slope_cntl_b, 0, //linear slope at start of curve in cm_helper_program_gamcor_xfer_func() 62 field_region_linear_slope, params->corner_points[0].blue.custom_float_slope); in cm_helper_program_gamcor_xfer_func() [all …]
|
/linux/Documentation/userspace-api/media/v4l/ |
H A D | metafmt-vsp1-hgo.rst | 1 .. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later 3 .. _v4l2-meta-fmt-vsp1-hgo: 9 Renesas R-Car VSP1 1-D Histogram Data 15 This format describes histogram data generated by the Renesas R-Car VSP1 1-D 20 computes the minimum, maximum and sum of all pixels as well as per-channel 24 three channels (RGB data only) or on the Y channel only (YCbCr only). It can 28 - In *64 bins normal mode*, the HGO operates on the three channels independently 29 to compute three 64-bins histograms. RGB, YCbCr and HSV image formats are 31 - In *64 bins maximum mode*, the HGO operates on the maximum of the (R, G, B) 32 channels to compute a single 64-bins histogram. Only the RGB image format is [all …]
|
/linux/drivers/staging/fbtft/ |
H A D | fb_uc1611.c | 1 // SPDX-License-Identifier: GPL-2.0+ 5 * The display is 4-bit grayscale (16 shades) 240x160. 29 * V_LCD = (C_V0 + C_PM × pot) * (1 + (T - 25) * temp) 34 /* BR -> actual ratio: 0-3 -> 5, 10, 11, 13 */ 37 MODULE_PARM_DESC(ratio, "BR[1:0] Bias voltage ratio: 0-3 (default: 2)"); 41 MODULE_PARM_DESC(gain, "GN[1:0] Bias voltage gain: 0-3 (default: 3)"); 45 MODULE_PARM_DESC(pot, "PM[6:0] Bias voltage pot.: 0-63 (default: 16)"); 47 /* TC -> % compensation per deg C: 0-3 -> -.05, -.10, -.015, -.20 */ 50 MODULE_PARM_DESC(temp, "TC[1:0] Temperature compensation: 0-3 (default: 0)"); 52 /* PC[1:0] -> LCD capacitance: 0-3 -> <20nF, 20-28 nF, 29-40 nF, 40-56 nF */ [all …]
|
/linux/tools/testing/selftests/bpf/ |
H A D | bpf_arena_alloc.h | 1 /* SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) */ 7 #define __round_mask(x, y) ((__typeof__(x))((y)-1)) argument 10 #define round_up(x, y) ((((x)-1) | __round_mask(x, y))+1) argument 26 int offset; in bpf_alloc() local 29 if (size >= PAGE_SIZE - 8) in bpf_alloc() 38 *cur_offset = PAGE_SIZE - 8; in bpf_alloc() 39 obj_cnt = page + PAGE_SIZE - 8; in bpf_alloc() 43 obj_cnt = page + PAGE_SIZE - 8; in bpf_alloc() 46 offset = *cur_offset - size; in bpf_alloc() 47 if (offset < 0) in bpf_alloc() [all …]
|
/linux/drivers/media/pci/intel/ipu6/ |
H A D | ipu6-fw-isys.h | 1 /* SPDX-License-Identifier: GPL-2.0-only */ 2 /* Copyright (C) 2013--2024 Intel Corporation */ 30 /* Single device queue for high priority commands (bypass in-order queue) */ 172 IPU6_FW_ISYS_FRAME_FORMAT_NV11 = 0, /* 12 bit YUV 411, Y, UV plane */ 173 IPU6_FW_ISYS_FRAME_FORMAT_NV12, /* 12 bit YUV 420, Y, UV plane */ 174 IPU6_FW_ISYS_FRAME_FORMAT_NV12_16, /* 16 bit YUV 420, Y, UV plane */ 178 IPU6_FW_ISYS_FRAME_FORMAT_NV16, /* 16 bit YUV 422, Y, UV plane */ 179 IPU6_FW_ISYS_FRAME_FORMAT_NV21, /* 12 bit YUV 420, Y, VU plane */ 180 IPU6_FW_ISYS_FRAME_FORMAT_NV61, /* 16 bit YUV 422, Y, VU plane */ 181 IPU6_FW_ISYS_FRAME_FORMAT_YV12, /* 12 bit YUV 420, Y, V, U plane */ [all …]
|
/linux/drivers/video/fbdev/omap2/omapfb/ |
H A D | omapfb-main.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * linux/drivers/video/omap2/omapfb-main.c 16 #include <linux/dma-mapping.h> 54 static void draw_pixel(struct fb_info *fbi, int x, int y, unsigned color) in draw_pixel() argument 56 struct fb_var_screeninfo *var = &fbi->var; in draw_pixel() 57 struct fb_fix_screeninfo *fix = &fbi->fix; in draw_pixel() 58 void __iomem *addr = fbi->screen_base; in draw_pixel() 59 const unsigned bytespp = var->bits_per_pixel >> 3; in draw_pixel() 60 const unsigned line_len = fix->line_length / bytespp; in draw_pixel() 66 if (var->bits_per_pixel == 16) { in draw_pixel() [all …]
|