It's kernel business to return EINVAL for unsupported RTC_UIE_ON. We
(userspace) should not make decisions about things that we do not
control.
If kernel is wrong then fix the kernel, don't hide the problem by
crazy ifdefs in userspace.
Signed-off-by: Karel Zak <kzak@redhat.com>
warn(_("cannot open rtc device"));
return ret;
} else {
- int rc; /* Return code from ioctl */
/* Turn on update interrupts (one per second) */
-#if defined(__alpha__) || defined(__sparc__)
- /*
- * Not all alpha kernels reject RTC_UIE_ON, but probably
- * they should.
- */
- rc = -1;
- errno = EINVAL;
-#else
- rc = ioctl(rtc_fd, RTC_UIE_ON, 0);
-#endif
+ int rc = ioctl(rtc_fd, RTC_UIE_ON, 0);
+
if (rc != -1) {
/*
* Just reading rtc_fd fails on broken hardware: no