Home
last modified time | relevance | path

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

12

/linux-4.19.296/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()
98 static int r9701_set_datetime(struct device *dev, struct rtc_time *dt) in r9701_set_datetime() argument
102 year = dt->tm_year + 1900; in r9701_set_datetime()
[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-max6916.c57 static int max6916_read_time(struct device *dev, struct rtc_time *dt) in max6916_read_time() argument
70 dt->tm_sec = bcd2bin(buf[0]); in max6916_read_time()
71 dt->tm_min = bcd2bin(buf[1]); in max6916_read_time()
72 dt->tm_hour = bcd2bin(buf[2] & 0x3F); in max6916_read_time()
73 dt->tm_mday = bcd2bin(buf[3]); in max6916_read_time()
74 dt->tm_mon = bcd2bin(buf[4]) - 1; in max6916_read_time()
75 dt->tm_wday = bcd2bin(buf[5]) - 1; in max6916_read_time()
76 dt->tm_year = bcd2bin(buf[6]) + 100; in max6916_read_time()
81 static int max6916_set_time(struct device *dev, struct rtc_time *dt) in max6916_set_time() argument
86 if (dt->tm_year < 100 || dt->tm_year > 199) { in max6916_set_time()
[all …]
Drtc-ds1347.c48 static int ds1347_read_time(struct device *dev, struct rtc_time *dt) in ds1347_read_time() argument
61 dt->tm_sec = bcd2bin(buf[0]); in ds1347_read_time()
62 dt->tm_min = bcd2bin(buf[1]); in ds1347_read_time()
63 dt->tm_hour = bcd2bin(buf[2] & 0x3F); in ds1347_read_time()
64 dt->tm_mday = bcd2bin(buf[3]); in ds1347_read_time()
65 dt->tm_mon = bcd2bin(buf[4]) - 1; in ds1347_read_time()
66 dt->tm_wday = bcd2bin(buf[5]) - 1; in ds1347_read_time()
67 dt->tm_year = bcd2bin(buf[6]) + 100; in ds1347_read_time()
72 static int ds1347_set_time(struct device *dev, struct rtc_time *dt) in ds1347_set_time() argument
80 buf[0] = bin2bcd(dt->tm_sec); in ds1347_set_time()
[all …]
Drtc-v3020.c212 static int v3020_read_time(struct device *dev, struct rtc_time *dt) in v3020_read_time() argument
222 dt->tm_sec = bcd2bin(tmp); in v3020_read_time()
224 dt->tm_min = bcd2bin(tmp); in v3020_read_time()
226 dt->tm_hour = bcd2bin(tmp); in v3020_read_time()
228 dt->tm_mday = bcd2bin(tmp); in v3020_read_time()
230 dt->tm_mon = bcd2bin(tmp) - 1; in v3020_read_time()
232 dt->tm_wday = bcd2bin(tmp); in v3020_read_time()
234 dt->tm_year = bcd2bin(tmp)+100; in v3020_read_time()
237 dev_dbg(dev, "tm_hour: %i\n", dt->tm_hour); in v3020_read_time()
238 dev_dbg(dev, "tm_min : %i\n", dt->tm_min); in v3020_read_time()
[all …]
Drtc-ds1390.c130 static int ds1390_read_time(struct device *dev, struct rtc_time *dt) in ds1390_read_time() argument
146 dt->tm_sec = bcd2bin(chip->txrx_buf[0]); in ds1390_read_time()
147 dt->tm_min = bcd2bin(chip->txrx_buf[1]); in ds1390_read_time()
148 dt->tm_hour = bcd2bin(chip->txrx_buf[2]); in ds1390_read_time()
149 dt->tm_wday = bcd2bin(chip->txrx_buf[3]); in ds1390_read_time()
150 dt->tm_mday = bcd2bin(chip->txrx_buf[4]); in ds1390_read_time()
152 dt->tm_mon = bcd2bin(chip->txrx_buf[5] & 0x7f) - 1; in ds1390_read_time()
154 dt->tm_year = bcd2bin(chip->txrx_buf[6]) + ((chip->txrx_buf[5] & 0x80) ? 100 : 0); in ds1390_read_time()
159 static int ds1390_set_time(struct device *dev, struct rtc_time *dt) in ds1390_set_time() argument
166 chip->txrx_buf[1] = bin2bcd(dt->tm_sec); in ds1390_set_time()
[all …]
Drtc-pcf8583.c52 static int pcf8583_get_datetime(struct i2c_client *client, struct rtc_time *dt) in pcf8583_get_datetime() argument
74 dt->tm_year = buf[4] >> 6; in pcf8583_get_datetime()
75 dt->tm_wday = buf[5] >> 5; in pcf8583_get_datetime()
80 dt->tm_sec = bcd2bin(buf[1]); in pcf8583_get_datetime()
81 dt->tm_min = bcd2bin(buf[2]); in pcf8583_get_datetime()
82 dt->tm_hour = bcd2bin(buf[3]); in pcf8583_get_datetime()
83 dt->tm_mday = bcd2bin(buf[4]); in pcf8583_get_datetime()
84 dt->tm_mon = bcd2bin(buf[5]) - 1; in pcf8583_get_datetime()
90 static int pcf8583_set_datetime(struct i2c_client *client, struct rtc_time *dt, int datetoo) in pcf8583_set_datetime() argument
98 buf[3] = bin2bcd(dt->tm_sec); in pcf8583_set_datetime()
[all …]
Drtc-rx8025.c182 static int rx8025_get_time(struct device *dev, struct rtc_time *dt) in rx8025_get_time() argument
201 dt->tm_sec = bcd2bin(date[RX8025_REG_SEC] & 0x7f); in rx8025_get_time()
202 dt->tm_min = bcd2bin(date[RX8025_REG_MIN] & 0x7f); in rx8025_get_time()
204 dt->tm_hour = bcd2bin(date[RX8025_REG_HOUR] & 0x3f); in rx8025_get_time()
206 dt->tm_hour = bcd2bin(date[RX8025_REG_HOUR] & 0x1f) % 12 in rx8025_get_time()
209 dt->tm_mday = bcd2bin(date[RX8025_REG_MDAY] & 0x3f); in rx8025_get_time()
210 dt->tm_mon = bcd2bin(date[RX8025_REG_MONTH] & 0x1f) - 1; in rx8025_get_time()
211 dt->tm_year = bcd2bin(date[RX8025_REG_YEAR]) + 100; in rx8025_get_time()
214 dt->tm_sec, dt->tm_min, dt->tm_hour, in rx8025_get_time()
215 dt->tm_mday, dt->tm_mon, dt->tm_year); in rx8025_get_time()
[all …]
Drtc-rx8010.c112 static int rx8010_get_time(struct device *dev, struct rtc_time *dt) in rx8010_get_time() argument
133 dt->tm_sec = bcd2bin(date[RX8010_SEC - RX8010_SEC] & 0x7f); in rx8010_get_time()
134 dt->tm_min = bcd2bin(date[RX8010_MIN - RX8010_SEC] & 0x7f); in rx8010_get_time()
135 dt->tm_hour = bcd2bin(date[RX8010_HOUR - RX8010_SEC] & 0x3f); in rx8010_get_time()
136 dt->tm_mday = bcd2bin(date[RX8010_MDAY - RX8010_SEC] & 0x3f); in rx8010_get_time()
137 dt->tm_mon = bcd2bin(date[RX8010_MONTH - RX8010_SEC] & 0x1f) - 1; in rx8010_get_time()
138 dt->tm_year = bcd2bin(date[RX8010_YEAR - RX8010_SEC]) + 100; in rx8010_get_time()
139 dt->tm_wday = ffs(date[RX8010_WDAY - RX8010_SEC] & 0x7f); in rx8010_get_time()
144 static int rx8010_set_time(struct device *dev, struct rtc_time *dt) in rx8010_set_time() argument
151 if ((dt->tm_year < 100) || (dt->tm_year > 199)) in rx8010_set_time()
[all …]
Drtc-ds1343.c239 static int ds1343_read_time(struct device *dev, struct rtc_time *dt) in ds1343_read_time() argument
249 dt->tm_sec = bcd2bin(buf[0]); in ds1343_read_time()
250 dt->tm_min = bcd2bin(buf[1]); in ds1343_read_time()
251 dt->tm_hour = bcd2bin(buf[2] & 0x3F); in ds1343_read_time()
252 dt->tm_wday = bcd2bin(buf[3]) - 1; in ds1343_read_time()
253 dt->tm_mday = bcd2bin(buf[4]); in ds1343_read_time()
254 dt->tm_mon = bcd2bin(buf[5] & 0x1F) - 1; in ds1343_read_time()
255 dt->tm_year = bcd2bin(buf[6]) + 100; /* year offset from 1900 */ in ds1343_read_time()
260 static int ds1343_set_time(struct device *dev, struct rtc_time *dt) in ds1343_set_time() argument
266 bin2bcd(dt->tm_sec)); in ds1343_set_time()
[all …]
/linux-4.19.296/drivers/iio/
Dindustrialio-sw-device.c71 void iio_unregister_sw_device_type(struct iio_sw_device_type *dt) in iio_unregister_sw_device_type() argument
76 iter = __iio_find_sw_device_type(dt->name, strlen(dt->name)); in iio_unregister_sw_device_type()
78 list_del(&dt->list); in iio_unregister_sw_device_type()
81 configfs_unregister_default_group(dt->group); in iio_unregister_sw_device_type()
88 struct iio_sw_device_type *dt; in iio_get_sw_device_type() local
91 dt = __iio_find_sw_device_type(name, strlen(name)); in iio_get_sw_device_type()
92 if (dt && !try_module_get(dt->owner)) in iio_get_sw_device_type()
93 dt = NULL; in iio_get_sw_device_type()
96 return dt; in iio_get_sw_device_type()
102 struct iio_sw_device_type *dt; in iio_sw_device_create() local
[all …]
/linux-4.19.296/lib/zstd/
Dfse_decompress.c95 size_t FSE_buildDTable_wksp(FSE_DTable *dt, const short *normalizedCounter, unsigned maxSymbolValue… in FSE_buildDTable_wksp() argument
97 void *const tdPtr = dt + 1; /* because *dt is unsigned, 32-bits aligned on 32-bits */ in FSE_buildDTable_wksp()
132 memcpy(dt, &DTableH, sizeof(DTableH)); in FSE_buildDTable_wksp()
170 size_t FSE_buildDTable_rle(FSE_DTable *dt, BYTE symbolValue) in FSE_buildDTable_rle() argument
172 void *ptr = dt; in FSE_buildDTable_rle()
174 void *dPtr = dt + 1; in FSE_buildDTable_rle()
187 size_t FSE_buildDTable_raw(FSE_DTable *dt, unsigned nbBits) in FSE_buildDTable_raw() argument
189 void *ptr = dt; in FSE_buildDTable_raw()
191 void *dPtr = dt + 1; in FSE_buildDTable_raw()
214 …able_generic(void *dst, size_t maxDstSize, const void *cSrc, size_t cSrcSize, const FSE_DTable *dt, in FSE_decompress_usingDTable_generic() argument
[all …]
Dhuf_decompress.c96 HUF_DEltX2 *const dt = (HUF_DEltX2 *)dtPtr; in HUF_readDTableX2_wksp() local
150 dt[u] = D; in HUF_readDTableX2_wksp()
158 static BYTE HUF_decodeSymbolX2(BIT_DStream_t *Dstream, const HUF_DEltX2 *dt, const U32 dtLog) in HUF_decodeSymbolX2() argument
161 BYTE const c = dt[val].byte; in HUF_decodeSymbolX2()
162 BIT_skipBits(Dstream, dt[val].nbBits); in HUF_decodeSymbolX2()
166 #define HUF_DECODE_SYMBOLX2_0(ptr, DStreamPtr) *ptr++ = HUF_decodeSymbolX2(DStreamPtr, dt, dtLog)
176 …TE *p, BIT_DStream_t *const bitDPtr, BYTE *const pEnd, const HUF_DEltX2 *const dt, const U32 dtLog) in HUF_decodeStreamX2() argument
204 const HUF_DEltX2 *const dt = (const HUF_DEltX2 *)dtPtr; in HUF_decompress1X2_usingDTable_internal() local
215 HUF_decodeStreamX2(op, &bitD, oend, dt, dtLog); in HUF_decompress1X2_usingDTable_internal()
258 const HUF_DEltX2 *const dt = (const HUF_DEltX2 *)dtPtr; in HUF_decompress4X2_usingDTable_internal() local
[all …]
Dfse.h190 FSE_PUBLIC_API size_t FSE_buildDTable_wksp(FSE_DTable *dt, const short *normalizedCounter, unsigned…
197 …singDTable(void *dst, size_t dstCapacity, const void *cSrc, size_t cSrcSize, const FSE_DTable *dt);
278 size_t FSE_buildDTable_raw(FSE_DTable *dt, unsigned nbBits);
281 size_t FSE_buildDTable_rle(FSE_DTable *dt, unsigned char symbolValue);
358 static void FSE_initDState(FSE_DState_t *DStatePtr, BIT_DStream_t *bitD, const FSE_DTable *dt);
481 ZSTD_STATIC void FSE_initDState(FSE_DState_t *DStatePtr, BIT_DStream_t *bitD, const FSE_DTable *dt) in FSE_initDState() argument
483 const void *ptr = dt; in FSE_initDState()
487 DStatePtr->table = dt + 1; in FSE_initDState()
/linux-4.19.296/lib/
Ddynamic_debug.c142 struct ddebug_table *dt; in ddebug_change() local
149 list_for_each_entry(dt, &ddebug_tables, link) { in ddebug_change()
153 !match_wildcard(query->module, dt->mod_name)) in ddebug_change()
156 for (i = 0; i < dt->num_ddebugs; i++) { in ddebug_change()
157 struct _ddebug *dp = &dt->ddebugs[i]; in ddebug_change()
201 dt->mod_name, dp->function, in ddebug_change()
851 struct ddebug_table *dt; in ddebug_add_module() local
854 dt = kzalloc(sizeof(*dt), GFP_KERNEL); in ddebug_add_module()
855 if (dt == NULL) in ddebug_add_module()
859 kfree(dt); in ddebug_add_module()
[all …]
Dwin_minmax.c32 u32 dt = val->t - m->s[0].t; in minmax_subwin_update() local
34 if (unlikely(dt > win)) { in minmax_subwin_update()
50 } else if (unlikely(m->s[1].t == m->s[0].t) && dt > win/4) { in minmax_subwin_update()
56 } else if (unlikely(m->s[2].t == m->s[1].t) && dt > win/2) { in minmax_subwin_update()
/linux-4.19.296/drivers/iio/pressure/
Dms5611_core.c127 s64 off, sens, dt; in ms5611_temp_and_pressure_compensate() local
129 dt = t - (st->prom[5] << 8); in ms5611_temp_and_pressure_compensate()
130 off = ((s64)st->prom[2] << 16) + ((st->prom[4] * dt) >> 7); in ms5611_temp_and_pressure_compensate()
131 sens = ((s64)st->prom[1] << 15) + ((st->prom[3] * dt) >> 8); in ms5611_temp_and_pressure_compensate()
133 t = 2000 + ((st->prom[6] * dt) >> 23); in ms5611_temp_and_pressure_compensate()
137 t2 = (dt * dt) >> 31; in ms5611_temp_and_pressure_compensate()
163 s64 off, sens, dt; in ms5607_temp_and_pressure_compensate() local
165 dt = t - (st->prom[5] << 8); in ms5607_temp_and_pressure_compensate()
166 off = ((s64)st->prom[2] << 17) + ((st->prom[4] * dt) >> 6); in ms5607_temp_and_pressure_compensate()
167 sens = ((s64)st->prom[1] << 16) + ((st->prom[3] * dt) >> 7); in ms5607_temp_and_pressure_compensate()
[all …]
/linux-4.19.296/include/linux/iio/
Dsw_device.h51 int iio_register_sw_device_type(struct iio_sw_device_type *dt);
52 void iio_unregister_sw_device_type(struct iio_sw_device_type *dt);
57 int iio_sw_device_type_configfs_register(struct iio_sw_device_type *dt);
58 void iio_sw_device_type_configfs_unregister(struct iio_sw_device_type *dt);
/linux-4.19.296/include/trace/events/
Dxen.h403 TP_PROTO(struct desc_struct *dt, int entrynum, u64 desc),
404 TP_ARGS(dt, entrynum, desc),
406 __field(struct desc_struct *, dt)
410 TP_fast_assign(__entry->dt = dt;
415 __entry->dt, __entry->entrynum,
420 TP_PROTO(gate_desc *dt, int entrynum, const gate_desc *ent),
421 TP_ARGS(dt, entrynum, ent),
423 __field(gate_desc *, dt)
426 TP_fast_assign(__entry->dt = dt;
430 __entry->dt, __entry->entrynum)
[all …]
/linux-4.19.296/drivers/edac/
Dsynopsys_edac.c268 enum dev_type dt; in synps_edac_get_dtype() local
276 dt = DEV_X2; in synps_edac_get_dtype()
279 dt = DEV_X4; in synps_edac_get_dtype()
282 dt = DEV_UNKNOWN; in synps_edac_get_dtype()
285 return dt; in synps_edac_get_dtype()
298 enum dev_type dt; in synps_edac_get_eccstate() local
302 dt = synps_edac_get_dtype(base); in synps_edac_get_eccstate()
303 if (dt == DEV_UNKNOWN) in synps_edac_get_eccstate()
307 if ((ecctype == SCRUB_MODE_SECDED) && (dt == DEV_X2)) in synps_edac_get_eccstate()
/linux-4.19.296/fs/coda/
Ddir.c329 unsigned int dt; in CDT2DT() local
332 case CDT_UNKNOWN: dt = DT_UNKNOWN; break; in CDT2DT()
333 case CDT_FIFO: dt = DT_FIFO; break; in CDT2DT()
334 case CDT_CHR: dt = DT_CHR; break; in CDT2DT()
335 case CDT_DIR: dt = DT_DIR; break; in CDT2DT()
336 case CDT_BLK: dt = DT_BLK; break; in CDT2DT()
337 case CDT_REG: dt = DT_REG; break; in CDT2DT()
338 case CDT_LNK: dt = DT_LNK; break; in CDT2DT()
339 case CDT_SOCK: dt = DT_SOCK; break; in CDT2DT()
340 case CDT_WHT: dt = DT_WHT; break; in CDT2DT()
[all …]
/linux-4.19.296/drivers/iio/common/ms_sensors/
Dms_sensors_i2c.c579 s32 dt, temp; in ms_sensors_read_temp_and_pressure() local
607 dt = (s32)t_adc - (prom[5] << 8); in ms_sensors_read_temp_and_pressure()
610 temp = 2000 + (((s64)dt * prom[6]) >> 23); in ms_sensors_read_temp_and_pressure()
616 t2 = (3 * ((s64)dt * (s64)dt)) >> 33; in ms_sensors_read_temp_and_pressure()
627 t2 = (5 * ((s64)dt * (s64)dt)) >> 38; in ms_sensors_read_temp_and_pressure()
633 off = (((s64)prom[2]) << 17) + ((((s64)prom[4]) * (s64)dt) >> 6); in ms_sensors_read_temp_and_pressure()
637 sens = (((s64)prom[1]) << 16) + (((s64)prom[3] * dt) >> 7); in ms_sensors_read_temp_and_pressure()
/linux-4.19.296/fs/exofs/
Dsuper.c477 struct exofs_device_table *dt) in _read_and_match_data_map() argument
482 le64_to_cpu(dt->dt_data_map.cb_stripe_unit); in _read_and_match_data_map()
484 le32_to_cpu(dt->dt_data_map.cb_group_width); in _read_and_match_data_map()
486 le32_to_cpu(dt->dt_data_map.cb_group_depth); in _read_and_match_data_map()
488 le32_to_cpu(dt->dt_data_map.cb_mirror_cnt) + 1; in _read_and_match_data_map()
490 le32_to_cpu(dt->dt_data_map.cb_raid_algorithm); in _read_and_match_data_map()
581 struct exofs_device_table *dt; in exofs_read_lookup_dev_table() local
583 unsigned table_bytes = table_count * sizeof(dt->dt_dev_table[0]) + in exofs_read_lookup_dev_table()
584 sizeof(*dt); in exofs_read_lookup_dev_table()
588 dt = kmalloc(table_bytes, GFP_KERNEL); in exofs_read_lookup_dev_table()
[all …]
/linux-4.19.296/include/video/
Dof_display_timing.h22 struct display_timing *dt);
26 const char *name, struct display_timing *dt) in of_get_display_timing() argument
/linux-4.19.296/drivers/media/rc/
Dsunxi-cir.c99 unsigned char dt; in sunxi_ir_irq() local
119 dt = readb(ir->base + SUNXI_IR_RXFIFO_REG); in sunxi_ir_irq()
120 rawir.pulse = (dt & 0x80) != 0; in sunxi_ir_irq()
121 rawir.duration = ((dt & 0x7f) + 1) * in sunxi_ir_irq()

12