mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-10-14 10:37:38 -04:00
Replace a couple of magic numbers with the appropriate constants.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23138 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
7331bd5381
commit
48658eec41
1 changed files with 4 additions and 4 deletions
|
@ -37,9 +37,9 @@ int rtc_read_datetime(struct tm *tm)
|
||||||
oldlevel = disable_irq_save();
|
oldlevel = disable_irq_save();
|
||||||
|
|
||||||
if (get_pmu_type() == PCF50606)
|
if (get_pmu_type() == PCF50606)
|
||||||
rc = pcf50606_read_multiple(0x0a, buf, sizeof(buf));
|
rc = pcf50606_read_multiple(PCF5060X_RTCSC, buf, sizeof(buf));
|
||||||
else
|
else
|
||||||
rc = pcf50635_read_multiple(0x59, buf, sizeof(buf));
|
rc = pcf50635_read_multiple(PCF5063X_REG_RTCSC, buf, sizeof(buf));
|
||||||
|
|
||||||
restore_irq(oldlevel);
|
restore_irq(oldlevel);
|
||||||
|
|
||||||
|
@ -77,9 +77,9 @@ int rtc_write_datetime(const struct tm *tm)
|
||||||
oldlevel = disable_irq_save();
|
oldlevel = disable_irq_save();
|
||||||
|
|
||||||
if (get_pmu_type() == PCF50606)
|
if (get_pmu_type() == PCF50606)
|
||||||
rc = pcf50606_write_multiple(0x0a, buf, sizeof(buf));
|
rc = pcf50606_write_multiple(PCF5060X_RTCSC, buf, sizeof(buf));
|
||||||
else
|
else
|
||||||
rc = pcf50635_write_multiple(0x59, buf, sizeof(buf));
|
rc = pcf50635_write_multiple(PCF5063X_REG_RTCSC, buf, sizeof(buf));
|
||||||
|
|
||||||
restore_irq(oldlevel);
|
restore_irq(oldlevel);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue