Home
last modified time | relevance | path

Searched refs:dt (Results 1 – 25 of 44) sorted by relevance

12

/drivers/input/misc/
Dgp2ap002a00f.c42 static int gp2a_report(struct gp2a_data *dt) in gp2a_report() argument
44 int vo = gpio_get_value(dt->pdata->vout_gpio); in gp2a_report()
46 input_report_switch(dt->input, SW_FRONT_PROXIMITY, !vo); in gp2a_report()
47 input_sync(dt->input); in gp2a_report()
54 struct gp2a_data *dt = handle; in gp2a_irq() local
56 gp2a_report(dt); in gp2a_irq()
61 static int gp2a_enable(struct gp2a_data *dt) in gp2a_enable() argument
63 return i2c_smbus_write_byte_data(dt->i2c_client, GP2A_ADDR_OPMOD, in gp2a_enable()
67 static int gp2a_disable(struct gp2a_data *dt) in gp2a_disable() argument
69 return i2c_smbus_write_byte_data(dt->i2c_client, GP2A_ADDR_OPMOD, in gp2a_disable()
[all …]
/drivers/rtc/
Drtc-r9701.c71 static int r9701_get_datetime(struct device *dev, struct rtc_time *dt) in r9701_get_datetime() argument
81 memset(dt, 0, sizeof(*dt)); in r9701_get_datetime()
83 dt->tm_sec = bcd2bin(buf[0]); /* RSECCNT */ in r9701_get_datetime()
84 dt->tm_min = bcd2bin(buf[1]); /* RMINCNT */ in r9701_get_datetime()
85 dt->tm_hour = bcd2bin(buf[2]); /* RHRCNT */ in r9701_get_datetime()
87 dt->tm_mday = bcd2bin(buf[3]); /* RDAYCNT */ in r9701_get_datetime()
88 dt->tm_mon = bcd2bin(buf[4]) - 1; /* RMONCNT */ in r9701_get_datetime()
89 dt->tm_year = bcd2bin(buf[5]) + 100; /* RYRCNT */ in r9701_get_datetime()
95 return rtc_valid_tm(dt); in r9701_get_datetime()
98 static int r9701_set_datetime(struct device *dev, struct rtc_time *dt) in r9701_set_datetime() argument
[all …]
Drtc-max6902.c56 static int max6902_read_time(struct device *dev, struct rtc_time *dt) in max6902_read_time() argument
70 dt->tm_sec = bcd2bin(buf[0]); in max6902_read_time()
71 dt->tm_min = bcd2bin(buf[1]); in max6902_read_time()
72 dt->tm_hour = bcd2bin(buf[2]); in max6902_read_time()
73 dt->tm_mday = bcd2bin(buf[3]); in max6902_read_time()
74 dt->tm_mon = bcd2bin(buf[4]) - 1; in max6902_read_time()
75 dt->tm_wday = bcd2bin(buf[5]); in max6902_read_time()
76 dt->tm_year = bcd2bin(buf[6]); in max6902_read_time()
85 dt->tm_year += century; in max6902_read_time()
86 dt->tm_year -= 1900; in max6902_read_time()
[all …]
Drtc-ds3234.c57 static int ds3234_read_time(struct device *dev, struct rtc_time *dt) in ds3234_read_time() argument
70 dt->tm_sec = bcd2bin(buf[0]); in ds3234_read_time()
71 dt->tm_min = bcd2bin(buf[1]); in ds3234_read_time()
72 dt->tm_hour = bcd2bin(buf[2] & 0x3f); in ds3234_read_time()
73 dt->tm_wday = bcd2bin(buf[3]) - 1; /* 0 = Sun */ in ds3234_read_time()
74 dt->tm_mday = bcd2bin(buf[4]); in ds3234_read_time()
75 dt->tm_mon = bcd2bin(buf[5] & 0x1f) - 1; /* 0 = Jan */ in ds3234_read_time()
76 dt->tm_year = bcd2bin(buf[6] & 0xff) + 100; /* Assume 20YY */ in ds3234_read_time()
78 return rtc_valid_tm(dt); in ds3234_read_time()
81 static int ds3234_set_time(struct device *dev, struct rtc_time *dt) in ds3234_set_time() argument
[all …]
Drtc-ds1390.c70 static int ds1390_read_time(struct device *dev, struct rtc_time *dt) in ds1390_read_time() argument
86 dt->tm_sec = bcd2bin(chip->txrx_buf[0]); in ds1390_read_time()
87 dt->tm_min = bcd2bin(chip->txrx_buf[1]); in ds1390_read_time()
88 dt->tm_hour = bcd2bin(chip->txrx_buf[2]); in ds1390_read_time()
89 dt->tm_wday = bcd2bin(chip->txrx_buf[3]); in ds1390_read_time()
90 dt->tm_mday = bcd2bin(chip->txrx_buf[4]); in ds1390_read_time()
92 dt->tm_mon = bcd2bin(chip->txrx_buf[5] & 0x7f) - 1; in ds1390_read_time()
94 dt->tm_year = bcd2bin(chip->txrx_buf[6]) + ((chip->txrx_buf[5] & 0x80) ? 100 : 0); in ds1390_read_time()
96 return rtc_valid_tm(dt); in ds1390_read_time()
99 static int ds1390_set_time(struct device *dev, struct rtc_time *dt) in ds1390_set_time() argument
[all …]
Drtc-v3020.c231 static int v3020_read_time(struct device *dev, struct rtc_time *dt) in v3020_read_time() argument
241 dt->tm_sec = bcd2bin(tmp); in v3020_read_time()
243 dt->tm_min = bcd2bin(tmp); in v3020_read_time()
245 dt->tm_hour = bcd2bin(tmp); in v3020_read_time()
247 dt->tm_mday = bcd2bin(tmp); in v3020_read_time()
249 dt->tm_mon = bcd2bin(tmp) - 1; in v3020_read_time()
251 dt->tm_wday = bcd2bin(tmp); in v3020_read_time()
253 dt->tm_year = bcd2bin(tmp)+100; in v3020_read_time()
256 dev_dbg(dev, "tm_hour: %i\n", dt->tm_hour); in v3020_read_time()
257 dev_dbg(dev, "tm_min : %i\n", dt->tm_min); in v3020_read_time()
[all …]
Drtc-pcf8583.c51 static int pcf8583_get_datetime(struct i2c_client *client, struct rtc_time *dt) in pcf8583_get_datetime() argument
73 dt->tm_year = buf[4] >> 6; in pcf8583_get_datetime()
74 dt->tm_wday = buf[5] >> 5; in pcf8583_get_datetime()
79 dt->tm_sec = bcd2bin(buf[1]); in pcf8583_get_datetime()
80 dt->tm_min = bcd2bin(buf[2]); in pcf8583_get_datetime()
81 dt->tm_hour = bcd2bin(buf[3]); in pcf8583_get_datetime()
82 dt->tm_mday = bcd2bin(buf[4]); in pcf8583_get_datetime()
83 dt->tm_mon = bcd2bin(buf[5]) - 1; in pcf8583_get_datetime()
89 static int pcf8583_set_datetime(struct i2c_client *client, struct rtc_time *dt, int datetoo) in pcf8583_set_datetime() argument
97 buf[3] = bin2bcd(dt->tm_sec); in pcf8583_set_datetime()
[all …]
Drtc-rx8025.c191 static int rx8025_get_time(struct device *dev, struct rtc_time *dt) in rx8025_get_time() argument
206 dt->tm_sec = bcd2bin(date[RX8025_REG_SEC] & 0x7f); in rx8025_get_time()
207 dt->tm_min = bcd2bin(date[RX8025_REG_MIN] & 0x7f); in rx8025_get_time()
209 dt->tm_hour = bcd2bin(date[RX8025_REG_HOUR] & 0x3f); in rx8025_get_time()
211 dt->tm_hour = bcd2bin(date[RX8025_REG_HOUR] & 0x1f) % 12 in rx8025_get_time()
214 dt->tm_mday = bcd2bin(date[RX8025_REG_MDAY] & 0x3f); in rx8025_get_time()
215 dt->tm_mon = bcd2bin(date[RX8025_REG_MONTH] & 0x1f) - 1; in rx8025_get_time()
216 dt->tm_year = bcd2bin(date[RX8025_REG_YEAR]); in rx8025_get_time()
218 if (dt->tm_year < 70) in rx8025_get_time()
219 dt->tm_year += 100; in rx8025_get_time()
[all …]
Drtc-ds2404.c202 static int ds2404_read_time(struct device *dev, struct rtc_time *dt) in ds2404_read_time() argument
209 rtc_time_to_tm(time, dt); in ds2404_read_time()
210 return rtc_valid_tm(dt); in ds2404_read_time()
/drivers/video/
Dof_display_timing.c61 struct display_timing *dt; in of_get_display_timing() local
65 dt = kzalloc(sizeof(*dt), GFP_KERNEL); in of_get_display_timing()
66 if (!dt) { in of_get_display_timing()
72 ret |= parse_timing_property(np, "hback-porch", &dt->hback_porch); in of_get_display_timing()
73 ret |= parse_timing_property(np, "hfront-porch", &dt->hfront_porch); in of_get_display_timing()
74 ret |= parse_timing_property(np, "hactive", &dt->hactive); in of_get_display_timing()
75 ret |= parse_timing_property(np, "hsync-len", &dt->hsync_len); in of_get_display_timing()
76 ret |= parse_timing_property(np, "vback-porch", &dt->vback_porch); in of_get_display_timing()
77 ret |= parse_timing_property(np, "vfront-porch", &dt->vfront_porch); in of_get_display_timing()
78 ret |= parse_timing_property(np, "vactive", &dt->vactive); in of_get_display_timing()
[all …]
Dvideomode.c14 void videomode_from_timing(const struct display_timing *dt, in videomode_from_timing() argument
17 vm->pixelclock = dt->pixelclock.typ; in videomode_from_timing()
18 vm->hactive = dt->hactive.typ; in videomode_from_timing()
19 vm->hfront_porch = dt->hfront_porch.typ; in videomode_from_timing()
20 vm->hback_porch = dt->hback_porch.typ; in videomode_from_timing()
21 vm->hsync_len = dt->hsync_len.typ; in videomode_from_timing()
23 vm->vactive = dt->vactive.typ; in videomode_from_timing()
24 vm->vfront_porch = dt->vfront_porch.typ; in videomode_from_timing()
25 vm->vback_porch = dt->vback_porch.typ; in videomode_from_timing()
26 vm->vsync_len = dt->vsync_len.typ; in videomode_from_timing()
[all …]
Dmetronomefb.c187 epd_frame_table[par->dt].wfm_size = user_wfm_size; in load_waveform()
189 if (size != epd_frame_table[par->dt].wfm_size) { in load_waveform()
191 epd_frame_table[par->dt].wfm_size); in load_waveform()
376 memcpy(par->metromem_cmd->args, epd_frame_table[par->dt].config, in metronome_config_cmd()
377 sizeof(epd_frame_table[par->dt].config)); in metronome_config_cmd()
649 par->dt = epd_dt_index; in metronomefb_probe()
/drivers/mtd/nand/
Ddenali_dt.c63 struct denali_dt *dt; in denali_dt_probe() local
76 dt = devm_kzalloc(&ofdev->dev, sizeof(*dt), GFP_KERNEL); in denali_dt_probe()
77 if (!dt) in denali_dt_probe()
79 denali = &dt->denali; in denali_dt_probe()
111 dt->clk = clk_get(&ofdev->dev, NULL); in denali_dt_probe()
112 if (IS_ERR(dt->clk)) { in denali_dt_probe()
114 return PTR_ERR(dt->clk); in denali_dt_probe()
116 clk_prepare_enable(dt->clk); in denali_dt_probe()
122 platform_set_drvdata(ofdev, dt); in denali_dt_probe()
126 clk_disable_unprepare(dt->clk); in denali_dt_probe()
[all …]
/drivers/block/drbd/
Ddrbd_proc.c71 unsigned long db, dt, dbdt, rt, rs_left; in drbd_syncer_progress() local
118 dt = (jiffies - mdev->rs_mark_time[i]) / HZ; in drbd_syncer_progress()
119 if (dt > (DRBD_SYNC_MARK_STEP * DRBD_SYNC_MARKS)) in drbd_syncer_progress()
122 if (!dt) in drbd_syncer_progress()
123 dt++; in drbd_syncer_progress()
125 rt = (dt * (rs_left / (db/100+1)))/100; /* seconds */ in drbd_syncer_progress()
130 dbdt = Bit2KB(db/dt); in drbd_syncer_progress()
138 dt = (jiffies - mdev->rs_mark_time[i]) / HZ; in drbd_syncer_progress()
139 if (!dt) in drbd_syncer_progress()
140 dt++; in drbd_syncer_progress()
[all …]
Ddrbd_actlog.c128 long dt; in wait_until_done_or_force_detached() local
131 dt = rcu_dereference(bdev->disk_conf)->disk_timeout; in wait_until_done_or_force_detached()
133 dt = dt * HZ / 10; in wait_until_done_or_force_detached()
134 if (dt == 0) in wait_until_done_or_force_detached()
135 dt = MAX_SCHEDULE_TIMEOUT; in wait_until_done_or_force_detached()
137 dt = wait_event_timeout(mdev->misc_wait, in wait_until_done_or_force_detached()
138 *done || test_bit(FORCE_DETACH, &mdev->flags), dt); in wait_until_done_or_force_detached()
139 if (dt == 0) { in wait_until_done_or_force_detached()
/drivers/macintosh/
Dvia-pmu-led.c84 struct device_node *dt; in via_pmu_led_init() local
91 dt = of_find_node_by_path("/"); in via_pmu_led_init()
92 if (dt == NULL) in via_pmu_led_init()
94 model = of_get_property(dt, "model", NULL); in via_pmu_led_init()
96 of_node_put(dt); in via_pmu_led_init()
103 of_node_put(dt); in via_pmu_led_init()
107 of_node_put(dt); in via_pmu_led_init()
/drivers/isdn/pcbit/
Dlayer2.h173 static __inline__ void pcbit_writeb(struct pcbit_dev *dev, unsigned char dt) in pcbit_writeb() argument
175 writeb(dt, dev->writeptr++); in pcbit_writeb()
180 static __inline__ void pcbit_writew(struct pcbit_dev *dev, unsigned short dt) in pcbit_writew() argument
187 writew(dt, dev->writeptr); in pcbit_writew()
191 writeb((u_char) (dt & 0x00ffU), dev->writeptr); in pcbit_writew()
193 writeb((u_char) (dt >> 8), dev->writeptr++); in pcbit_writew()
196 writew(dt, dev->writeptr); in pcbit_writew()
/drivers/scsi/
Dch.c109 struct scsi_device **dt; /* ptrs to data transfer elements */ member
361 ch->dt = kcalloc(ch->counts[CHET_DT], sizeof(*ch->dt), in ch_readconfig()
364 if (!ch->dt) { in ch_readconfig()
385 ch->dt[elem] = NULL; in ch_readconfig()
388 ch->dt[elem] = NULL; in ch_readconfig()
398 ch->dt[elem] = in ch_readconfig()
402 if (!ch->dt[elem]) { in ch_readconfig()
407 ch->dt[elem]->vendor, in ch_readconfig()
408 ch->dt[elem]->model, in ch_readconfig()
409 ch->dt[elem]->rev); in ch_readconfig()
[all …]
/drivers/scsi/aic7xxx/
Daic79xx_osm.c2425 unsigned int dt; in ahd_linux_set_period() local
2447 dt = ppr_options & MSG_EXT_PPR_DT_REQ; in ahd_linux_set_period()
2459 dt ? AHD_SYNCRATE_MAX : AHD_SYNCRATE_ULTRA2); in ahd_linux_set_period()
2479 unsigned int dt = ppr_options & MSG_EXT_PPR_DT_REQ; in ahd_linux_set_offset() local
2493 dt ? AHD_SYNCRATE_MAX : AHD_SYNCRATE_ULTRA2); in ahd_linux_set_offset()
2502 static void ahd_linux_set_dt(struct scsi_target *starget, int dt) in ahd_linux_set_dt() argument
2521 dt ? "enabling" : "disabling"); in ahd_linux_set_dt()
2523 if (dt && spi_max_width(starget)) { in ahd_linux_set_dt()
2536 dt ? AHD_SYNCRATE_MAX : AHD_SYNCRATE_ULTRA2); in ahd_linux_set_dt()
2557 unsigned int dt; in ahd_linux_set_qas() local
[all …]
/drivers/crypto/
Dtegra-aes.c164 u8 dt[DEFAULT_RNG_BLK_SZ]; member
669 u8 *dest = rdata, *dt = dd->dt; in tegra_aes_get_random() local
684 memcpy(dd->buf_in, dt, DEFAULT_RNG_BLK_SZ); in tegra_aes_get_random()
697 dt[i] += 1; in tegra_aes_get_random()
698 if (dt[i] != 0) in tegra_aes_get_random()
719 u8 *dt; in tegra_aes_rng_reset() local
779 dt = dd->iv + DEFAULT_RNG_BLK_SZ + AES_KEYSIZE_128; in tegra_aes_rng_reset()
788 dt = (u8 *)tmp; in tegra_aes_rng_reset()
790 memcpy(dd->dt, dt, DEFAULT_RNG_BLK_SZ); in tegra_aes_rng_reset()
/drivers/s390/crypto/
Dap_bus.h206 #define AP_DEVICE(dt) \ argument
207 .dev_type=(dt), \
/drivers/block/paride/
Dpf.c626 int dt, s; in pf_identify() local
637 dt = buf[0] & 0x1f; in pf_identify()
638 if ((dt != 0) && (dt != 7)) { in pf_identify()
641 pf->name, pf->drive, pf->lun, dt); in pf_identify()
657 pf->name, mf, id, ms[pf->drive], pf->lun, dt); in pf_identify()
/drivers/staging/iio/meter/
DKconfig11 Metering IC with di/dt Sensor Interface.
34 Metering IC with di/dt Sensor Interface.
/drivers/scsi/sym53c8xx_2/
Dsym_glue.c942 tp->tgoal.iu = tp->tgoal.dt = in sym_exec_user_command()
948 tp->tgoal.iu = tp->tgoal.dt = in sym_exec_user_command()
956 tp->tgoal.iu = tp->tgoal.dt = in sym_exec_user_command()
1923 tp->tgoal.dt = 1; in sym2_set_period()
1938 tp->tgoal.iu = tp->tgoal.dt = tp->tgoal.qas = 0; in sym2_set_width()
1944 static void sym2_set_dt(struct scsi_target *starget, int dt) in sym2_set_dt() argument
1951 if (dt) in sym2_set_dt()
1952 tp->tgoal.dt = 1; in sym2_set_dt()
1954 tp->tgoal.iu = tp->tgoal.dt = tp->tgoal.qas = 0; in sym2_set_dt()
1966 tp->tgoal.iu = tp->tgoal.dt = 1;
[all …]
/drivers/sh/clk/
Dcpg.c107 struct clk_div_table *dt = clk_to_div_table(clk); in sh_clk_div_set_rate() local
121 if (dt->kick) in sh_clk_div_set_rate()
122 dt->kick(clk); in sh_clk_div_set_rate()

12