| /OK3568_Linux_fs/external/xserver/dix/ |
| H A D | resource.c | 75 * Copyright (c) 2005-2006, Oracle and/or its affiliates. All rights reserved. 105 * A resource ID is a 32 bit quantity, the upper 2 bits of which are 106 * off-limits for client-visible resources. The next 8 bits are 107 * used as client ID, and the low 22 bits come from the client. 108 * A resource ID is "hashed" by extracting and xoring subfields 111 * It is sometimes necessary for the server to create an ID that looks 112 * like it belongs to a client. This ID, however, must not be one 113 * the client actually can create, or we have the potential for conflict. 114 * The 31st bit of the ID is reserved for the server's use for this 115 * purpose. By setting CLIENT_ID(id) to the client, the SERVER_BIT to [all …]
|
| /OK3568_Linux_fs/external/xserver/Xext/ |
| H A D | panoramiXprocs.c | 29 #include <dix-config.h> 55 PanoramiXCreateWindow(ClientPtr client) in PanoramiXCreateWindow() argument 71 len = client->req_len - bytes_to_int32(sizeof(xCreateWindowReq)); in PanoramiXCreateWindow() 72 if (Ones(stuff->mask) != len) in PanoramiXCreateWindow() 75 result = dixLookupResourceByType((void **) &parent, stuff->parent, in PanoramiXCreateWindow() 76 XRT_WINDOW, client, DixWriteAccess); in PanoramiXCreateWindow() 80 if (stuff->class == CopyFromParent) in PanoramiXCreateWindow() 81 stuff->class = parent->u.win.class; in PanoramiXCreateWindow() 83 if ((stuff->class == InputOnly) && (stuff->mask & (~INPUTONLY_LEGAL_MASK))) in PanoramiXCreateWindow() 86 if ((Mask) stuff->mask & CWBackPixmap) { in PanoramiXCreateWindow() [all …]
|
| H A D | xselinux_ext.c | 21 #include <dix-config.h> 44 CARD32 id; member 64 ProcSELinuxQueryVersion(ClientPtr client) in ProcSELinuxQueryVersion() argument 68 .sequenceNumber = client->sequence, in ProcSELinuxQueryVersion() 73 if (client->swapped) { in ProcSELinuxQueryVersion() 79 WriteToClient(client, sizeof(rep), &rep); in ProcSELinuxQueryVersion() 84 SELinuxSendContextReply(ClientPtr client, security_id_t sid) in SELinuxSendContextReply() argument 98 .sequenceNumber = client->sequence, in SELinuxSendContextReply() 103 if (client->swapped) { in SELinuxSendContextReply() 109 WriteToClient(client, sizeof(SELinuxGetContextReply), &rep); in SELinuxSendContextReply() [all …]
|
| H A D | xres.c | 6 #include <dix-config.h> 25 #include "protocol-versions.h" 26 #include "client.h" 49 ProcXResQueryClientIds; used by ConstructClientId* -functions */ 62 via a parameter, as they are called via already-existing 97 @return Returns a pointer to the allocated non-zeroed region 108 f->bytes = bytes; in AddFragment() 109 xorg_list_add(&f->l, frags->prev); in AddFragment() 114 /** @brief Sends all fragments in the list to the client. Does not 117 @param client The client to send the fragments to [all …]
|
| H A D | xvdisp.c | 25 #include <dix-config.h> 59 SWriteQueryExtensionReply(ClientPtr client, xvQueryExtensionReply * rep) in SWriteQueryExtensionReply() argument 61 swaps(&rep->sequenceNumber); in SWriteQueryExtensionReply() 62 swapl(&rep->length); in SWriteQueryExtensionReply() 63 swaps(&rep->version); in SWriteQueryExtensionReply() 64 swaps(&rep->revision); in SWriteQueryExtensionReply() 66 WriteToClient(client, sz_xvQueryExtensionReply, rep); in SWriteQueryExtensionReply() 72 SWriteQueryAdaptorsReply(ClientPtr client, xvQueryAdaptorsReply * rep) in SWriteQueryAdaptorsReply() argument 74 swaps(&rep->sequenceNumber); in SWriteQueryAdaptorsReply() 75 swapl(&rep->length); in SWriteQueryAdaptorsReply() [all …]
|
| H A D | xvmain.c | 28 ** xvmain.c --- Xv server extension main device independent module. 37 ** - change: stop video always generates an event even when video 41 ** - change: unrealizing windows no longer preempts video 44 ** - changed SetPortControl to SetPortAttribute 45 ** - changed GetPortControl to GetPortAttribute 46 ** - changed QueryBestSize 49 ** - fixed Put and Get requests to not preempt operations to same drawable 52 ** - version 2.0 upgrade 55 ** - fixed Put and Get requests to honor grabbed ports. 56 ** - fixed Video requests to update di structure with new drawable, and [all …]
|
| /OK3568_Linux_fs/kernel/drivers/gpu/vga/ |
| H A D | vga_switcheroo.c | 2 * vga_switcheroo.c - Support for laptop with dual GPU using one set of outputs 33 #include <linux/apple-gmux.h> 71 * handler to control the power state of the discrete GPU, its ->switchto 72 * callback is a no-op for obvious reasons. The discrete GPU is often equipped 74 * register as a client so that vga_switcheroo can take care of the correct 77 * client (on the discrete GPU). The code is mostly prepared to support 81 * active client in vga_switcheroo parlance. The GPU not in use is the 82 * inactive client. When the inactive client's DRM driver is loaded, 86 * a client may alternatively request that the DDC lines are temporarily 93 * struct vga_switcheroo_client - registered client [all …]
|
| /OK3568_Linux_fs/kernel/drivers/input/touchscreen/ |
| H A D | gslx680_pad.c | 44 #define GSLX680_I2C_NAME "gslX680-pad" 105 struct i2c_client *client; member 182 static u32 gsl_write_interface(struct i2c_client *client, const u8 reg, u8 *buf, u32 num) in gsl_write_interface() argument 188 xfer_msg[0].addr = client->addr; in gsl_write_interface() 190 xfer_msg[0].flags = client->flags & I2C_M_TEN; in gsl_write_interface() 194 return i2c_transfer(client->adapter, xfer_msg, 1) == 1 ? 0 : -EFAULT; in gsl_write_interface() 197 static int gsl_ts_write(struct i2c_client *client, u8 addr, u8 *pdata, int datalen) in gsl_ts_write() argument 204 dev_err(&client->dev,"%s too big datalen = %d!\n", __func__, datalen); in gsl_ts_write() 205 return -1; in gsl_ts_write() 217 ret = i2c_master_send(client, tmp_buf, bytelen); in gsl_ts_write() [all …]
|
| H A D | gslx680_firefly.c | 129 struct i2c_client *client; member 169 if (gpio_is_valid(gts->rst_pin)) in gslX680_shutdown_low() 170 gpio_set_value(gts->rst_pin, GPIO_LOW); in gslX680_shutdown_low() 177 if (gpio_is_valid(gts->rst_pin)) in gslX680_shutdown_high() 178 gpio_set_value(gts->rst_pin, GPIO_HIGH); in gslX680_shutdown_high() 192 static u32 gsl_write_interface(struct i2c_client *client, const u8 reg, u8 *buf, u32 num) in gsl_write_interface() argument 197 xfer_msg[0].addr = client->addr; in gsl_write_interface() 199 xfer_msg[0].flags = client->flags & I2C_M_TEN; in gsl_write_interface() 202 return i2c_transfer(client->adapter, xfer_msg, 1) == 1 ? 0 : -EFAULT; in gsl_write_interface() 205 static int gsl_ts_write(struct i2c_client *client, u8 addr, u8 *pdata, int datalen) in gsl_ts_write() argument [all …]
|
| H A D | gsl3673_800x1280.c | 197 struct i2c_client *client; member 233 struct device_node *np = gsl_client->dev.of_node; in gsl3673_init() 237 this_ts->irq = of_get_named_gpio_flags(np, "irq_gpio_number", 0, in gsl3673_init() 239 this_ts->rst = of_get_named_gpio_flags(np, "rst_gpio_number", 0, in gsl3673_init() 241 if (devm_gpio_request(&this_ts->client->dev, this_ts->rst, NULL) != 0) { in gsl3673_init() 242 dev_err(&this_ts->client->dev, "gpio_request this_ts->rst error\n"); in gsl3673_init() 243 return -EIO; in gsl3673_init() 245 gpio_direction_output(this_ts->rst, 0); in gsl3673_init() 246 gpio_set_value(this_ts->rst, 1); in gsl3673_init() 252 if (this_ts->rst > 1) in gsl3673_shutdown_low() [all …]
|
| H A D | gsl3673.c | 194 struct i2c_client *client; member 235 struct device_node *np = gsl_client->dev.of_node; in gsl3673_init() 239 this_ts->irq = of_get_named_gpio_flags(np, "irq_gpio_number", 0, in gsl3673_init() 241 if (!gpio_is_valid(this_ts->irq)) { in gsl3673_init() 242 dev_err(&this_ts->client->dev, "irq pin invalid\n"); in gsl3673_init() 243 return -EINVAL; in gsl3673_init() 246 this_ts->rst = of_get_named_gpio_flags(np, "rst_gpio_number", 0, in gsl3673_init() 248 if (!gpio_is_valid(this_ts->rst)) { in gsl3673_init() 249 dev_err(&this_ts->client->dev, "rst pin invalid\n"); in gsl3673_init() 250 return -EINVAL; in gsl3673_init() [all …]
|
| H A D | gslx6801.c | 148 struct i2c_client *client; member 192 if (!IS_ERR(ts->pinctrl)) in gslx680_set_pinctrl_state() 193 return PTR_ERR(ts->pinctrl); in gslx680_set_pinctrl_state() 196 ret = pinctrl_select_state(ts->pinctrl, state); in gslx680_set_pinctrl_state() 206 struct device_node *np = ts->client->dev.of_node; in gslX680_init() 209 ts->irq = of_get_named_gpio_flags(np, "touch-gpio", 0, NULL); in gslX680_init() 210 ts->rst = of_get_named_gpio_flags(np, "reset-gpio", 0, NULL); in gslX680_init() 213 ts->pinctrl = devm_pinctrl_get(&ts->client->dev); in gslX680_init() 214 if (!IS_ERR(ts->pinctrl)) { in gslX680_init() 215 ts->pins_default = in gslX680_init() [all …]
|
| H A D | gslx680a.c | 242 struct i2c_client *client; member 302 static u32 gsl_write_interface(struct i2c_client *client, const u8 reg, u8 *buf, u32 num) in gsl_write_interface() argument 308 xfer_msg[0].addr = client->addr; in gsl_write_interface() 310 xfer_msg[0].flags = client->flags & I2C_M_TEN; in gsl_write_interface() 313 return i2c_transfer(client->adapter, xfer_msg, 1) == 1 ? 0 : -EFAULT; in gsl_write_interface() 316 static int gsl_ts_write(struct i2c_client *client, u8 addr, u8 *pdata, int datalen) in gsl_ts_write() argument 324 return -1; in gsl_ts_write() 335 ret = i2c_master_send(client, tmp_buf, bytelen); in gsl_ts_write() 339 static int gsl_ts_read(struct i2c_client *client, u8 addr, u8 *pdata, unsigned int datalen) in gsl_ts_read() argument 345 return -1; in gsl_ts_read() [all …]
|
| /OK3568_Linux_fs/kernel/drivers/media/i2c/ |
| H A D | otp_eeprom.c | 1 // SPDX-License-Identifier: GPL-2.0 22 #include <linux/rk-camera-module.h> 25 #include <media/v4l2-ctrls.h> 26 #include <media/v4l2-device.h> 40 static int read_reg_otp(struct i2c_client *client, u16 reg, in read_reg_otp() argument 50 return -EINVAL; in read_reg_otp() 54 msgs[0].addr = client->addr; in read_reg_otp() 60 msgs[1].addr = client->addr; in read_reg_otp() 63 msgs[1].buf = &data_be_p[4 - len]; in read_reg_otp() 65 ret = i2c_transfer(client->adapter, msgs, ARRAY_SIZE(msgs)); in read_reg_otp() [all …]
|
| H A D | aw36518.c | 1 // SPDX-License-Identifier: GPL-2.0 18 #include <linux/rk-camera-module.h> 19 #include <linux/rk-led-flash.h> 22 #include <media/v4l2-ctrls.h> 23 #include <media/v4l2-device.h> 61 (((a) - AW36518_MIN_FLASH_INTENSITY) / AW36518_FLASH_INTENSITY_STEP)) 74 (((a) - AW36518_MIN_TORCH_INTENSITY) / AW36518_TORCH_INTENSITY_STEP)) 90 (((a) - TIMEOUT_MIN) / TIMEOUT_STEP)) 96 MODULE_PARM_DESC(debug, "debug level (0-2)"); 116 struct i2c_client *client; member [all …]
|
| H A D | sgm3784.c | 1 // SPDX-License-Identifier: GPL-2.0 13 #include <linux/rk-camera-module.h> 14 #include <linux/rk-led-flash.h> 17 #include <media/v4l2-ctrls.h> 18 #include <media/v4l2-device.h> 57 MODULE_PARM_DESC(debug, "debug level (0-2)"); 77 struct i2c_client *client; member 95 struct i2c_client *client = flash->client; in sgm3784_i2c_write() local 98 ret = i2c_smbus_write_byte_data(client, reg, val); in sgm3784_i2c_write() 100 dev_err(&client->dev, in sgm3784_i2c_write() [all …]
|
| /OK3568_Linux_fs/external/xserver/Xi/ |
| H A D | xichangehierarchy.c | 2 * Copyright 2007-2008 Peter Hutterer 34 #include <dix-config.h> 76 ev->type = GenericEvent; in XISendDeviceHierarchyEvent() 77 ev->extension = IReqCode; in XISendDeviceHierarchyEvent() 78 ev->evtype = XI_HierarchyChanged; in XISendDeviceHierarchyEvent() 79 ev->time = GetTimeInMillis(); in XISendDeviceHierarchyEvent() 80 ev->flags = 0; in XISendDeviceHierarchyEvent() 81 ev->num_info = inputInfo.numDevices; in XISendDeviceHierarchyEvent() 84 for (dev = inputInfo.devices; dev; dev = dev->next) { in XISendDeviceHierarchyEvent() 85 info->deviceid = dev->id; in XISendDeviceHierarchyEvent() [all …]
|
| /OK3568_Linux_fs/kernel/drivers/input/keyboard/ |
| H A D | qt2160.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 * qt2160.c - Atmel AT42QT2160 Touch Sense Controller 49 int id; member 55 struct i2c_client *client; member 65 static int qt2160_read(struct i2c_client *client, u8 reg); 66 static int qt2160_write(struct i2c_client *client, u8 reg, u8 data); 74 struct qt2160_data *qt2160 = led->qt2160; in qt2160_led_set() 75 struct i2c_client *client = qt2160->client; in qt2160_led_set() local 78 if (value != led->brightness) { in qt2160_led_set() 79 drive = qt2160_read(client, QT2160_CMD_DRIVE_X); in qt2160_led_set() [all …]
|
| /OK3568_Linux_fs/kernel/drivers/leds/ |
| H A D | leds-bd2802.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * leds-bd2802.c - RGB LED Driver 8 * Datasheet: http://www.rohm.com/products/databook/driver/pdf/bd2802gu-e.pdf 16 #include <linux/leds-bd2802.h> 69 struct i2c_client *client; member 104 /*--------------------------------------------------------------*/ 106 /*--------------------------------------------------------------*/ 108 static inline int bd2802_is_rgb_off(struct bd2802_led *led, enum led_ids id, in bd2802_is_rgb_off() argument 113 return !led->led[id].r; in bd2802_is_rgb_off() 115 return !led->led[id].g; in bd2802_is_rgb_off() [all …]
|
| /OK3568_Linux_fs/kernel/drivers/video/backlight/ |
| H A D | adp8860_bl.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 5 * Copyright 2009-2010 Analog Devices Inc. 24 #define ADP8860_MFDVID 0x00 /* Manufacturer and device ID */ 33 #define ADP8860_BLMX1 0x09 /* Backlight (Brightness Level 1-daylight) maximum current */ 34 #define ADP8860_BLDM1 0x0A /* Backlight (Brightness Level 1-daylight) dim current */ 35 #define ADP8860_BLMX2 0x0B /* Backlight (Brightness Level 2-office) maximum current */ 36 #define ADP8860_BLDM2 0x0C /* Backlight (Brightness Level 2-office) dim current */ 37 #define ADP8860_BLMX3 0x0D /* Backlight (Brightness Level 3-dark) maximum current */ 38 #define ADP8860_BLDM3 0x0E /* Backlight (Brightness Level 3-dark) dim current */ 57 #define ADP8860_PH1LEVL 0x21 /* First phototransistor ambient light level-low byte register */ [all …]
|
| /OK3568_Linux_fs/kernel/drivers/net/ethernet/hisilicon/hns3/ |
| H A D | hnae3.c | 1 // SPDX-License-Identifier: GPL-2.0+ 2 // Copyright (c) 2016-2017 Hisilicon Limited. 22 if (!hnae3_get_bit(ae_dev->flag, HNAE3_DEV_INITED_B)) in hnae3_unregister_ae_algo_prepare() 25 pci_id = pci_match_id(ae_algo->pdev_id_table, ae_dev->pdev); in hnae3_unregister_ae_algo_prepare() 29 pci_disable_sriov(ae_dev->pdev); in hnae3_unregister_ae_algo_prepare() 35 * list. This is a non-critical code so other updations, if happen 49 void hnae3_set_client_init_flag(struct hnae3_client *client, in hnae3_set_client_init_flag() argument 53 if (!client || !ae_dev) in hnae3_set_client_init_flag() 56 switch (client->type) { in hnae3_set_client_init_flag() 58 hnae3_set_bit(ae_dev->flag, HNAE3_KNIC_CLIENT_INITED_B, inited); in hnae3_set_client_init_flag() [all …]
|
| /OK3568_Linux_fs/kernel/drivers/input/touchscreen/gsl3676/ |
| H A D | gsl3676.c | 197 struct i2c_client *client; member 233 struct device_node *np = gsl_client->dev.of_node; in gsl_init() 237 this_ts->irq = of_get_named_gpio_flags(np, "irq_gpio_number", 0, in gsl_init() 239 this_ts->rst = of_get_named_gpio_flags(np, "rst_gpio_number", 0, in gsl_init() 242 if (gpio_is_valid(this_ts->rst)) { in gsl_init() 243 if (devm_gpio_request(&this_ts->client->dev, this_ts->rst, NULL) != 0) { in gsl_init() 244 dev_err(&this_ts->client->dev, "gpio_request this_ts->rst error\n"); in gsl_init() 245 return -EIO; in gsl_init() 247 gpio_direction_output(this_ts->rst, 0); in gsl_init() 248 gpio_set_value(this_ts->rst, 1); in gsl_init() [all …]
|
| /OK3568_Linux_fs/kernel/drivers/i2c/muxes/ |
| H A D | i2c-mux-pca954x.c | 1 // SPDX-License-Identifier: GPL-2.0 5 * Copyright (c) 2008-2009 Rodolfo Giometti <giometti@linux.it> 6 * Copyright (c) 2008-2009 Eurotech S.p.A. <info@eurotech.it> 15 * single 8-bit register. The upstream "parent" bus fans out to two, 18 * mux can select only one sub-bus at a time; a switch can select any 30 * i2c-virtual_cb.c from Brian Kuschak <bkuschak@yahoo.com> 39 #include <linux/i2c-mux.h> 47 #include <dt-bindings/mux/mux.h> 76 struct i2c_device_identity id; member 86 struct i2c_client *client; member [all …]
|
| /OK3568_Linux_fs/kernel/drivers/input/touchscreen/gslx680_d708/ |
| H A D | rockchip_gslX680.c | 42 #define GSLX680_I2C_NAME "gslX680-d708" 69 static int gsl_lcd_flag = -1; 70 static int gsl_gesture_flag = -1; 144 struct i2c_client *client; member 214 static u32 gsl_write_interface(struct i2c_client *client, const u8 reg, u8 *buf, u32 num) in gsl_write_interface() argument 220 xfer_msg[0].addr = client->addr; in gsl_write_interface() 222 xfer_msg[0].flags = client->flags & I2C_M_TEN; in gsl_write_interface() 225 return i2c_transfer(client->adapter, xfer_msg, 1) == 1 ? 0 : -EFAULT; in gsl_write_interface() 228 static int gsl_ts_write(struct i2c_client *client, u8 addr, u8 *pdata, int datalen) in gsl_ts_write() argument 235 return -1; in gsl_ts_write() [all …]
|
| /OK3568_Linux_fs/external/xserver/composite/ |
| H A D | compext.c | 45 #include <dix-config.h> 50 #include "protocol-versions.h" 67 dixLookupPrivate(&(pClient)->devPrivates, CompositeClientPrivateKey)) 97 ProcCompositeQueryVersion(ClientPtr client) in ProcCompositeQueryVersion() argument 99 CompositeClientPtr pCompositeClient = GetCompositeClient(client); in ProcCompositeQueryVersion() 102 .sequenceNumber = client->sequence, in ProcCompositeQueryVersion() 109 if (stuff->majorVersion < SERVER_COMPOSITE_MAJOR_VERSION) { in ProcCompositeQueryVersion() 110 rep.majorVersion = stuff->majorVersion; in ProcCompositeQueryVersion() 111 rep.minorVersion = stuff->minorVersion; in ProcCompositeQueryVersion() 117 pCompositeClient->major_version = rep.majorVersion; in ProcCompositeQueryVersion() [all …]
|