/linux-4.1.27/arch/m68k/sun3x/ |
H A D | time.c | 49 h->sec = bin2bcd(t->tm_sec); sun3x_hwclk() 50 h->min = bin2bcd(t->tm_min); sun3x_hwclk() 51 h->hour = bin2bcd(t->tm_hour); sun3x_hwclk() 52 h->wday = bin2bcd(t->tm_wday); sun3x_hwclk() 53 h->mday = bin2bcd(t->tm_mday); sun3x_hwclk() 54 h->month = bin2bcd(t->tm_mon); sun3x_hwclk() 55 h->year = bin2bcd(t->tm_year); sun3x_hwclk()
|
/linux-4.1.27/include/linux/ |
H A D | bcd.h | 11 #define bin2bcd(x) \ macro
|
/linux-4.1.27/drivers/rtc/ |
H A D | rtc-max6902.c | 98 max6902_set_reg(dev, MAX6902_REG_SECONDS, bin2bcd(dt->tm_sec)); max6902_set_time() 99 max6902_set_reg(dev, MAX6902_REG_MINUTES, bin2bcd(dt->tm_min)); max6902_set_time() 100 max6902_set_reg(dev, MAX6902_REG_HOURS, bin2bcd(dt->tm_hour)); max6902_set_time() 102 max6902_set_reg(dev, MAX6902_REG_DATE, bin2bcd(dt->tm_mday)); max6902_set_time() 103 max6902_set_reg(dev, MAX6902_REG_MONTH, bin2bcd(dt->tm_mon + 1)); max6902_set_time() 104 max6902_set_reg(dev, MAX6902_REG_DAY, bin2bcd(dt->tm_wday)); max6902_set_time() 105 max6902_set_reg(dev, MAX6902_REG_YEAR, bin2bcd(dt->tm_year % 100)); max6902_set_time() 106 max6902_set_reg(dev, MAX6902_REG_CENTURY, bin2bcd(dt->tm_year / 100)); max6902_set_time()
|
H A D | rtc-em3027.c | 95 buf[1] = bin2bcd(tm->tm_sec); em3027_set_time() 96 buf[2] = bin2bcd(tm->tm_min); em3027_set_time() 97 buf[3] = bin2bcd(tm->tm_hour); em3027_set_time() 98 buf[4] = bin2bcd(tm->tm_mday); em3027_set_time() 99 buf[5] = bin2bcd(tm->tm_wday); em3027_set_time() 100 buf[6] = bin2bcd(tm->tm_mon); em3027_set_time() 101 buf[7] = bin2bcd(tm->tm_year % 100); em3027_set_time()
|
H A D | rtc-m41t94.c | 44 buf[M41T94_REG_SECONDS] = bin2bcd(tm->tm_sec); m41t94_set_time() 45 buf[M41T94_REG_MINUTES] = bin2bcd(tm->tm_min); m41t94_set_time() 46 buf[M41T94_REG_HOURS] = bin2bcd(tm->tm_hour); m41t94_set_time() 47 buf[M41T94_REG_WDAY] = bin2bcd(tm->tm_wday + 1); m41t94_set_time() 48 buf[M41T94_REG_DAY] = bin2bcd(tm->tm_mday); m41t94_set_time() 49 buf[M41T94_REG_MONTH] = bin2bcd(tm->tm_mon + 1); m41t94_set_time() 54 buf[M41T94_REG_YEAR] = bin2bcd(tm->tm_year % 100); m41t94_set_time()
|
H A D | rtc-ds1216.c | 117 regs.sec = bin2bcd(tm->tm_sec); ds1216_rtc_set_time() 118 regs.min = bin2bcd(tm->tm_min); ds1216_rtc_set_time() 124 regs.hour |= bin2bcd(tm->tm_hour); ds1216_rtc_set_time() 127 regs.mday = bin2bcd(tm->tm_mday); ds1216_rtc_set_time() 128 regs.month = bin2bcd(tm->tm_mon); ds1216_rtc_set_time() 129 regs.year = bin2bcd(tm->tm_year % 100); ds1216_rtc_set_time()
|
H A D | rtc-mv.c | 54 rtc_reg = (bin2bcd(tm->tm_sec) << RTC_SECONDS_OFFS) | mv_rtc_set_time() 55 (bin2bcd(tm->tm_min) << RTC_MINUTES_OFFS) | mv_rtc_set_time() 56 (bin2bcd(tm->tm_hour) << RTC_HOURS_OFFS) | mv_rtc_set_time() 57 (bin2bcd(tm->tm_wday) << RTC_WDAY_OFFS); mv_rtc_set_time() 60 rtc_reg = (bin2bcd(tm->tm_mday) << RTC_MDAY_OFFS) | mv_rtc_set_time() 61 (bin2bcd(tm->tm_mon + 1) << RTC_MONTH_OFFS) | mv_rtc_set_time() 62 (bin2bcd(tm->tm_year % 100) << RTC_YEAR_OFFS); mv_rtc_set_time() 143 rtc_reg |= (RTC_ALARM_VALID | bin2bcd(alm->time.tm_sec)) mv_rtc_set_alarm() 146 rtc_reg |= (RTC_ALARM_VALID | bin2bcd(alm->time.tm_min)) mv_rtc_set_alarm() 149 rtc_reg |= (RTC_ALARM_VALID | bin2bcd(alm->time.tm_hour)) mv_rtc_set_alarm() 155 rtc_reg = (RTC_ALARM_VALID | bin2bcd(alm->time.tm_mday)) mv_rtc_set_alarm() 161 rtc_reg |= (RTC_ALARM_VALID | bin2bcd(alm->time.tm_mon + 1)) mv_rtc_set_alarm() 165 rtc_reg |= (RTC_ALARM_VALID | bin2bcd(alm->time.tm_year % 100)) mv_rtc_set_alarm()
|
H A D | rtc-tps80031.c | 94 buff[0] = bin2bcd(tm->tm_sec); tps80031_rtc_set_time() 95 buff[1] = bin2bcd(tm->tm_min); tps80031_rtc_set_time() 96 buff[2] = bin2bcd(tm->tm_hour); tps80031_rtc_set_time() 97 buff[3] = bin2bcd(tm->tm_mday); tps80031_rtc_set_time() 98 buff[4] = bin2bcd(tm->tm_mon + 1); tps80031_rtc_set_time() 99 buff[5] = bin2bcd(tm->tm_year % RTC_YEAR_OFFSET); tps80031_rtc_set_time() 100 buff[6] = bin2bcd(tm->tm_wday); tps80031_rtc_set_time() 148 buff[0] = bin2bcd(alrm->time.tm_sec); tps80031_rtc_set_alarm() 149 buff[1] = bin2bcd(alrm->time.tm_min); tps80031_rtc_set_alarm() 150 buff[2] = bin2bcd(alrm->time.tm_hour); tps80031_rtc_set_alarm() 151 buff[3] = bin2bcd(alrm->time.tm_mday); tps80031_rtc_set_alarm() 152 buff[4] = bin2bcd(alrm->time.tm_mon + 1); tps80031_rtc_set_alarm() 153 buff[5] = bin2bcd(alrm->time.tm_year % RTC_YEAR_OFFSET); tps80031_rtc_set_alarm()
|
H A D | rtc-ds1347.c | 86 buf[1] = bin2bcd(dt->tm_sec); ds1347_set_time() 87 buf[2] = bin2bcd(dt->tm_min); ds1347_set_time() 88 buf[3] = (bin2bcd(dt->tm_hour) & 0x3F); ds1347_set_time() 89 buf[4] = bin2bcd(dt->tm_mday); ds1347_set_time() 90 buf[5] = bin2bcd(dt->tm_mon + 1); ds1347_set_time() 91 buf[6] = bin2bcd(dt->tm_wday + 1); ds1347_set_time() 97 buf[7] = bin2bcd(dt->tm_year); ds1347_set_time() 98 buf[8] = bin2bcd(0x00); ds1347_set_time()
|
H A D | rtc-max6900.c | 180 regs[MAX6900_REG_SC] = bin2bcd(tm->tm_sec); max6900_i2c_set_time() 181 regs[MAX6900_REG_MN] = bin2bcd(tm->tm_min); max6900_i2c_set_time() 182 regs[MAX6900_REG_HR] = bin2bcd(tm->tm_hour); max6900_i2c_set_time() 183 regs[MAX6900_REG_DT] = bin2bcd(tm->tm_mday); max6900_i2c_set_time() 184 regs[MAX6900_REG_MO] = bin2bcd(tm->tm_mon + 1); max6900_i2c_set_time() 185 regs[MAX6900_REG_DW] = bin2bcd(tm->tm_wday); max6900_i2c_set_time() 186 regs[MAX6900_REG_YR] = bin2bcd(tm->tm_year % 100); max6900_i2c_set_time() 187 regs[MAX6900_REG_CENTURY] = bin2bcd((tm->tm_year + 1900) / 100); max6900_i2c_set_time()
|
H A D | rtc-rc5t583.c | 99 rtc_data[0] = bin2bcd(tm->tm_sec); rc5t583_rtc_set_time() 100 rtc_data[1] = bin2bcd(tm->tm_min); rc5t583_rtc_set_time() 101 rtc_data[2] = bin2bcd(tm->tm_hour); rc5t583_rtc_set_time() 102 rtc_data[3] = bin2bcd(tm->tm_wday); rc5t583_rtc_set_time() 103 rtc_data[4] = bin2bcd(tm->tm_mday); rc5t583_rtc_set_time() 104 rtc_data[5] = bin2bcd(tm->tm_mon + 1); rc5t583_rtc_set_time() 105 rtc_data[6] = bin2bcd(tm->tm_year - 100); rc5t583_rtc_set_time() 158 alarm_data[0] = bin2bcd(alm->time.tm_min); rc5t583_rtc_set_alarm() 159 alarm_data[1] = bin2bcd(alm->time.tm_hour); rc5t583_rtc_set_alarm() 160 alarm_data[2] = bin2bcd(alm->time.tm_mday); rc5t583_rtc_set_alarm() 161 alarm_data[3] = bin2bcd(alm->time.tm_mon + 1); rc5t583_rtc_set_alarm() 162 alarm_data[4] = bin2bcd(alm->time.tm_year - 100); rc5t583_rtc_set_alarm()
|
H A D | rtc-tps65910.c | 93 rtc_data[0] = bin2bcd(tm->tm_sec); tps65910_rtc_set_time() 94 rtc_data[1] = bin2bcd(tm->tm_min); tps65910_rtc_set_time() 95 rtc_data[2] = bin2bcd(tm->tm_hour); tps65910_rtc_set_time() 96 rtc_data[3] = bin2bcd(tm->tm_mday); tps65910_rtc_set_time() 97 rtc_data[4] = bin2bcd(tm->tm_mon + 1); tps65910_rtc_set_time() 98 rtc_data[5] = bin2bcd(tm->tm_year - 100); tps65910_rtc_set_time() 169 alarm_data[0] = bin2bcd(alm->time.tm_sec); tps65910_rtc_set_alarm() 170 alarm_data[1] = bin2bcd(alm->time.tm_min); tps65910_rtc_set_alarm() 171 alarm_data[2] = bin2bcd(alm->time.tm_hour); tps65910_rtc_set_alarm() 172 alarm_data[3] = bin2bcd(alm->time.tm_mday); tps65910_rtc_set_alarm() 173 alarm_data[4] = bin2bcd(alm->time.tm_mon + 1); tps65910_rtc_set_alarm() 174 alarm_data[5] = bin2bcd(alm->time.tm_year - 100); tps65910_rtc_set_alarm()
|
H A D | rtc-vt8500.c | 139 writel((bin2bcd(tm->tm_year % 100) << DATE_YEAR_S) vt8500_rtc_set_time() 140 | (bin2bcd(tm->tm_mon + 1) << DATE_MONTH_S) vt8500_rtc_set_time() 141 | (bin2bcd(tm->tm_mday)) vt8500_rtc_set_time() 144 writel((bin2bcd(tm->tm_wday) << TIME_DOW_S) vt8500_rtc_set_time() 145 | (bin2bcd(tm->tm_hour) << TIME_HOUR_S) vt8500_rtc_set_time() 146 | (bin2bcd(tm->tm_min) << TIME_MIN_S) vt8500_rtc_set_time() 147 | (bin2bcd(tm->tm_sec)), vt8500_rtc_set_time() 177 | (bin2bcd(alrm->time.tm_mday) << ALARM_DAY_S) vt8500_rtc_set_alarm() 178 | (bin2bcd(alrm->time.tm_hour) << TIME_HOUR_S) vt8500_rtc_set_alarm() 179 | (bin2bcd(alrm->time.tm_min) << TIME_MIN_S) vt8500_rtc_set_alarm() 180 | (bin2bcd(alrm->time.tm_sec)), vt8500_rtc_set_alarm()
|
H A D | rtc-bq4802.c | 110 sec = bin2bcd(sec); bq4802_set_time() 111 min = bin2bcd(min); bq4802_set_time() 112 hrs = bin2bcd(hrs); bq4802_set_time() 113 day = bin2bcd(day); bq4802_set_time() 114 mon = bin2bcd(mon); bq4802_set_time() 115 yrs = bin2bcd(yrs); bq4802_set_time() 116 century = bin2bcd(century); bq4802_set_time()
|
H A D | rtc-ds1302.c | 172 ds1302_writebyte(RTC_ADDR_SEC, bin2bcd(tm->tm_sec)); ds1302_rtc_set_time() 173 ds1302_writebyte(RTC_ADDR_MIN, bin2bcd(tm->tm_min)); ds1302_rtc_set_time() 174 ds1302_writebyte(RTC_ADDR_HOUR, bin2bcd(tm->tm_hour)); ds1302_rtc_set_time() 175 ds1302_writebyte(RTC_ADDR_DAY, bin2bcd(tm->tm_wday)); ds1302_rtc_set_time() 176 ds1302_writebyte(RTC_ADDR_DATE, bin2bcd(tm->tm_mday)); ds1302_rtc_set_time() 177 ds1302_writebyte(RTC_ADDR_MON, bin2bcd(tm->tm_mon + 1)); ds1302_rtc_set_time() 178 ds1302_writebyte(RTC_ADDR_YEAR, bin2bcd(tm->tm_year % 100)); ds1302_rtc_set_time()
|
H A D | rtc-ds1390.c | 106 chip->txrx_buf[1] = bin2bcd(dt->tm_sec); ds1390_set_time() 107 chip->txrx_buf[2] = bin2bcd(dt->tm_min); ds1390_set_time() 108 chip->txrx_buf[3] = bin2bcd(dt->tm_hour); ds1390_set_time() 109 chip->txrx_buf[4] = bin2bcd(dt->tm_wday); ds1390_set_time() 110 chip->txrx_buf[5] = bin2bcd(dt->tm_mday); ds1390_set_time() 111 chip->txrx_buf[6] = bin2bcd(dt->tm_mon + 1) | ds1390_set_time() 113 chip->txrx_buf[7] = bin2bcd(dt->tm_year % 100); ds1390_set_time()
|
H A D | rtc-ds3234.c | 83 ds3234_set_reg(dev, DS3234_REG_SECONDS, bin2bcd(dt->tm_sec)); ds3234_set_time() 84 ds3234_set_reg(dev, DS3234_REG_MINUTES, bin2bcd(dt->tm_min)); ds3234_set_time() 85 ds3234_set_reg(dev, DS3234_REG_HOURS, bin2bcd(dt->tm_hour) & 0x3f); ds3234_set_time() 88 ds3234_set_reg(dev, DS3234_REG_DAY, bin2bcd(dt->tm_wday + 1)); ds3234_set_time() 89 ds3234_set_reg(dev, DS3234_REG_DATE, bin2bcd(dt->tm_mday)); ds3234_set_time() 92 ds3234_set_reg(dev, DS3234_REG_MONTH, bin2bcd(dt->tm_mon + 1)); ds3234_set_time() 98 ds3234_set_reg(dev, DS3234_REG_YEAR, bin2bcd(dt->tm_year)); ds3234_set_time()
|
H A D | rtc-m41t93.c | 91 data[M41T93_REG_ST_SEC] = bin2bcd(tm->tm_sec); m41t93_set_time() 92 data[M41T93_REG_MIN] = bin2bcd(tm->tm_min); m41t93_set_time() 93 data[M41T93_REG_CENT_HOUR] = bin2bcd(tm->tm_hour) | m41t93_set_time() 95 data[M41T93_REG_DAY] = bin2bcd(tm->tm_mday); m41t93_set_time() 96 data[M41T93_REG_WDAY] = bin2bcd(tm->tm_wday + 1); m41t93_set_time() 97 data[M41T93_REG_MON] = bin2bcd(tm->tm_mon + 1); m41t93_set_time() 98 data[M41T93_REG_YEAR] = bin2bcd(tm->tm_year % 100); m41t93_set_time()
|
H A D | rtc-m48t86.c | 106 ops->writebyte(bin2bcd(tm->tm_sec), M48T86_REG_SEC); m48t86_rtc_set_time() 107 ops->writebyte(bin2bcd(tm->tm_min), M48T86_REG_MIN); m48t86_rtc_set_time() 108 ops->writebyte(bin2bcd(tm->tm_hour), M48T86_REG_HOUR); m48t86_rtc_set_time() 109 ops->writebyte(bin2bcd(tm->tm_mday), M48T86_REG_DOM); m48t86_rtc_set_time() 110 ops->writebyte(bin2bcd(tm->tm_mon + 1), M48T86_REG_MONTH); m48t86_rtc_set_time() 111 ops->writebyte(bin2bcd(tm->tm_year % 100), M48T86_REG_YEAR); m48t86_rtc_set_time() 112 ops->writebyte(bin2bcd(tm->tm_wday), M48T86_REG_DOW); m48t86_rtc_set_time()
|
H A D | rtc-max8907.c | 87 regs[RTC_YEAR2] = bin2bcd(high); tm_to_regs() 88 regs[RTC_YEAR1] = bin2bcd(low); tm_to_regs() 89 regs[RTC_MONTH] = bin2bcd(tm->tm_mon + 1); tm_to_regs() 90 regs[RTC_DATE] = bin2bcd(tm->tm_mday); tm_to_regs() 92 regs[RTC_HOUR] = bin2bcd(tm->tm_hour); tm_to_regs() 93 regs[RTC_MIN] = bin2bcd(tm->tm_min); tm_to_regs() 94 regs[RTC_SEC] = bin2bcd(tm->tm_sec); tm_to_regs()
|
H A D | rtc-rv3029c2.c | 275 regs[RV3029C2_A_SC-RV3029C2_A_SC] = bin2bcd(tm->tm_sec & 0x7f); rv3029c2_rtc_i2c_set_alarm() 276 regs[RV3029C2_A_MN-RV3029C2_A_SC] = bin2bcd(tm->tm_min & 0x7f); rv3029c2_rtc_i2c_set_alarm() 277 regs[RV3029C2_A_HR-RV3029C2_A_SC] = bin2bcd(tm->tm_hour & 0x3f); rv3029c2_rtc_i2c_set_alarm() 278 regs[RV3029C2_A_DT-RV3029C2_A_SC] = bin2bcd(tm->tm_mday & 0x3f); rv3029c2_rtc_i2c_set_alarm() 279 regs[RV3029C2_A_MO-RV3029C2_A_SC] = bin2bcd((tm->tm_mon & 0x1f) - 1); rv3029c2_rtc_i2c_set_alarm() 280 regs[RV3029C2_A_DW-RV3029C2_A_SC] = bin2bcd((tm->tm_wday & 7) - 1); rv3029c2_rtc_i2c_set_alarm() 281 regs[RV3029C2_A_YR-RV3029C2_A_SC] = bin2bcd((tm->tm_year & 0x7f) - 100); rv3029c2_rtc_i2c_set_alarm() 342 regs[RV3029C2_W_SEC-RV3029C2_W_SEC] = bin2bcd(tm->tm_sec); rv3029c2_i2c_set_time() 343 regs[RV3029C2_W_MINUTES-RV3029C2_W_SEC] = bin2bcd(tm->tm_min); rv3029c2_i2c_set_time() 344 regs[RV3029C2_W_HOURS-RV3029C2_W_SEC] = bin2bcd(tm->tm_hour); rv3029c2_i2c_set_time() 345 regs[RV3029C2_W_DATE-RV3029C2_W_SEC] = bin2bcd(tm->tm_mday); rv3029c2_i2c_set_time() 346 regs[RV3029C2_W_MONTHS-RV3029C2_W_SEC] = bin2bcd(tm->tm_mon+1); rv3029c2_i2c_set_time() 347 regs[RV3029C2_W_DAYS-RV3029C2_W_SEC] = bin2bcd((tm->tm_wday & 7)+1); rv3029c2_i2c_set_time() 348 regs[RV3029C2_W_YEARS-RV3029C2_W_SEC] = bin2bcd(tm->tm_year - 100); rv3029c2_i2c_set_time()
|
H A D | rtc-rk808.c | 119 rtc_data[0] = bin2bcd(tm->tm_sec); rk808_rtc_set_time() 120 rtc_data[1] = bin2bcd(tm->tm_min); rk808_rtc_set_time() 121 rtc_data[2] = bin2bcd(tm->tm_hour); rk808_rtc_set_time() 122 rtc_data[3] = bin2bcd(tm->tm_mday); rk808_rtc_set_time() 123 rtc_data[4] = bin2bcd(tm->tm_mon + 1); rk808_rtc_set_time() 124 rtc_data[5] = bin2bcd(tm->tm_year - 100); rk808_rtc_set_time() 125 rtc_data[6] = bin2bcd(tm->tm_wday); rk808_rtc_set_time() 230 alrm_data[0] = bin2bcd(alrm->time.tm_sec); rk808_rtc_setalarm() 231 alrm_data[1] = bin2bcd(alrm->time.tm_min); rk808_rtc_setalarm() 232 alrm_data[2] = bin2bcd(alrm->time.tm_hour); rk808_rtc_setalarm() 233 alrm_data[3] = bin2bcd(alrm->time.tm_mday); rk808_rtc_setalarm() 234 alrm_data[4] = bin2bcd(alrm->time.tm_mon + 1); rk808_rtc_setalarm() 235 alrm_data[5] = bin2bcd(alrm->time.tm_year - 100); rk808_rtc_setalarm()
|
H A D | rtc-m48t35.c | 119 sec = bin2bcd(sec); m48t35_set_time() 120 min = bin2bcd(min); m48t35_set_time() 121 hrs = bin2bcd(hrs); m48t35_set_time() 122 day = bin2bcd(day); m48t35_set_time() 123 mon = bin2bcd(mon); m48t35_set_time() 124 yrs = bin2bcd(yrs); m48t35_set_time()
|
H A D | rtc-pcf85063.c | 102 buf[PCF85063_REG_SC] = bin2bcd(tm->tm_sec) & 0x7F; pcf85063_set_datetime() 104 buf[PCF85063_REG_MN] = bin2bcd(tm->tm_min); pcf85063_set_datetime() 105 buf[PCF85063_REG_HR] = bin2bcd(tm->tm_hour); pcf85063_set_datetime() 108 buf[PCF85063_REG_DM] = bin2bcd(tm->tm_mday); pcf85063_set_datetime() 114 buf[PCF85063_REG_MO] = bin2bcd(tm->tm_mon + 1); pcf85063_set_datetime() 117 buf[PCF85063_REG_YR] = bin2bcd(tm->tm_year % 100); pcf85063_set_datetime()
|
H A D | rtc-r9701.c | 106 ret = write_reg(dev, RHRCNT, bin2bcd(dt->tm_hour)); r9701_set_datetime() 107 ret = ret ? ret : write_reg(dev, RMINCNT, bin2bcd(dt->tm_min)); r9701_set_datetime() 108 ret = ret ? ret : write_reg(dev, RSECCNT, bin2bcd(dt->tm_sec)); r9701_set_datetime() 109 ret = ret ? ret : write_reg(dev, RDAYCNT, bin2bcd(dt->tm_mday)); r9701_set_datetime() 110 ret = ret ? ret : write_reg(dev, RMONCNT, bin2bcd(dt->tm_mon + 1)); r9701_set_datetime() 111 ret = ret ? ret : write_reg(dev, RYRCNT, bin2bcd(dt->tm_year - 100)); r9701_set_datetime()
|
H A D | rtc-ds1553.c | 83 century = bin2bcd((tm->tm_year + 1900) / 100); ds1553_rtc_set_time() 87 writeb(bin2bcd(tm->tm_year % 100), ioaddr + RTC_YEAR); ds1553_rtc_set_time() 88 writeb(bin2bcd(tm->tm_mon + 1), ioaddr + RTC_MONTH); ds1553_rtc_set_time() 89 writeb(bin2bcd(tm->tm_wday) & RTC_DAY_MASK, ioaddr + RTC_DAY); ds1553_rtc_set_time() 90 writeb(bin2bcd(tm->tm_mday), ioaddr + RTC_DATE); ds1553_rtc_set_time() 91 writeb(bin2bcd(tm->tm_hour), ioaddr + RTC_HOURS); ds1553_rtc_set_time() 92 writeb(bin2bcd(tm->tm_min), ioaddr + RTC_MINUTES); ds1553_rtc_set_time() 93 writeb(bin2bcd(tm->tm_sec) & RTC_SECONDS_MASK, ioaddr + RTC_SECONDS); ds1553_rtc_set_time() 146 0x80 : bin2bcd(pdata->alrm_mday), ds1553_rtc_update_alarm() 149 0x80 : bin2bcd(pdata->alrm_hour), ds1553_rtc_update_alarm() 152 0x80 : bin2bcd(pdata->alrm_min), ds1553_rtc_update_alarm() 155 0x80 : bin2bcd(pdata->alrm_sec), ds1553_rtc_update_alarm()
|
H A D | rtc-palmas.c | 85 rtc_data[0] = bin2bcd(tm->tm_sec); palmas_rtc_set_time() 86 rtc_data[1] = bin2bcd(tm->tm_min); palmas_rtc_set_time() 87 rtc_data[2] = bin2bcd(tm->tm_hour); palmas_rtc_set_time() 88 rtc_data[3] = bin2bcd(tm->tm_mday); palmas_rtc_set_time() 89 rtc_data[4] = bin2bcd(tm->tm_mon + 1); palmas_rtc_set_time() 90 rtc_data[5] = bin2bcd(tm->tm_year - 100); palmas_rtc_set_time() 171 alarm_data[0] = bin2bcd(alm->time.tm_sec); palmas_rtc_set_alarm() 172 alarm_data[1] = bin2bcd(alm->time.tm_min); palmas_rtc_set_alarm() 173 alarm_data[2] = bin2bcd(alm->time.tm_hour); palmas_rtc_set_alarm() 174 alarm_data[3] = bin2bcd(alm->time.tm_mday); palmas_rtc_set_alarm() 175 alarm_data[4] = bin2bcd(alm->time.tm_mon + 1); palmas_rtc_set_alarm() 176 alarm_data[5] = bin2bcd(alm->time.tm_year - 100); palmas_rtc_set_alarm()
|
H A D | rtc-stk17ta8.c | 87 writeb(bin2bcd(tm->tm_year % 100), ioaddr + RTC_YEAR); stk17ta8_rtc_set_time() 88 writeb(bin2bcd(tm->tm_mon + 1), ioaddr + RTC_MONTH); stk17ta8_rtc_set_time() 89 writeb(bin2bcd(tm->tm_wday) & RTC_DAY_MASK, ioaddr + RTC_DAY); stk17ta8_rtc_set_time() 90 writeb(bin2bcd(tm->tm_mday), ioaddr + RTC_DATE); stk17ta8_rtc_set_time() 91 writeb(bin2bcd(tm->tm_hour), ioaddr + RTC_HOURS); stk17ta8_rtc_set_time() 92 writeb(bin2bcd(tm->tm_min), ioaddr + RTC_MINUTES); stk17ta8_rtc_set_time() 93 writeb(bin2bcd(tm->tm_sec) & RTC_SECONDS_MASK, ioaddr + RTC_SECONDS); stk17ta8_rtc_set_time() 94 writeb(bin2bcd((tm->tm_year + 1900) / 100), ioaddr + RTC_CENTURY); stk17ta8_rtc_set_time() 153 0x80 : bin2bcd(pdata->alrm_mday), stk17ta8_rtc_update_alarm() 156 0x80 : bin2bcd(pdata->alrm_hour), stk17ta8_rtc_update_alarm() 159 0x80 : bin2bcd(pdata->alrm_min), stk17ta8_rtc_update_alarm() 162 0x80 : bin2bcd(pdata->alrm_sec), stk17ta8_rtc_update_alarm()
|
H A D | rtc-s35390a.c | 129 return bin2bcd(hour); s35390a_hr2reg() 132 return bin2bcd(hour); s35390a_hr2reg() 134 return 0x40 | bin2bcd(hour - 12); s35390a_hr2reg() 162 buf[S35390A_BYTE_YEAR] = bin2bcd(tm->tm_year - 100); s35390a_set_datetime() 163 buf[S35390A_BYTE_MONTH] = bin2bcd(tm->tm_mon + 1); s35390a_set_datetime() 164 buf[S35390A_BYTE_DAY] = bin2bcd(tm->tm_mday); s35390a_set_datetime() 165 buf[S35390A_BYTE_WDAY] = bin2bcd(tm->tm_wday); s35390a_set_datetime() 167 buf[S35390A_BYTE_MINS] = bin2bcd(tm->tm_min); s35390a_set_datetime() 168 buf[S35390A_BYTE_SECS] = bin2bcd(tm->tm_sec); s35390a_set_datetime() 244 buf[S35390A_ALRM_BYTE_WDAY] = bin2bcd(alm->time.tm_wday) | 0x80; s35390a_set_alarm() 248 buf[S35390A_ALRM_BYTE_MINS] = bin2bcd(alm->time.tm_min) | 0x80; s35390a_set_alarm()
|
H A D | rtc-bq32k.c | 112 regs.seconds = bin2bcd(tm->tm_sec); bq32k_rtc_set_time() 113 regs.minutes = bin2bcd(tm->tm_min); bq32k_rtc_set_time() 114 regs.cent_hours = bin2bcd(tm->tm_hour) | BQ32K_CENT_EN; bq32k_rtc_set_time() 115 regs.day = bin2bcd(tm->tm_wday + 1); bq32k_rtc_set_time() 116 regs.date = bin2bcd(tm->tm_mday); bq32k_rtc_set_time() 117 regs.month = bin2bcd(tm->tm_mon + 1); bq32k_rtc_set_time() 121 regs.years = bin2bcd(tm->tm_year - 100); bq32k_rtc_set_time() 123 regs.years = bin2bcd(tm->tm_year); bq32k_rtc_set_time()
|
H A D | rtc-ds1742.c | 70 century = bin2bcd((tm->tm_year + 1900) / 100); ds1742_rtc_set_time() 74 writeb(bin2bcd(tm->tm_year % 100), ioaddr + RTC_YEAR); ds1742_rtc_set_time() 75 writeb(bin2bcd(tm->tm_mon + 1), ioaddr + RTC_MONTH); ds1742_rtc_set_time() 76 writeb(bin2bcd(tm->tm_wday) & RTC_DAY_MASK, ioaddr + RTC_DAY); ds1742_rtc_set_time() 77 writeb(bin2bcd(tm->tm_mday), ioaddr + RTC_DATE); ds1742_rtc_set_time() 78 writeb(bin2bcd(tm->tm_hour), ioaddr + RTC_HOURS); ds1742_rtc_set_time() 79 writeb(bin2bcd(tm->tm_min), ioaddr + RTC_MINUTES); ds1742_rtc_set_time() 80 writeb(bin2bcd(tm->tm_sec) & RTC_SECONDS_MASK, ioaddr + RTC_SECONDS); ds1742_rtc_set_time()
|
H A D | rtc-rs5c348.c | 79 txp[RS5C348_REG_SECS] = bin2bcd(tm->tm_sec); rs5c348_rtc_set_time() 80 txp[RS5C348_REG_MINS] = bin2bcd(tm->tm_min); rs5c348_rtc_set_time() 82 txp[RS5C348_REG_HOURS] = bin2bcd(tm->tm_hour); rs5c348_rtc_set_time() 85 txp[RS5C348_REG_HOURS] = bin2bcd((tm->tm_hour + 11) % 12 + 1) | rs5c348_rtc_set_time() 88 txp[RS5C348_REG_WDAY] = bin2bcd(tm->tm_wday); rs5c348_rtc_set_time() 89 txp[RS5C348_REG_DAY] = bin2bcd(tm->tm_mday); rs5c348_rtc_set_time() 90 txp[RS5C348_REG_MONTH] = bin2bcd(tm->tm_mon + 1) | rs5c348_rtc_set_time() 92 txp[RS5C348_REG_YEAR] = bin2bcd(tm->tm_year % 100); rs5c348_rtc_set_time()
|
H A D | rtc-at91rm9200.c | 181 bin2bcd(tm->tm_sec) << 0 at91_rtc_settime() 182 | bin2bcd(tm->tm_min) << 8 at91_rtc_settime() 183 | bin2bcd(tm->tm_hour) << 16); at91_rtc_settime() 186 bin2bcd((tm->tm_year + 1900) / 100) /* century */ at91_rtc_settime() 187 | bin2bcd(tm->tm_year % 100) << 8 /* year */ at91_rtc_settime() 188 | bin2bcd(tm->tm_mon + 1) << 16 /* tm_mon starts at zero */ at91_rtc_settime() 189 | bin2bcd(tm->tm_wday + 1) << 21 /* day of the week [0-6], Sunday=0 */ at91_rtc_settime() 190 | bin2bcd(tm->tm_mday) << 24); at91_rtc_settime() 241 bin2bcd(tm.tm_sec) << 0 at91_rtc_setalarm() 242 | bin2bcd(tm.tm_min) << 8 at91_rtc_setalarm() 243 | bin2bcd(tm.tm_hour) << 16 at91_rtc_setalarm() 246 bin2bcd(tm.tm_mon + 1) << 16 /* tm_mon starts at zero */ at91_rtc_setalarm() 247 | bin2bcd(tm.tm_mday) << 24 at91_rtc_setalarm()
|
H A D | rtc-ds1511.c | 157 rtc_write(bin2bcd(deciseconds % 100), DS1511_WD_MSEC); ds1511_wdog_set() 158 rtc_write(bin2bcd(deciseconds / 100), DS1511_WD_SEC); ds1511_wdog_set() 220 sec = bin2bcd(sec) & 0x7f; ds1511_rtc_set_time() 221 min = bin2bcd(min) & 0x7f; ds1511_rtc_set_time() 222 hrs = bin2bcd(hrs) & 0x3f; ds1511_rtc_set_time() 223 day = bin2bcd(day) & 0x3f; ds1511_rtc_set_time() 224 mon = bin2bcd(mon) & 0x1f; ds1511_rtc_set_time() 225 yrs = bin2bcd(yrs) & 0xff; ds1511_rtc_set_time() 226 cen = bin2bcd(cen) & 0xff; ds1511_rtc_set_time() 304 0x80 : bin2bcd(pdata->alrm_mday) & 0x3f, ds1511_rtc_update_alarm() 307 0x80 : bin2bcd(pdata->alrm_hour) & 0x3f, ds1511_rtc_update_alarm() 310 0x80 : bin2bcd(pdata->alrm_min) & 0x7f, ds1511_rtc_update_alarm() 313 0x80 : bin2bcd(pdata->alrm_sec) & 0x7f, ds1511_rtc_update_alarm()
|
H A D | rtc-isl1208.c | 394 regs[ISL1208_REG_SCA - offs] = bin2bcd(alarm_tm->tm_sec) | enable; isl1208_i2c_set_alarm() 395 regs[ISL1208_REG_MNA - offs] = bin2bcd(alarm_tm->tm_min) | enable; isl1208_i2c_set_alarm() 396 regs[ISL1208_REG_HRA - offs] = bin2bcd(alarm_tm->tm_hour) | isl1208_i2c_set_alarm() 399 regs[ISL1208_REG_DTA - offs] = bin2bcd(alarm_tm->tm_mday) | enable; isl1208_i2c_set_alarm() 400 regs[ISL1208_REG_MOA - offs] = bin2bcd(alarm_tm->tm_mon + 1) | enable; isl1208_i2c_set_alarm() 401 regs[ISL1208_REG_DWA - offs] = bin2bcd(alarm_tm->tm_wday & 7) | enable; isl1208_i2c_set_alarm() 438 regs[ISL1208_REG_SC] = bin2bcd(tm->tm_sec); isl1208_i2c_set_time() 439 regs[ISL1208_REG_MN] = bin2bcd(tm->tm_min); isl1208_i2c_set_time() 440 regs[ISL1208_REG_HR] = bin2bcd(tm->tm_hour) | ISL1208_REG_HR_MIL; isl1208_i2c_set_time() 442 regs[ISL1208_REG_DT] = bin2bcd(tm->tm_mday); isl1208_i2c_set_time() 443 regs[ISL1208_REG_MO] = bin2bcd(tm->tm_mon + 1); isl1208_i2c_set_time() 444 regs[ISL1208_REG_YR] = bin2bcd(tm->tm_year - 100); isl1208_i2c_set_time() 446 regs[ISL1208_REG_DW] = bin2bcd(tm->tm_wday & 7); isl1208_i2c_set_time()
|
H A D | rtc-max8998.c | 101 data[RTC_SEC] = bin2bcd(tm->tm_sec); max8998_tm_to_data() 102 data[RTC_MIN] = bin2bcd(tm->tm_min); max8998_tm_to_data() 103 data[RTC_HOUR] = bin2bcd(tm->tm_hour); max8998_tm_to_data() 105 data[RTC_DATE] = bin2bcd(tm->tm_mday); max8998_tm_to_data() 106 data[RTC_MONTH] = bin2bcd(tm->tm_mon); max8998_tm_to_data() 107 data[RTC_YEAR1] = bin2bcd(tm->tm_year % 100); max8998_tm_to_data() 108 data[RTC_YEAR2] = bin2bcd((tm->tm_year + 1900) / 100); max8998_tm_to_data()
|
H A D | rtc-nuc900.c | 122 gettm->bcd_mday = bin2bcd(settm->tm_mday) << 0; nuc900_rtc_bin2bcd() 123 gettm->bcd_mon = bin2bcd(settm->tm_mon) << 8; nuc900_rtc_bin2bcd() 127 gettm->bcd_year = bin2bcd(settm->tm_year) << 16; nuc900_rtc_bin2bcd() 129 gettm->bcd_year = bin2bcd(settm->tm_year - 100) << 16; nuc900_rtc_bin2bcd() 132 gettm->bcd_sec = bin2bcd(settm->tm_sec) << 0; nuc900_rtc_bin2bcd() 133 gettm->bcd_min = bin2bcd(settm->tm_min) << 8; nuc900_rtc_bin2bcd() 134 gettm->bcd_hour = bin2bcd(settm->tm_hour) << 16; nuc900_rtc_bin2bcd()
|
H A D | rtc-opal.c | 48 *y_m_d |= ((u32)bin2bcd((tm->tm_year + 1900) / 100)) << 24; tm_to_opal() 49 *y_m_d |= ((u32)bin2bcd((tm->tm_year + 1900) % 100)) << 16; tm_to_opal() 50 *y_m_d |= ((u32)bin2bcd((tm->tm_mon + 1))) << 8; tm_to_opal() 51 *y_m_d |= ((u32)bin2bcd(tm->tm_mday)); tm_to_opal() 53 *h_m_s_ms |= ((u64)bin2bcd(tm->tm_hour)) << 56; tm_to_opal() 54 *h_m_s_ms |= ((u64)bin2bcd(tm->tm_min)) << 48; tm_to_opal() 55 *h_m_s_ms |= ((u64)bin2bcd(tm->tm_sec)) << 40; tm_to_opal()
|
H A D | rtc-pcf50633.c | 80 pcf->time[PCF50633_TI_SEC] = bin2bcd(rtc->tm_sec); rtc2pcf_time() 81 pcf->time[PCF50633_TI_MIN] = bin2bcd(rtc->tm_min); rtc2pcf_time() 82 pcf->time[PCF50633_TI_HOUR] = bin2bcd(rtc->tm_hour); rtc2pcf_time() 83 pcf->time[PCF50633_TI_WKDAY] = bin2bcd(rtc->tm_wday); rtc2pcf_time() 84 pcf->time[PCF50633_TI_DAY] = bin2bcd(rtc->tm_mday); rtc2pcf_time() 85 pcf->time[PCF50633_TI_MONTH] = bin2bcd(rtc->tm_mon + 1); rtc2pcf_time() 86 pcf->time[PCF50633_TI_YEAR] = bin2bcd(rtc->tm_year % 100); rtc2pcf_time()
|
H A D | rtc-rs5c313.c | 299 data = bin2bcd(tm->tm_sec); rs5c313_rtc_set_time() 303 data = bin2bcd(tm->tm_min); rs5c313_rtc_set_time() 307 data = bin2bcd(tm->tm_hour); rs5c313_rtc_set_time() 311 data = bin2bcd(tm->tm_mday); rs5c313_rtc_set_time() 315 data = bin2bcd(tm->tm_mon + 1); rs5c313_rtc_set_time() 319 data = bin2bcd(tm->tm_year % 100); rs5c313_rtc_set_time() 323 data = bin2bcd(tm->tm_wday); rs5c313_rtc_set_time()
|
H A D | rtc-v3020.c | 281 v3020_set_reg(chip, V3020_SECONDS, bin2bcd(dt->tm_sec)); v3020_set_time() 282 v3020_set_reg(chip, V3020_MINUTES, bin2bcd(dt->tm_min)); v3020_set_time() 283 v3020_set_reg(chip, V3020_HOURS, bin2bcd(dt->tm_hour)); v3020_set_time() 284 v3020_set_reg(chip, V3020_MONTH_DAY, bin2bcd(dt->tm_mday)); v3020_set_time() 285 v3020_set_reg(chip, V3020_MONTH, bin2bcd(dt->tm_mon + 1)); v3020_set_time() 286 v3020_set_reg(chip, V3020_WEEK_DAY, bin2bcd(dt->tm_wday)); v3020_set_time() 287 v3020_set_reg(chip, V3020_YEAR, bin2bcd(dt->tm_year % 100)); v3020_set_time()
|
H A D | rtc-ds3232.c | 167 buf[0] = bin2bcd(time->tm_sec); ds3232_set_time() 168 buf[1] = bin2bcd(time->tm_min); ds3232_set_time() 169 buf[2] = bin2bcd(time->tm_hour); ds3232_set_time() 171 buf[3] = bin2bcd(time->tm_wday + 1); ds3232_set_time() 172 buf[4] = bin2bcd(time->tm_mday); /* Date */ ds3232_set_time() 174 buf[5] = bin2bcd(time->tm_mon + 1); ds3232_set_time() 177 buf[6] = bin2bcd(time->tm_year - 100); ds3232_set_time() 179 buf[6] = bin2bcd(time->tm_year); ds3232_set_time() 250 buf[0] = bin2bcd(alarm->time.tm_sec); ds3232_set_alarm() 251 buf[1] = bin2bcd(alarm->time.tm_min); ds3232_set_alarm() 252 buf[2] = bin2bcd(alarm->time.tm_hour); ds3232_set_alarm() 253 buf[3] = bin2bcd(alarm->time.tm_mday); ds3232_set_alarm()
|
H A D | rtc-fm3130.c | 157 buf[FM3130_RTC_SECONDS] = bin2bcd(t->tm_sec); fm3130_set_time() 158 buf[FM3130_RTC_MINUTES] = bin2bcd(t->tm_min); fm3130_set_time() 159 buf[FM3130_RTC_HOURS] = bin2bcd(t->tm_hour); fm3130_set_time() 160 buf[FM3130_RTC_DAY] = bin2bcd(t->tm_wday + 1); fm3130_set_time() 161 buf[FM3130_RTC_DATE] = bin2bcd(t->tm_mday); fm3130_set_time() 162 buf[FM3130_RTC_MONTHS] = bin2bcd(t->tm_mon + 1); fm3130_set_time() 166 buf[FM3130_RTC_YEARS] = bin2bcd(tmp); fm3130_set_time() 258 (tm->tm_sec != -1) ? bin2bcd(tm->tm_sec) : 0x80; fm3130_set_alarm() 261 (tm->tm_min != -1) ? bin2bcd(tm->tm_min) : 0x80; fm3130_set_alarm() 264 (tm->tm_hour != -1) ? bin2bcd(tm->tm_hour) : 0x80; fm3130_set_alarm() 267 (tm->tm_mday != -1) ? bin2bcd(tm->tm_mday) : 0x80; fm3130_set_alarm() 270 (tm->tm_mon != -1) ? bin2bcd(tm->tm_mon + 1) : 0x80; fm3130_set_alarm()
|
H A D | rtc-twl.c | 320 rtc_data[0] = bin2bcd(tm->tm_sec); twl_rtc_set_time() 321 rtc_data[1] = bin2bcd(tm->tm_min); twl_rtc_set_time() 322 rtc_data[2] = bin2bcd(tm->tm_hour); twl_rtc_set_time() 323 rtc_data[3] = bin2bcd(tm->tm_mday); twl_rtc_set_time() 324 rtc_data[4] = bin2bcd(tm->tm_mon + 1); twl_rtc_set_time() 325 rtc_data[5] = bin2bcd(tm->tm_year - 100); twl_rtc_set_time() 392 alarm_data[0] = bin2bcd(alm->time.tm_sec); twl_rtc_set_alarm() 393 alarm_data[1] = bin2bcd(alm->time.tm_min); twl_rtc_set_alarm() 394 alarm_data[2] = bin2bcd(alm->time.tm_hour); twl_rtc_set_alarm() 395 alarm_data[3] = bin2bcd(alm->time.tm_mday); twl_rtc_set_alarm() 396 alarm_data[4] = bin2bcd(alm->time.tm_mon + 1); twl_rtc_set_alarm() 397 alarm_data[5] = bin2bcd(alm->time.tm_year - 100); twl_rtc_set_alarm()
|
H A D | rtc-ds1343.c | 410 bin2bcd(dt->tm_sec)); ds1343_set_time() 415 bin2bcd(dt->tm_min)); ds1343_set_time() 420 bin2bcd(dt->tm_hour) & 0x3F); ds1343_set_time() 425 bin2bcd(dt->tm_wday + 1)); ds1343_set_time() 430 bin2bcd(dt->tm_mday)); ds1343_set_time() 435 bin2bcd(dt->tm_mon + 1)); ds1343_set_time() 442 bin2bcd(dt->tm_year)); ds1343_set_time() 476 0x80 : bin2bcd(priv->alarm_sec) & 0x7F; ds1343_update_alarm() 478 0x80 : bin2bcd(priv->alarm_min) & 0x7F; ds1343_update_alarm() 480 0x80 : bin2bcd(priv->alarm_hour) & 0x3F; ds1343_update_alarm() 482 0x80 : bin2bcd(priv->alarm_mday) & 0x7F; ds1343_update_alarm()
|
H A D | rtc-m48t59.c | 136 M48T59_WRITE((bin2bcd(tm->tm_sec) & 0x7F), M48T59_SEC); m48t59_rtc_set_time() 137 M48T59_WRITE((bin2bcd(tm->tm_min) & 0x7F), M48T59_MIN); m48t59_rtc_set_time() 138 M48T59_WRITE((bin2bcd(tm->tm_hour) & 0x3F), M48T59_HOUR); m48t59_rtc_set_time() 139 M48T59_WRITE((bin2bcd(tm->tm_mday) & 0x3F), M48T59_MDAY); m48t59_rtc_set_time() 141 M48T59_WRITE((bin2bcd(tm->tm_mon + 1) & 0x1F), M48T59_MONTH); m48t59_rtc_set_time() 142 M48T59_WRITE(bin2bcd(year % 100), M48T59_YEAR); m48t59_rtc_set_time() 146 val |= (bin2bcd(tm->tm_wday) & 0x07); m48t59_rtc_set_time() 231 mday = (mday >= 1 && mday <= 31) ? bin2bcd(mday) : 0xff; m48t59_rtc_setalarm() 236 hour = (hour < 24) ? bin2bcd(hour) : 0x00; m48t59_rtc_setalarm() 239 min = (min < 60) ? bin2bcd(min) : 0x00; m48t59_rtc_setalarm() 242 sec = (sec < 60) ? bin2bcd(sec) : 0x00; m48t59_rtc_setalarm()
|
H A D | rtc-rx8025.c | 243 date[RX8025_REG_SEC] = bin2bcd(dt->tm_sec); rx8025_set_time() 244 date[RX8025_REG_MIN] = bin2bcd(dt->tm_min); rx8025_set_time() 246 date[RX8025_REG_HOUR] = bin2bcd(dt->tm_hour); rx8025_set_time() 249 | bin2bcd((dt->tm_hour + 11) % 12 + 1); rx8025_set_time() 251 date[RX8025_REG_WDAY] = bin2bcd(dt->tm_wday); rx8025_set_time() 252 date[RX8025_REG_MDAY] = bin2bcd(dt->tm_mday); rx8025_set_time() 253 date[RX8025_REG_MONTH] = bin2bcd(dt->tm_mon + 1); rx8025_set_time() 254 date[RX8025_REG_YEAR] = bin2bcd(dt->tm_year % 100); rx8025_set_time() 374 ald[0] = bin2bcd(t->time.tm_min); rx8025_set_alarm() 376 ald[1] = bin2bcd(t->time.tm_hour); rx8025_set_alarm() 379 | bin2bcd((t->time.tm_hour + 11) % 12 + 1); rx8025_set_alarm()
|
H A D | rtc-ds1286.c | 244 sec = bin2bcd(sec); ds1286_set_time() 245 min = bin2bcd(min); ds1286_set_time() 246 hrs = bin2bcd(hrs); ds1286_set_time() 247 day = bin2bcd(day); ds1286_set_time() 248 mon = bin2bcd(mon); ds1286_set_time() 249 yrs = bin2bcd(yrs); ds1286_set_time() 308 min = bin2bcd(min); ds1286_set_alarm() 309 hrs = bin2bcd(hrs); ds1286_set_alarm()
|
H A D | rtc-abx80x.c | 133 buf[ABX8XX_REG_SC] = bin2bcd(tm->tm_sec); abx80x_rtc_set_time() 134 buf[ABX8XX_REG_MN] = bin2bcd(tm->tm_min); abx80x_rtc_set_time() 135 buf[ABX8XX_REG_HR] = bin2bcd(tm->tm_hour); abx80x_rtc_set_time() 136 buf[ABX8XX_REG_DA] = bin2bcd(tm->tm_mday); abx80x_rtc_set_time() 137 buf[ABX8XX_REG_MO] = bin2bcd(tm->tm_mon + 1); abx80x_rtc_set_time() 138 buf[ABX8XX_REG_YR] = bin2bcd(tm->tm_year - 100); abx80x_rtc_set_time()
|
H A D | rtc-as3722.c | 44 rbuff[0] = bin2bcd(tm->tm_sec); as3722_time_to_reg() 45 rbuff[1] = bin2bcd(tm->tm_min); as3722_time_to_reg() 46 rbuff[2] = bin2bcd(tm->tm_hour); as3722_time_to_reg() 47 rbuff[3] = bin2bcd(tm->tm_mday); as3722_time_to_reg() 48 rbuff[4] = bin2bcd(tm->tm_mon); as3722_time_to_reg() 49 rbuff[5] = bin2bcd(tm->tm_year - (AS3722_RTC_START_YEAR - 1900)); as3722_time_to_reg()
|
H A D | rtc-isl12022.c | 213 buf[ISL12022_REG_SC] = bin2bcd(tm->tm_sec); isl12022_set_datetime() 214 buf[ISL12022_REG_MN] = bin2bcd(tm->tm_min); isl12022_set_datetime() 215 buf[ISL12022_REG_HR] = bin2bcd(tm->tm_hour) | ISL12022_HR_MIL; isl12022_set_datetime() 217 buf[ISL12022_REG_DT] = bin2bcd(tm->tm_mday); isl12022_set_datetime() 220 buf[ISL12022_REG_MO] = bin2bcd(tm->tm_mon + 1); isl12022_set_datetime() 223 buf[ISL12022_REG_YR] = bin2bcd(tm->tm_year % 100); isl12022_set_datetime()
|
H A D | rtc-pcf2123.c | 199 txbuf[1] = bin2bcd(tm->tm_sec & 0x7F); pcf2123_rtc_set_time() 200 txbuf[2] = bin2bcd(tm->tm_min & 0x7F); pcf2123_rtc_set_time() 201 txbuf[3] = bin2bcd(tm->tm_hour & 0x3F); pcf2123_rtc_set_time() 202 txbuf[4] = bin2bcd(tm->tm_mday & 0x3F); pcf2123_rtc_set_time() 204 txbuf[6] = bin2bcd((tm->tm_mon + 1) & 0x1F); /* rtc mn 1-12 */ pcf2123_rtc_set_time() 205 txbuf[7] = bin2bcd(tm->tm_year < 100 ? tm->tm_year : tm->tm_year - 100); pcf2123_rtc_set_time()
|
H A D | rtc-pcf2127.c | 115 buf[i++] = bin2bcd(tm->tm_sec); pcf2127_set_datetime() 116 buf[i++] = bin2bcd(tm->tm_min); pcf2127_set_datetime() 117 buf[i++] = bin2bcd(tm->tm_hour); pcf2127_set_datetime() 118 buf[i++] = bin2bcd(tm->tm_mday); pcf2127_set_datetime() 122 buf[i++] = bin2bcd(tm->tm_mon + 1); pcf2127_set_datetime() 125 buf[i++] = bin2bcd(tm->tm_year % 100); pcf2127_set_datetime()
|
H A D | rtc-pcf8523.c | 227 regs[1] = bin2bcd(tm->tm_sec); pcf8523_rtc_set_time() 228 regs[2] = bin2bcd(tm->tm_min); pcf8523_rtc_set_time() 229 regs[3] = bin2bcd(tm->tm_hour); pcf8523_rtc_set_time() 230 regs[4] = bin2bcd(tm->tm_mday); pcf8523_rtc_set_time() 232 regs[6] = bin2bcd(tm->tm_mon + 1); pcf8523_rtc_set_time() 233 regs[7] = bin2bcd(tm->tm_year - 100); pcf8523_rtc_set_time()
|
H A D | rtc-rx4581.c | 196 buf[RX4581_REG_SC+1] = bin2bcd(tm->tm_sec); rx4581_set_datetime() 197 buf[RX4581_REG_MN+1] = bin2bcd(tm->tm_min); rx4581_set_datetime() 198 buf[RX4581_REG_HR+1] = bin2bcd(tm->tm_hour); rx4581_set_datetime() 200 buf[RX4581_REG_DM+1] = bin2bcd(tm->tm_mday); rx4581_set_datetime() 203 buf[RX4581_REG_MO+1] = bin2bcd(tm->tm_mon + 1); rx4581_set_datetime() 206 buf[RX4581_REG_YR+1] = bin2bcd(tm->tm_year % 100); rx4581_set_datetime()
|
H A D | rtc-hym8563.c | 135 buf[0] = bin2bcd(tm->tm_sec); hym8563_rtc_set_time() 136 buf[1] = bin2bcd(tm->tm_min); hym8563_rtc_set_time() 137 buf[2] = bin2bcd(tm->tm_hour); hym8563_rtc_set_time() 138 buf[3] = bin2bcd(tm->tm_mday); hym8563_rtc_set_time() 139 buf[4] = bin2bcd(tm->tm_wday); hym8563_rtc_set_time() 140 buf[5] = bin2bcd(tm->tm_mon + 1); hym8563_rtc_set_time() 265 bin2bcd(alm_tm->tm_min) : HYM8563_ALM_BIT_DISABLE; hym8563_rtc_set_alarm() 268 bin2bcd(alm_tm->tm_hour) : HYM8563_ALM_BIT_DISABLE; hym8563_rtc_set_alarm() 271 bin2bcd(alm_tm->tm_mday) : HYM8563_ALM_BIT_DISABLE; hym8563_rtc_set_alarm() 274 bin2bcd(alm_tm->tm_wday) : HYM8563_ALM_BIT_DISABLE; hym8563_rtc_set_alarm()
|
H A D | rtc-pcf8563.c | 258 buf[PCF8563_REG_SC] = bin2bcd(tm->tm_sec); pcf8563_set_datetime() 259 buf[PCF8563_REG_MN] = bin2bcd(tm->tm_min); pcf8563_set_datetime() 260 buf[PCF8563_REG_HR] = bin2bcd(tm->tm_hour); pcf8563_set_datetime() 262 buf[PCF8563_REG_DM] = bin2bcd(tm->tm_mday); pcf8563_set_datetime() 265 buf[PCF8563_REG_MO] = bin2bcd(tm->tm_mon + 1); pcf8563_set_datetime() 268 buf[PCF8563_REG_YR] = bin2bcd(tm->tm_year % 100); pcf8563_set_datetime() 380 buf[0] = bin2bcd(tm->time.tm_min); pcf8563_rtc_set_alarm() 381 buf[1] = bin2bcd(tm->time.tm_hour); pcf8563_rtc_set_alarm() 382 buf[2] = bin2bcd(tm->time.tm_mday); pcf8563_rtc_set_alarm()
|
H A D | rtc-pcf8583.c | 98 buf[3] = bin2bcd(dt->tm_sec); pcf8583_set_datetime() 99 buf[4] = bin2bcd(dt->tm_min); pcf8583_set_datetime() 100 buf[5] = bin2bcd(dt->tm_hour); pcf8583_set_datetime() 104 buf[6] = bin2bcd(dt->tm_mday) | (dt->tm_year << 6); pcf8583_set_datetime() 105 buf[7] = bin2bcd(dt->tm_mon + 1) | (dt->tm_wday << 5); pcf8583_set_datetime()
|
H A D | rtc-rs5c372.c | 172 return bin2bcd(hour); rs5c_hr2reg() 175 return 0x20 | bin2bcd(hour - 12); rs5c_hr2reg() 177 return 0x20 | bin2bcd(12); rs5c_hr2reg() 179 return bin2bcd(12); rs5c_hr2reg() 180 return bin2bcd(hour); rs5c_hr2reg() 227 buf[0] = bin2bcd(tm->tm_sec); rs5c372_set_datetime() 228 buf[1] = bin2bcd(tm->tm_min); rs5c372_set_datetime() 230 buf[3] = bin2bcd(tm->tm_wday); rs5c372_set_datetime() 231 buf[4] = bin2bcd(tm->tm_mday); rs5c372_set_datetime() 232 buf[5] = bin2bcd(tm->tm_mon + 1); rs5c372_set_datetime() 233 buf[6] = bin2bcd(tm->tm_year - 100); rs5c372_set_datetime() 391 buf[0] = bin2bcd(t->time.tm_min); rs5c_set_alarm()
|
H A D | rtc-rx8581.c | 189 buf[RX8581_REG_SC] = bin2bcd(tm->tm_sec); rx8581_set_datetime() 190 buf[RX8581_REG_MN] = bin2bcd(tm->tm_min); rx8581_set_datetime() 191 buf[RX8581_REG_HR] = bin2bcd(tm->tm_hour); rx8581_set_datetime() 193 buf[RX8581_REG_DM] = bin2bcd(tm->tm_mday); rx8581_set_datetime() 196 buf[RX8581_REG_MO] = bin2bcd(tm->tm_mon + 1); rx8581_set_datetime() 199 buf[RX8581_REG_YR] = bin2bcd(tm->tm_year % 100); rx8581_set_datetime()
|
H A D | rtc-ds1307.c | 422 buf[DS1307_REG_SECS] = bin2bcd(t->tm_sec); ds1307_set_time() 423 buf[DS1307_REG_MIN] = bin2bcd(t->tm_min); ds1307_set_time() 424 buf[DS1307_REG_HOUR] = bin2bcd(t->tm_hour); ds1307_set_time() 425 buf[DS1307_REG_WDAY] = bin2bcd(t->tm_wday + 1); ds1307_set_time() 426 buf[DS1307_REG_MDAY] = bin2bcd(t->tm_mday); ds1307_set_time() 427 buf[DS1307_REG_MONTH] = bin2bcd(t->tm_mon + 1); ds1307_set_time() 431 buf[DS1307_REG_YEAR] = bin2bcd(tmp); ds1307_set_time() 554 buf[0] = bin2bcd(t->time.tm_sec); ds1337_set_alarm() 555 buf[1] = bin2bcd(t->time.tm_min); ds1337_set_alarm() 556 buf[2] = bin2bcd(t->time.tm_hour); ds1337_set_alarm() 557 buf[3] = bin2bcd(t->time.tm_mday); ds1337_set_alarm() 734 regs[3] = bin2bcd(t->time.tm_sec); mcp794xx_set_alarm() 735 regs[4] = bin2bcd(t->time.tm_min); mcp794xx_set_alarm() 736 regs[5] = bin2bcd(t->time.tm_hour); mcp794xx_set_alarm() 737 regs[6] = bin2bcd(t->time.tm_wday) + 1; mcp794xx_set_alarm() 738 regs[7] = bin2bcd(t->time.tm_mday); mcp794xx_set_alarm() 739 regs[8] = bin2bcd(t->time.tm_mon) + 1; mcp794xx_set_alarm() 1168 bin2bcd(tmp)); ds1307_probe()
|
H A D | rtc-isl12057.c | 128 regs[ISL12057_REG_RTC_SC] = bin2bcd(tm->tm_sec); isl12057_rtc_tm_to_regs() 129 regs[ISL12057_REG_RTC_MN] = bin2bcd(tm->tm_min); isl12057_rtc_tm_to_regs() 130 regs[ISL12057_REG_RTC_HR] = bin2bcd(tm->tm_hour); /* 24-hour format */ isl12057_rtc_tm_to_regs() 131 regs[ISL12057_REG_RTC_DT] = bin2bcd(tm->tm_mday); isl12057_rtc_tm_to_regs() 132 regs[ISL12057_REG_RTC_MO] = bin2bcd(tm->tm_mon + 1) | century_bit; isl12057_rtc_tm_to_regs() 133 regs[ISL12057_REG_RTC_YR] = bin2bcd(tm->tm_year % 100); isl12057_rtc_tm_to_regs() 134 regs[ISL12057_REG_RTC_DW] = bin2bcd(tm->tm_wday + 1); isl12057_rtc_tm_to_regs() 373 regs[0] = bin2bcd(alarm_tm->tm_sec) & 0x7f; isl12057_rtc_set_alarm() 374 regs[1] = bin2bcd(alarm_tm->tm_min) & 0x7f; isl12057_rtc_set_alarm() 375 regs[2] = bin2bcd(alarm_tm->tm_hour) & 0x3f; isl12057_rtc_set_alarm() 376 regs[3] = bin2bcd(alarm_tm->tm_mday) & 0x3f; isl12057_rtc_set_alarm()
|
H A D | rtc-x1205.c | 197 buf[CCR_SEC] = bin2bcd(tm->tm_sec); x1205_set_datetime() 198 buf[CCR_MIN] = bin2bcd(tm->tm_min); x1205_set_datetime() 201 buf[CCR_HOUR] = bin2bcd(tm->tm_hour) | X1205_HR_MIL; x1205_set_datetime() 203 buf[CCR_MDAY] = bin2bcd(tm->tm_mday); x1205_set_datetime() 206 buf[CCR_MONTH] = bin2bcd(tm->tm_mon + 1); x1205_set_datetime() 209 buf[CCR_YEAR] = bin2bcd(tm->tm_year % 100); x1205_set_datetime() 211 buf[CCR_Y2K] = bin2bcd((tm->tm_year + 1900) / 100); x1205_set_datetime()
|
H A D | rtc-ds1305.c | 130 return DS1305_HR_12 | bin2bcd(hour); hour2bcd() 132 return DS1305_HR_12 | DS1305_HR_PM | bin2bcd(hour); hour2bcd() 134 return bin2bcd(hour); hour2bcd() 227 *bp++ = bin2bcd(time->tm_sec); ds1305_set_time() 228 *bp++ = bin2bcd(time->tm_min); ds1305_set_time() 231 *bp++ = bin2bcd(time->tm_mday); ds1305_set_time() 232 *bp++ = bin2bcd(time->tm_mon + 1); ds1305_set_time() 233 *bp++ = bin2bcd(time->tm_year - 100); ds1305_set_time() 375 buf[1 + DS1305_SEC] = bin2bcd(alm->time.tm_sec); ds1305_set_alarm() 376 buf[1 + DS1305_MIN] = bin2bcd(alm->time.tm_min); ds1305_set_alarm()
|
H A D | rtc-sh.c | 428 writeb(bin2bcd(tm->tm_sec), rtc->regbase + RSECCNT); sh_rtc_set_time() 429 writeb(bin2bcd(tm->tm_min), rtc->regbase + RMINCNT); sh_rtc_set_time() 430 writeb(bin2bcd(tm->tm_hour), rtc->regbase + RHRCNT); sh_rtc_set_time() 431 writeb(bin2bcd(tm->tm_wday), rtc->regbase + RWKCNT); sh_rtc_set_time() 432 writeb(bin2bcd(tm->tm_mday), rtc->regbase + RDAYCNT); sh_rtc_set_time() 433 writeb(bin2bcd(tm->tm_mon + 1), rtc->regbase + RMONCNT); sh_rtc_set_time() 436 year = (bin2bcd((tm->tm_year + 1900) / 100) << 8) | sh_rtc_set_time() 437 bin2bcd(tm->tm_year % 100); sh_rtc_set_time() 441 writeb(bin2bcd(year), rtc->regbase + RYRCNT); sh_rtc_set_time() 501 writeb(bin2bcd(value) | AR_ENB, rtc->regbase + reg_off); sh_rtc_write_alarm_value()
|
H A D | rtc-s3c.c | 226 writeb(bin2bcd(tm->tm_sec), info->base + S3C2410_RTCSEC); s3c_rtc_settime() 227 writeb(bin2bcd(tm->tm_min), info->base + S3C2410_RTCMIN); s3c_rtc_settime() 228 writeb(bin2bcd(tm->tm_hour), info->base + S3C2410_RTCHOUR); s3c_rtc_settime() 229 writeb(bin2bcd(tm->tm_mday), info->base + S3C2410_RTCDATE); s3c_rtc_settime() 230 writeb(bin2bcd(tm->tm_mon + 1), info->base + S3C2410_RTCMON); s3c_rtc_settime() 231 writeb(bin2bcd(year), info->base + S3C2410_RTCYEAR); s3c_rtc_settime() 318 writeb(bin2bcd(tm->tm_sec), info->base + S3C2410_ALMSEC); s3c_rtc_setalarm() 323 writeb(bin2bcd(tm->tm_min), info->base + S3C2410_ALMMIN); s3c_rtc_setalarm() 328 writeb(bin2bcd(tm->tm_hour), info->base + S3C2410_ALMHOUR); s3c_rtc_setalarm()
|
H A D | rtc-spear.c | 177 tm->tm_sec = bin2bcd(tm->tm_sec); tm2bcd() 178 tm->tm_min = bin2bcd(tm->tm_min); tm2bcd() 179 tm->tm_hour = bin2bcd(tm->tm_hour); tm2bcd() 180 tm->tm_mday = bin2bcd(tm->tm_mday); tm2bcd() 181 tm->tm_mon = bin2bcd(tm->tm_mon + 1); tm2bcd() 182 tm->tm_year = bin2bcd(tm->tm_year); tm2bcd()
|
H A D | rtc-davinci.c | 335 rtcss_write(davinci_rtc, bin2bcd(tm->tm_sec), PRTCSS_RTC_SEC); davinci_rtc_set_time() 338 rtcss_write(davinci_rtc, bin2bcd(tm->tm_min), PRTCSS_RTC_MIN); davinci_rtc_set_time() 341 rtcss_write(davinci_rtc, bin2bcd(tm->tm_hour), PRTCSS_RTC_HOUR); davinci_rtc_set_time() 454 rtcss_write(davinci_rtc, bin2bcd(alm->time.tm_min), PRTCSS_RTC_AMIN); davinci_rtc_set_alarm() 457 rtcss_write(davinci_rtc, bin2bcd(alm->time.tm_hour), PRTCSS_RTC_AHOUR); davinci_rtc_set_alarm()
|
H A D | rtc-s5m.c | 304 data[RTC_SEC] = bin2bcd(tm->tm_sec); s5m8763_tm_to_data() 305 data[RTC_MIN] = bin2bcd(tm->tm_min); s5m8763_tm_to_data() 306 data[RTC_HOUR] = bin2bcd(tm->tm_hour); s5m8763_tm_to_data() 308 data[RTC_DATE] = bin2bcd(tm->tm_mday); s5m8763_tm_to_data() 309 data[RTC_MONTH] = bin2bcd(tm->tm_mon); s5m8763_tm_to_data() 310 data[RTC_YEAR1] = bin2bcd(tm->tm_year % 100); s5m8763_tm_to_data() 311 data[RTC_YEAR2] = bin2bcd((tm->tm_year + 1900) / 100); s5m8763_tm_to_data()
|
H A D | rtc-ab-b5ze-s3.c | 279 regs[ABB5ZES3_REG_RTC_SC] = bin2bcd(tm->tm_sec); /* MSB=0 clears OSC */ abb5zes3_rtc_set_time() 280 regs[ABB5ZES3_REG_RTC_MN] = bin2bcd(tm->tm_min); abb5zes3_rtc_set_time() 281 regs[ABB5ZES3_REG_RTC_HR] = bin2bcd(tm->tm_hour); /* 24-hour format */ abb5zes3_rtc_set_time() 282 regs[ABB5ZES3_REG_RTC_DT] = bin2bcd(tm->tm_mday); abb5zes3_rtc_set_time() 283 regs[ABB5ZES3_REG_RTC_DW] = bin2bcd(tm->tm_wday); abb5zes3_rtc_set_time() 284 regs[ABB5ZES3_REG_RTC_MO] = bin2bcd(tm->tm_mon + 1); abb5zes3_rtc_set_time() 285 regs[ABB5ZES3_REG_RTC_YR] = bin2bcd(tm->tm_year - 100); abb5zes3_rtc_set_time() 530 regs[0] = bin2bcd(alarm_tm->tm_min) & 0x7f; _abb5zes3_rtc_set_alarm() 531 regs[1] = bin2bcd(alarm_tm->tm_hour) & 0x3f; _abb5zes3_rtc_set_alarm() 532 regs[2] = bin2bcd(alarm_tm->tm_mday) & 0x3f; _abb5zes3_rtc_set_alarm()
|
H A D | rtc-m41t80.c | 168 bin2bcd(tm->tm_sec) | (buf[M41T80_REG_SEC] & ~0x7f); m41t80_set_datetime() 170 bin2bcd(tm->tm_min) | (buf[M41T80_REG_MIN] & ~0x7f); m41t80_set_datetime() 172 bin2bcd(tm->tm_hour) | (buf[M41T80_REG_HOUR] & ~0x3f); m41t80_set_datetime() 176 bin2bcd(tm->tm_mday) | (buf[M41T80_REG_DAY] & ~0x3f); m41t80_set_datetime() 178 bin2bcd(tm->tm_mon + 1) | (buf[M41T80_REG_MON] & ~0x1f); m41t80_set_datetime() 180 buf[M41T80_REG_YEAR] = bin2bcd(tm->tm_year % 100); m41t80_set_datetime()
|
H A D | rtc-omap.c | 262 tm->tm_sec = bin2bcd(tm->tm_sec); tm2bcd() 263 tm->tm_min = bin2bcd(tm->tm_min); tm2bcd() 264 tm->tm_hour = bin2bcd(tm->tm_hour); tm2bcd() 265 tm->tm_mday = bin2bcd(tm->tm_mday); tm2bcd() 267 tm->tm_mon = bin2bcd(tm->tm_mon + 1); tm2bcd() 272 tm->tm_year = bin2bcd(tm->tm_year - 100); tm2bcd()
|
H A D | rtc-cmos.c | 346 mon = (mon <= 12) ? bin2bcd(mon) : 0xff; cmos_set_alarm() 347 mday = (mday >= 1 && mday <= 31) ? bin2bcd(mday) : 0xff; cmos_set_alarm() 348 hrs = (hrs < 24) ? bin2bcd(hrs) : 0xff; cmos_set_alarm() 349 min = (min < 60) ? bin2bcd(min) : 0xff; cmos_set_alarm() 350 sec = (sec < 60) ? bin2bcd(sec) : 0xff; cmos_set_alarm()
|
H A D | rtc-pl031.c | 137 *bcd_year = (bin2bcd(year % 100) | bin2bcd(year / 100) << 8); pl031_stv2_tm_to_time()
|
H A D | rtc-ds1685.c | 90 * ds1685_rtc_bin2bcd - bin2bcd wrapper in case platform doesn't support BCD. 102 return (bin2bcd(val) & bcd_mask); ds1685_rtc_bin2bcd()
|
/linux-4.1.27/arch/powerpc/platforms/chrp/ |
H A D | time.c | 101 tm.tm_sec = bin2bcd(tm.tm_sec); chrp_set_rtc_time() 102 tm.tm_min = bin2bcd(tm.tm_min); chrp_set_rtc_time() 103 tm.tm_hour = bin2bcd(tm.tm_hour); chrp_set_rtc_time() 104 tm.tm_mon = bin2bcd(tm.tm_mon); chrp_set_rtc_time() 105 tm.tm_mday = bin2bcd(tm.tm_mday); chrp_set_rtc_time() 106 tm.tm_year = bin2bcd(tm.tm_year); chrp_set_rtc_time()
|
/linux-4.1.27/arch/m68k/mvme16x/ |
H A D | rtc.c | 103 rtc->bcd_sec = bin2bcd(sec); rtc_ioctl() 104 rtc->bcd_min = bin2bcd(min); rtc_ioctl() 105 rtc->bcd_hr = bin2bcd(hrs); rtc_ioctl() 106 rtc->bcd_dom = bin2bcd(day); rtc_ioctl() 107 rtc->bcd_mth = bin2bcd(mon); rtc_ioctl() 108 rtc->bcd_year = bin2bcd(yrs%100); rtc_ioctl()
|
/linux-4.1.27/arch/m68k/bvme6000/ |
H A D | rtc.c | 112 rtc->bcd_sec = bin2bcd(sec); rtc_ioctl() 113 rtc->bcd_min = bin2bcd(min); rtc_ioctl() 114 rtc->bcd_hr = bin2bcd(hrs); rtc_ioctl() 115 rtc->bcd_dom = bin2bcd(day); rtc_ioctl() 116 rtc->bcd_mth = bin2bcd(mon); rtc_ioctl() 117 rtc->bcd_year = bin2bcd(yrs%100); rtc_ioctl() 119 rtc->bcd_dow = bin2bcd(rtc_tm.tm_wday+1); rtc_ioctl()
|
H A D | config.c | 280 rtc->bcd_sec = bin2bcd(t->tm_sec); bvme6000_hwclk() 281 rtc->bcd_min = bin2bcd(t->tm_min); bvme6000_hwclk() 282 rtc->bcd_hr = bin2bcd(t->tm_hour); bvme6000_hwclk() 283 rtc->bcd_dom = bin2bcd(t->tm_mday); bvme6000_hwclk() 284 rtc->bcd_mth = bin2bcd(t->tm_mon + 1); bvme6000_hwclk() 285 rtc->bcd_year = bin2bcd(t->tm_year%100); bvme6000_hwclk() 287 rtc->bcd_dow = bin2bcd(t->tm_wday+1); bvme6000_hwclk() 340 rtc->bcd_min = bin2bcd(real_minutes); bvme6000_set_clock_mmss() 341 rtc->bcd_sec = bin2bcd(real_seconds); bvme6000_set_clock_mmss()
|
/linux-4.1.27/arch/powerpc/platforms/maple/ |
H A D | time.c | 106 sec = bin2bcd(sec); maple_set_rtc_time() 107 min = bin2bcd(min); maple_set_rtc_time() 108 hour = bin2bcd(hour); maple_set_rtc_time() 109 mon = bin2bcd(mon); maple_set_rtc_time() 110 mday = bin2bcd(mday); maple_set_rtc_time() 111 year = bin2bcd(year); maple_set_rtc_time()
|
/linux-4.1.27/arch/mips/sibyte/swarm/ |
H A D | rtc_xicor1241.c | 127 tm.tm_sec = bin2bcd(tm.tm_sec); xicor_set_time() 130 tm.tm_min = bin2bcd(tm.tm_min); xicor_set_time() 133 tm.tm_mday = bin2bcd(tm.tm_mday); xicor_set_time() 138 tm.tm_mon = bin2bcd(tm.tm_mon); xicor_set_time() 151 tm.tm_hour = bin2bcd(tm.tm_hour); xicor_set_time() 160 tm.tm_hour = bin2bcd(tm.tm_hour); xicor_set_time()
|
H A D | rtc_m41t81.c | 159 tm.tm_sec = bin2bcd(tm.tm_sec); m41t81_set_time() 162 tm.tm_min = bin2bcd(tm.tm_min); m41t81_set_time() 165 tm.tm_hour = bin2bcd(tm.tm_hour); m41t81_set_time() 171 tm.tm_wday = bin2bcd(tm.tm_wday); m41t81_set_time() 174 tm.tm_mday = bin2bcd(tm.tm_mday); m41t81_set_time() 179 tm.tm_mon = bin2bcd(tm.tm_mon); m41t81_set_time() 184 tm.tm_year = bin2bcd(tm.tm_year); m41t81_set_time()
|
/linux-4.1.27/include/asm-generic/ |
H A D | rtc.h | 166 sec = bin2bcd(sec); __set_rtc_time() 167 min = bin2bcd(min); __set_rtc_time() 168 hrs = bin2bcd(hrs); __set_rtc_time() 169 day = bin2bcd(day); __set_rtc_time() 170 mon = bin2bcd(mon); __set_rtc_time() 171 yrs = bin2bcd(yrs); __set_rtc_time()
|
/linux-4.1.27/arch/m68k/atari/ |
H A D | time.c | 198 sec = bin2bcd(sec); atari_tt_hwclk() 199 min = bin2bcd(min); atari_tt_hwclk() 200 hour = bin2bcd(hour); atari_tt_hwclk() 201 day = bin2bcd(day); atari_tt_hwclk() 202 mon = bin2bcd(mon); atari_tt_hwclk() 203 year = bin2bcd(year); atari_tt_hwclk() 205 wday = bin2bcd(wday); atari_tt_hwclk() 337 real_seconds = bin2bcd(real_seconds); atari_tt_set_clock_mmss() 338 real_minutes = bin2bcd(real_minutes); atari_tt_set_clock_mmss()
|
/linux-4.1.27/arch/m68k/q40/ |
H A D | config.c | 234 Q40_RTC_SECS = bin2bcd(t->tm_sec); q40_hwclk() 235 Q40_RTC_MINS = bin2bcd(t->tm_min); q40_hwclk() 236 Q40_RTC_HOUR = bin2bcd(t->tm_hour); q40_hwclk() 237 Q40_RTC_DATE = bin2bcd(t->tm_mday); q40_hwclk() 238 Q40_RTC_MNTH = bin2bcd(t->tm_mon + 1); q40_hwclk() 239 Q40_RTC_YEAR = bin2bcd(t->tm_year%100); q40_hwclk() 241 Q40_RTC_DOW = bin2bcd(t->tm_wday+1); q40_hwclk() 288 Q40_RTC_MINS = bin2bcd(real_minutes); q40_set_clock_mmss() 289 Q40_RTC_SECS = bin2bcd(real_seconds); q40_set_clock_mmss()
|
/linux-4.1.27/drivers/char/ |
H A D | ds1302.c | 214 sec = bin2bcd(sec); rtc_ioctl() 215 min = bin2bcd(min); rtc_ioctl() 216 hrs = bin2bcd(hrs); rtc_ioctl() 217 day = bin2bcd(day); rtc_ioctl() 218 mon = bin2bcd(mon); rtc_ioctl() 219 yrs = bin2bcd(yrs); rtc_ioctl()
|
H A D | rtc.c | 519 sec = bin2bcd(sec); rtc_do_ioctl() 524 min = bin2bcd(min); rtc_do_ioctl() 529 hrs = bin2bcd(hrs); rtc_do_ioctl() 615 sec = bin2bcd(sec); rtc_do_ioctl() 616 min = bin2bcd(min); rtc_do_ioctl() 617 hrs = bin2bcd(hrs); rtc_do_ioctl() 618 day = bin2bcd(day); rtc_do_ioctl() 619 mon = bin2bcd(mon); rtc_do_ioctl() 620 yrs = bin2bcd(yrs); rtc_do_ioctl()
|
/linux-4.1.27/arch/mips/include/asm/ |
H A D | mc146818-time.h | 63 real_seconds = bin2bcd(real_seconds); mc146818_set_rtc_mmss() 64 real_minutes = bin2bcd(real_minutes); mc146818_set_rtc_mmss()
|
/linux-4.1.27/arch/mips/dec/ |
H A D | time.c | 101 real_seconds = bin2bcd(real_seconds); rtc_mips_set_mmss() 102 real_minutes = bin2bcd(real_minutes); rtc_mips_set_mmss()
|
/linux-4.1.27/arch/mn10300/kernel/ |
H A D | rtc.c | 86 real_seconds = bin2bcd(real_seconds); set_rtc_mmss() 87 real_minutes = bin2bcd(real_minutes); set_rtc_mmss()
|
/linux-4.1.27/drivers/mfd/ |
H A D | menelaus.c | 860 status = menelaus_write_reg(regnum++, bin2bcd(t->tm_sec)); time_to_menelaus() 864 status = menelaus_write_reg(regnum++, bin2bcd(t->tm_min)); time_to_menelaus() 871 hour = RTC_HR_PM | bin2bcd(hour - 12); time_to_menelaus() 873 hour = bin2bcd(hour); time_to_menelaus() 875 hour = bin2bcd(t->tm_hour); time_to_menelaus() 880 status = menelaus_write_reg(regnum++, bin2bcd(t->tm_mday)); time_to_menelaus() 884 status = menelaus_write_reg(regnum++, bin2bcd(t->tm_mon + 1)); time_to_menelaus() 888 status = menelaus_write_reg(regnum++, bin2bcd(t->tm_year - 100)); time_to_menelaus() 938 status = menelaus_write_reg(MENELAUS_RTC_WKDAY, bin2bcd(t->tm_wday)); menelaus_set_time()
|
/linux-4.1.27/arch/alpha/kernel/ |
H A D | rtc.c | 169 real_seconds = bin2bcd(real_seconds); alpha_rtc_set_mmss() 170 real_minutes = bin2bcd(real_minutes); alpha_rtc_set_mmss()
|
H A D | core_marvel.c | 671 ret = bin2bcd(rtc_access.data); __marvel_rtc_io()
|
/linux-4.1.27/arch/ia64/include/asm/ |
H A D | sal.h | 238 #define SAL_VERSION_CODE(major, minor) ((bin2bcd(major) << 8) | bin2bcd(minor))
|
/linux-4.1.27/include/linux/usb/ |
H A D | composite.h | 558 bcdDevice = bin2bcd((LINUX_VERSION_CODE >> 16 & 0xff)) << 8; get_default_bcdDevice() 559 bcdDevice |= bin2bcd((LINUX_VERSION_CODE >> 8 & 0xff)); get_default_bcdDevice()
|
/linux-4.1.27/drivers/ide/ |
H A D | ide-cd.c | 1046 toc->hdr.first_track = (u8)bin2bcd(CDROM_LEADOUT); ide_cd_read_toc() 1047 toc->hdr.last_track = (u8)bin2bcd(CDROM_LEADOUT); ide_cd_read_toc()
|
/linux-4.1.27/drivers/usb/core/ |
H A D | hcd.c | 128 #define KERNEL_REL bin2bcd(((LINUX_VERSION_CODE >> 16) & 0x0ff)) 129 #define KERNEL_VER bin2bcd(((LINUX_VERSION_CODE >> 8) & 0x0ff))
|