/drivers/gpu/drm/msm/ |
D | msm_rd.c | 101 static void rd_write(struct msm_rd_state *rd, const void *buf, int sz) in rd_write() argument 103 struct circ_buf *fifo = &rd->fifo; in rd_write() 110 wait_event(rd->fifo_event, circ_space(&rd->fifo) > 0 || !rd->open); in rd_write() 111 if (!rd->open) in rd_write() 118 n = min(sz, circ_space_to_end(&rd->fifo)); in rd_write() 125 wake_up_all(&rd->fifo_event); in rd_write() 129 static void rd_write_section(struct msm_rd_state *rd, in rd_write_section() argument 132 rd_write(rd, &type, 4); in rd_write_section() 133 rd_write(rd, &sz, 4); in rd_write_section() 134 rd_write(rd, buf, sz); in rd_write_section() [all …]
|
/drivers/powercap/ |
D | intel_rapl_common.c | 95 void (*set_floor_freq)(struct rapl_domain *rd, bool mode); 132 static int rapl_read_data_raw(struct rapl_domain *rd, 135 static int rapl_write_data_raw(struct rapl_domain *rd, 138 static u64 rapl_unit_xlate(struct rapl_domain *rd, 155 struct rapl_domain *rd; in get_energy_counter() local 162 rd = power_zone_to_rapl_domain(power_zone); in get_energy_counter() 164 if (!rapl_read_data_raw(rd, ENERGY_COUNTER, true, &energy_now)) { in get_energy_counter() 177 struct rapl_domain *rd = power_zone_to_rapl_domain(pcd_dev); in get_max_energy_counter() local 179 *energy = rapl_unit_xlate(rd, ENERGY_UNIT, ENERGY_STATUS_MASK, 0); in get_max_energy_counter() 185 struct rapl_domain *rd = power_zone_to_rapl_domain(power_zone); in release_zone() local [all …]
|
/drivers/media/tuners/ |
D | qt1010.c | 51 qt1010_i2c_oper_t rd[48] = { in qt1010_set_params() local 123 rd[2].val = reg05; in qt1010_set_params() 126 rd[4].val = (freq + QT1010_OFFSET) / FREQ1; in qt1010_set_params() 129 if (mod1 < 8000000) rd[6].val = 0x1d; in qt1010_set_params() 130 else rd[6].val = 0x1c; in qt1010_set_params() 133 if (mod1 < 1*FREQ2) rd[7].val = 0x09; /* +0 MHz */ in qt1010_set_params() 134 else if (mod1 < 2*FREQ2) rd[7].val = 0x08; /* +4 MHz */ in qt1010_set_params() 135 else if (mod1 < 3*FREQ2) rd[7].val = 0x0f; /* +8 MHz */ in qt1010_set_params() 136 else if (mod1 < 4*FREQ2) rd[7].val = 0x0e; /* +12 MHz */ in qt1010_set_params() 137 else if (mod1 < 5*FREQ2) rd[7].val = 0x0d; /* +16 MHz */ in qt1010_set_params() [all …]
|
/drivers/reset/ |
D | reset-pistachio.c | 66 struct pistachio_reset_data *rd; in pistachio_reset_assert() local 70 rd = container_of(rcdev, struct pistachio_reset_data, rcdev); in pistachio_reset_assert() 76 return regmap_update_bits(rd->periph_regs, PISTACHIO_SOFT_RESET, in pistachio_reset_assert() 83 struct pistachio_reset_data *rd; in pistachio_reset_deassert() local 87 rd = container_of(rcdev, struct pistachio_reset_data, rcdev); in pistachio_reset_deassert() 93 return regmap_update_bits(rd->periph_regs, PISTACHIO_SOFT_RESET, in pistachio_reset_deassert() 104 struct pistachio_reset_data *rd; in pistachio_reset_probe() local 108 rd = devm_kzalloc(dev, sizeof(*rd), GFP_KERNEL); in pistachio_reset_probe() 109 if (!rd) in pistachio_reset_probe() 112 rd->periph_regs = syscon_node_to_regmap(np->parent); in pistachio_reset_probe() [all …]
|
/drivers/media/dvb-frontends/ |
D | dib3000mb.c | 342 rd(DIB3000MB_REG_AS_IRQ_PENDING), in dib3000mb_set_frontend() 343 rd(DIB3000MB_REG_LOCK2_VALUE))) < 0 && as_count++ < 100) in dib3000mb_set_frontend() 450 if (!rd(DIB3000MB_REG_TPS_LOCK)) in dib3000mb_get_frontend() 453 dds_val = ((rd(DIB3000MB_REG_DDS_VALUE_MSB) & 0xff) << 16) + rd(DIB3000MB_REG_DDS_VALUE_LSB); in dib3000mb_get_frontend() 454 …deb_getf("DDS_VAL: %x %x %x\n", dds_val, rd(DIB3000MB_REG_DDS_VALUE_MSB), rd(DIB3000MB_REG_DDS_VAL… in dib3000mb_get_frontend() 462 dds_val = ((rd(DIB3000MB_REG_DDS_FREQ_MSB) & 0xff) << 16) + rd(DIB3000MB_REG_DDS_FREQ_LSB); in dib3000mb_get_frontend() 463 …deb_getf("DDS_FREQ: %x %x %x\n", dds_val, rd(DIB3000MB_REG_DDS_FREQ_MSB), rd(DIB3000MB_REG_DDS_FRE… in dib3000mb_get_frontend() 478 switch ((tps_val = rd(DIB3000MB_REG_TPS_QAM))) { in dib3000mb_get_frontend() 497 if (rd(DIB3000MB_REG_TPS_HRCH)) { in dib3000mb_get_frontend() 501 switch ((tps_val = rd(DIB3000MB_REG_TPS_VIT_ALPHA))) { in dib3000mb_get_frontend() [all …]
|
/drivers/clk/samsung/ |
D | clk-exynos5-subcmu.c | 21 struct exynos5_subcmu_reg_dump *rd, in exynos5_subcmu_clk_save() argument 24 for (; num_regs > 0; --num_regs, ++rd) { in exynos5_subcmu_clk_save() 25 rd->save = readl(base + rd->offset); in exynos5_subcmu_clk_save() 26 writel((rd->save & ~rd->mask) | rd->value, base + rd->offset); in exynos5_subcmu_clk_save() 27 rd->save &= rd->mask; in exynos5_subcmu_clk_save() 32 struct exynos5_subcmu_reg_dump *rd, in exynos5_subcmu_clk_restore() argument 35 for (; num_regs > 0; --num_regs, ++rd) in exynos5_subcmu_clk_restore() 36 writel((readl(base + rd->offset) & ~rd->mask) | rd->save, in exynos5_subcmu_clk_restore() 37 base + rd->offset); in exynos5_subcmu_clk_restore()
|
D | clk.c | 24 struct samsung_clk_reg_dump *rd, in samsung_clk_save() argument 27 for (; num_regs > 0; --num_regs, ++rd) in samsung_clk_save() 28 rd->value = readl(base + rd->offset); in samsung_clk_save() 32 const struct samsung_clk_reg_dump *rd, in samsung_clk_restore() argument 35 for (; num_regs > 0; --num_regs, ++rd) in samsung_clk_restore() 36 writel(rd->value, base + rd->offset); in samsung_clk_restore() 43 struct samsung_clk_reg_dump *rd; in samsung_clk_alloc_reg_dump() local 46 rd = kcalloc(nr_rdump, sizeof(*rd), GFP_KERNEL); in samsung_clk_alloc_reg_dump() 47 if (!rd) in samsung_clk_alloc_reg_dump() 51 rd[i].offset = rdump[i]; in samsung_clk_alloc_reg_dump() [all …]
|
/drivers/memory/samsung/ |
D | exynos-srom.c | 54 struct exynos_srom_reg_dump *rd; in exynos_srom_alloc_reg_dump() local 57 rd = kcalloc(nr_rdump, sizeof(*rd), GFP_KERNEL); in exynos_srom_alloc_reg_dump() 58 if (!rd) in exynos_srom_alloc_reg_dump() 62 rd[i].offset = rdump[i]; in exynos_srom_alloc_reg_dump() 64 return rd; in exynos_srom_alloc_reg_dump() 160 struct exynos_srom_reg_dump *rd, in exynos_srom_save() argument 163 for (; num_regs > 0; --num_regs, ++rd) in exynos_srom_save() 164 rd->value = readl(base + rd->offset); in exynos_srom_save() 168 const struct exynos_srom_reg_dump *rd, in exynos_srom_restore() argument 171 for (; num_regs > 0; --num_regs, ++rd) in exynos_srom_restore() [all …]
|
/drivers/media/pci/cobalt/ |
D | cobalt-cpld.c | 27 u32 rd; in cpld_info_ver3() local 66 rd = cpld_read(cobalt, 0x3c); in cpld_info_ver3() 67 tmp = (rd * 33 * 1000) / (483 * 10); in cpld_info_ver3() 69 rd = cpld_read(cobalt, 0x40); in cpld_info_ver3() 70 tmp = (rd * 74 * 2197) / (27 * 1000); in cpld_info_ver3() 72 rd = cpld_read(cobalt, 0x44); in cpld_info_ver3() 73 tmp = (rd * 74 * 2197) / (47 * 1000); in cpld_info_ver3() 75 rd = cpld_read(cobalt, 0x48); in cpld_info_ver3() 76 tmp = (rd * 57 * 2197) / (47 * 1000); in cpld_info_ver3() 78 rd = cpld_read(cobalt, 0x4c); in cpld_info_ver3() [all …]
|
/drivers/i2c/busses/ |
D | i2c-pasemi.c | 112 u32 rd; in pasemi_i2c_xfer_msg() local 127 rd = RXFIFO_RD(smbus); in pasemi_i2c_xfer_msg() 128 if (rd & MRXFIFO_EMPTY) { in pasemi_i2c_xfer_msg() 132 msg->buf[i] = rd & MRXFIFO_DATA_M; in pasemi_i2c_xfer_msg() 177 unsigned int rd; in pasemi_smb_xfer() local 226 rd = RXFIFO_RD(smbus); in pasemi_smb_xfer() 227 len = min_t(u8, (rd & MRXFIFO_DATA_M), in pasemi_smb_xfer() 258 rd = RXFIFO_RD(smbus); in pasemi_smb_xfer() 259 len = min_t(u8, (rd & MRXFIFO_DATA_M), in pasemi_smb_xfer() 279 rd = RXFIFO_RD(smbus); in pasemi_smb_xfer() [all …]
|
/drivers/of/ |
D | of_reserved_mem.c | 334 struct rmem_assigned_device *rd; in of_reserved_mem_device_init_by_idx() local 357 rd = kmalloc(sizeof(struct rmem_assigned_device), GFP_KERNEL); in of_reserved_mem_device_init_by_idx() 358 if (!rd) in of_reserved_mem_device_init_by_idx() 363 rd->dev = dev; in of_reserved_mem_device_init_by_idx() 364 rd->rmem = rmem; in of_reserved_mem_device_init_by_idx() 367 list_add(&rd->list, &of_rmem_assigned_device_list); in of_reserved_mem_device_init_by_idx() 372 kfree(rd); in of_reserved_mem_device_init_by_idx() 407 struct rmem_assigned_device *rd, *tmp; in of_reserved_mem_device_release() local 411 list_for_each_entry_safe(rd, tmp, &of_rmem_assigned_device_list, list) { in of_reserved_mem_device_release() 412 if (rd->dev == dev) in of_reserved_mem_device_release() [all …]
|
D | dynamic.c | 236 struct of_reconfig_data rd; in of_attach_node() local 239 memset(&rd, 0, sizeof(rd)); in of_attach_node() 240 rd.dn = np; in of_attach_node() 250 of_reconfig_notify(OF_RECONFIG_ATTACH_NODE, &rd); in of_attach_node() 288 struct of_reconfig_data rd; in of_detach_node() local 291 memset(&rd, 0, sizeof(rd)); in of_detach_node() 292 rd.dn = np; in of_detach_node() 302 of_reconfig_notify(OF_RECONFIG_DETACH_NODE, &rd); in of_detach_node() 536 struct of_reconfig_data rd; in __of_changeset_entry_notify() local 548 memset(&rd, 0, sizeof(rd)); in __of_changeset_entry_notify() [all …]
|
/drivers/hid/ |
D | hid-sony.c | 890 static void sixaxis_parse_report(struct sony_sc *sc, u8 *rd, int size) in sixaxis_parse_report() argument 905 if (rd[offset] >= 0xee) { in sixaxis_parse_report() 907 battery_charging = !(rd[offset] & 0x01); in sixaxis_parse_report() 910 u8 index = rd[offset] <= 5 ? rd[offset] : 5; in sixaxis_parse_report() 926 val = ((rd[offset+1] << 8) | rd[offset]) - 511; in sixaxis_parse_report() 930 val = 511 - ((rd[offset+5] << 8) | rd[offset+4]); in sixaxis_parse_report() 933 val = 511 - ((rd[offset+3] << 8) | rd[offset+2]); in sixaxis_parse_report() 940 static void dualshock4_parse_report(struct sony_sc *sc, u8 *rd, int size) in dualshock4_parse_report() argument 955 input_report_key(sc->touchpad, BTN_LEFT, rd[offset+2] & 0x2); in dualshock4_parse_report() 971 if (rd[0] == 17) { in dualshock4_parse_report() [all …]
|
/drivers/scsi/ |
D | raid_class.c | 80 struct raid_data *rd; in raid_setup() local 84 rd = kzalloc(sizeof(*rd), GFP_KERNEL); in raid_setup() 85 if (!rd) in raid_setup() 88 INIT_LIST_HEAD(&rd->component_list); in raid_setup() 89 dev_set_drvdata(cdev, rd); in raid_setup() 97 struct raid_data *rd = dev_get_drvdata(cdev); in raid_remove() local 101 list_for_each_entry_safe(rc, next, &rd->component_list, node) { in raid_remove() 107 kfree(rd); in raid_remove() 179 struct raid_data *rd = dev_get_drvdata(dev); \ 188 name = raid_##states##_name(rd->attr); \ [all …]
|
/drivers/net/wireless/ralink/rt2x00/ |
D | rt2x00usb.c | 180 struct rt2x00_async_read_data *rd = urb->context; in rt2x00usb_register_read_async_cb() local 181 if (rd->callback(rd->rt2x00dev, urb->status, le32_to_cpu(rd->reg))) { in rt2x00usb_register_read_async_cb() 182 usb_anchor_urb(urb, rd->rt2x00dev->anchor); in rt2x00usb_register_read_async_cb() 185 kfree(rd); in rt2x00usb_register_read_async_cb() 188 kfree(rd); in rt2x00usb_register_read_async_cb() 197 struct rt2x00_async_read_data *rd; in rt2x00usb_register_read_async() local 199 rd = kmalloc(sizeof(*rd), GFP_ATOMIC); in rt2x00usb_register_read_async() 200 if (!rd) in rt2x00usb_register_read_async() 205 kfree(rd); in rt2x00usb_register_read_async() 209 rd->rt2x00dev = rt2x00dev; in rt2x00usb_register_read_async() [all …]
|
/drivers/clk/versatile/ |
D | icst.c | 51 unsigned int i = 0, rd, best = (unsigned int)-1; in icst_hz_to_vco() local 74 for (rd = p->rd_min; rd <= p->rd_max; rd++) { in icst_hz_to_vco() 79 fref_div = (2 * p->ref) / rd; in icst_hz_to_vco() 92 vco.r = rd - 2; in icst_hz_to_vco()
|
/drivers/i2c/ |
D | i2c-core-of.c | 235 struct of_reconfig_data *rd = arg; in of_i2c_notify() local 239 switch (of_reconfig_get_state_change(action, rd)) { in of_i2c_notify() 241 adap = of_find_i2c_adapter_by_node(rd->dn->parent); in of_i2c_notify() 245 if (of_node_test_and_set_flag(rd->dn, OF_POPULATED)) { in of_i2c_notify() 250 client = of_i2c_register_device(adap, rd->dn); in of_i2c_notify() 253 rd->dn); in of_i2c_notify() 255 of_node_clear_flag(rd->dn, OF_POPULATED); in of_i2c_notify() 262 if (!of_node_check_flag(rd->dn, OF_POPULATED)) in of_i2c_notify() 266 client = of_find_i2c_device_by_node(rd->dn); in of_i2c_notify()
|
/drivers/perf/ |
D | xgene_pmu.c | 343 XGENE_PMU_EVENT_ATTR(rd-cmd-sent, 0x04), 351 XGENE_PMU_EVENT_ATTR(rd-rda-cmd-sent, 0x0c), 353 XGENE_PMU_EVENT_ATTR(in-rd-collision, 0x0e), 358 XGENE_PMU_EVENT_ATTR(mcu-rd-request, 0x13), 359 XGENE_PMU_EVENT_ATTR(mcu-hp-rd-request, 0x14), 361 XGENE_PMU_EVENT_ATTR(mcu-rd-proceed-all, 0x16), 362 XGENE_PMU_EVENT_ATTR(mcu-rd-proceed-cancel, 0x17), 363 XGENE_PMU_EVENT_ATTR(mcu-rd-response, 0x18), 364 XGENE_PMU_EVENT_ATTR(mcu-rd-proceed-speculative-all, 0x19), 365 XGENE_PMU_EVENT_ATTR(mcu-rd-proceed-speculative-cancel, 0x1a), [all …]
|
/drivers/net/ethernet/seeq/ |
D | sgiseeq.c | 345 struct sgiseeq_rx_desc *rd; in sgiseeq_rx() local 353 rd = &sp->rx_desc[sp->rx_new]; in sgiseeq_rx() 354 dma_sync_desc_cpu(dev, rd); in sgiseeq_rx() 355 while (!(rd->rdma.cntinfo & HPCDMA_OWN)) { in sgiseeq_rx() 356 len = PKT_BUF_SZ - (rd->rdma.cntinfo & HPCDMA_BCNT) - 3; in sgiseeq_rx() 357 dma_unmap_single(dev->dev.parent, rd->rdma.pbuf, in sgiseeq_rx() 359 pkt_status = rd->skb->data[len]; in sgiseeq_rx() 363 if (!ether_addr_equal(rd->skb->data + 6, dev->dev_addr)) { in sgiseeq_rx() 365 skb = rd->skb; in sgiseeq_rx() 376 skb_copy_to_linear_data(skb, rd->skb->data, len); in sgiseeq_rx() [all …]
|
/drivers/video/fbdev/omap/ |
D | lcd_mipid.c | 341 } *rd, rd_ctrl[7] = { in ls041y3_esd_check_mode2() local 351 rd = rd_ctrl; in ls041y3_esd_check_mode2() 352 for (i = 0; i < 3; i++, rd++) in ls041y3_esd_check_mode2() 353 mipid_write(md, rd->cmd, (u8 *)rd->wbuf, rd->wlen); in ls041y3_esd_check_mode2() 356 mipid_read(md, rd->cmd, rbuf, 2); in ls041y3_esd_check_mode2() 357 rd++; in ls041y3_esd_check_mode2() 359 for (i = 0; i < 3; i++, rd++) { in ls041y3_esd_check_mode2() 361 mipid_write(md, rd->cmd, (u8 *)rd->wbuf, rd->wlen); in ls041y3_esd_check_mode2()
|
/drivers/net/wireless/broadcom/brcm80211/brcmfmac/ |
D | sdio.c | 1359 struct brcmf_sdio_hdrinfo *rd, in brcmf_sdio_hdparse() argument 1387 (roundup(len, bus->blocksize) != rd->len)) { in brcmf_sdio_hdparse() 1391 if (type == BRCMF_SDIO_FT_SUB && len > rd->len) { in brcmf_sdio_hdparse() 1395 rd->len = len; in brcmf_sdio_hdparse() 1402 rd->len = 0; in brcmf_sdio_hdparse() 1406 rd->channel = (swheader & SDPCM_CHANNEL_MASK) >> SDPCM_CHANNEL_SHIFT; in brcmf_sdio_hdparse() 1407 if (len > MAX_RX_DATASZ && rd->channel != SDPCM_CONTROL_CHANNEL && in brcmf_sdio_hdparse() 1412 rd->len = 0; in brcmf_sdio_hdparse() 1415 if (type == BRCMF_SDIO_FT_SUPER && rd->channel != SDPCM_GLOM_CHANNEL) { in brcmf_sdio_hdparse() 1417 rd->len = 0; in brcmf_sdio_hdparse() [all …]
|
/drivers/net/vxlan/ |
D | vxlan_core.c | 365 struct vxlan_rdst *rd, int type) in __vxlan_fdb_notify() argument 375 err = vxlan_fdb_info(skb, vxlan, fdb, 0, 0, type, 0, rd); in __vxlan_fdb_notify() 392 const struct vxlan_rdst *rd, in vxlan_fdb_switchdev_notifier_info() argument 398 fdb_info->remote_ip = rd->remote_ip; in vxlan_fdb_switchdev_notifier_info() 399 fdb_info->remote_port = rd->remote_port; in vxlan_fdb_switchdev_notifier_info() 400 fdb_info->remote_vni = rd->remote_vni; in vxlan_fdb_switchdev_notifier_info() 401 fdb_info->remote_ifindex = rd->remote_ifindex; in vxlan_fdb_switchdev_notifier_info() 404 fdb_info->offloaded = rd->offloaded; in vxlan_fdb_switchdev_notifier_info() 410 struct vxlan_rdst *rd, in vxlan_fdb_switchdev_call_notifiers() argument 418 if (WARN_ON(!rd)) in vxlan_fdb_switchdev_call_notifiers() [all …]
|
/drivers/net/ethernet/hisilicon/hns/ |
D | hns_enet.c | 1279 struct hns_nic_ring_data *rd; in hns_nic_init_irq() local 1285 rd = &priv->ring_data[i]; in hns_nic_init_irq() 1287 if (rd->ring->irq_init_flag == RCB_IRQ_INITED) in hns_nic_init_irq() 1290 snprintf(rd->ring->ring_name, RCB_RING_NAME_LEN, in hns_nic_init_irq() 1292 (is_tx_ring(rd->ring) ? "tx" : "rx"), rd->queue_index); in hns_nic_init_irq() 1294 rd->ring->ring_name[RCB_RING_NAME_LEN - 1] = '\0'; in hns_nic_init_irq() 1296 irq_set_status_flags(rd->ring->irq, IRQ_NOAUTOEN); in hns_nic_init_irq() 1297 ret = request_irq(rd->ring->irq, in hns_nic_init_irq() 1298 hns_irq_handle, 0, rd->ring->ring_name, rd); in hns_nic_init_irq() 1301 rd->ring->irq); in hns_nic_init_irq() [all …]
|
/drivers/net/ethernet/ |
D | korina.c | 187 struct dma_desc *rd) in korina_start_rx() argument 189 korina_start_dma(lp->rx_dma_regs, CPHYSADDR(rd)); in korina_start_rx() 193 struct dma_desc *rd) in korina_chain_rx() argument 195 korina_chain_dma(lp->rx_dma_regs, CPHYSADDR(rd)); in korina_chain_rx() 354 struct dma_desc *rd = &lp->rd_ring[lp->rx_next_done]; in korina_rx() local 360 dma_cache_inv((u32)rd, sizeof(*rd)); in korina_rx() 366 devcs = rd->devcs; in korina_rx() 368 if ((KORINA_RBSIZE - (u32)DMA_COUNT(rd->control)) == 0) in korina_rx() 425 rd->devcs = 0; in korina_rx() 429 rd->ca = CPHYSADDR(skb_new->data); in korina_rx() [all …]
|
/drivers/net/hamradio/ |
D | hdlcdrv.c | 444 s->hdlcrx.hbuf.rd = s->hdlcrx.hbuf.wr = 0; in hdlcdrv_open() 448 s->hdlctx.hbuf.rd = s->hdlctx.hbuf.wr = 0; in hdlcdrv_open() 576 if (s->bitbuf_channel.rd == s->bitbuf_channel.wr) in hdlcdrv_ioctl() 579 s->bitbuf_channel.buffer[s->bitbuf_channel.rd]; in hdlcdrv_ioctl() 580 s->bitbuf_channel.rd = (s->bitbuf_channel.rd+1) % in hdlcdrv_ioctl() 589 if (s->bitbuf_hdlc.rd == s->bitbuf_hdlc.wr) in hdlcdrv_ioctl() 592 s->bitbuf_hdlc.buffer[s->bitbuf_hdlc.rd]; in hdlcdrv_ioctl() 593 s->bitbuf_hdlc.rd = (s->bitbuf_hdlc.rd+1) % in hdlcdrv_ioctl() 641 s->hdlcrx.hbuf.rd = s->hdlcrx.hbuf.wr = 0; in hdlcdrv_setup() 646 s->hdlctx.hbuf.rd = s->hdlctx.hbuf.wr = 0; in hdlcdrv_setup() [all …]
|