#define RTCGET _IOR('p', 20, struct sparc_rtc_time)
#define RTCSET _IOW('p', 21, struct sparc_rtc_time)
-/* non-sparc stuff */
-#if 0
-# include <linux/version.h>
-/*
- * Check if the /dev/rtc interface is available in this version of the
- * system headers. 131072 is linux 2.0.0.
- */
-# if LINUX_VERSION_CODE >= 131072
-# include <linux/mc146818rtc.h>
-# endif
-#endif
-
/*
* struct rtc_time is present since 1.3.99.
* Earlier (since 1.3.89), a struct tm was used.
printf(_("Not adjusting drift factor because it has "
"been less than four hours since the last "
"calibration.\n"));
- } else if (adjtime_p->last_calib_time != 0) {
+ } else {
/*
* At adjustment time we drift correct the hardware clock
* according to the contents of the adjtime file and refresh
manipulate_clock(const struct hwclock_control *ctl, const time_t set_time,
const struct timeval startup_time, struct adjtime *adjtime)
{
- /* Set if user lacks necessary authorization to access the clock */
- bool no_auth;
/* The time at which we read the Hardware Clock */
struct timeval read_time;
/*
/* local return code */
int rc = 0;
- if (!ctl->systz && !ctl->predict) {
- no_auth = ur->get_permissions();
- if (no_auth)
+ if (!ctl->systz && !ctl->predict)
+ if (ur->get_permissions())
return EX_NOPERM;
- }
if ((ctl->set || ctl->systohc || ctl->adjust) &&
(adjtime->local_utc == UTC) != ctl->universal) {