rtc.c: decode RTC_PLL_GET and RTC_PLL_SET
* rtc.c (rtc_ioctl): Decode RTC_PLL_GET and RTC_PLL_SET
diff --git a/rtc.c b/rtc.c
index 1978ff0..c54b9a8 100644
--- a/rtc.c
+++ b/rtc.c
@@ -65,6 +65,18 @@
}
}
+static void
+decode_rtc_pll_info(struct tcb *tcp, const long addr)
+{
+ struct rtc_pll_info pll;
+
+ if (!umove_or_printaddr(tcp, addr, &pll))
+ tprintf("{pll_ctrl=%d, pll_value=%d, pll_max=%d, pll_min=%d"
+ ", pll_posmult=%d, pll_negmult=%d, pll_clock=%ld}",
+ pll.pll_ctrl, pll.pll_value, pll.pll_max, pll.pll_min,
+ pll.pll_posmult, pll.pll_negmult, pll.pll_clock);
+}
+
int
rtc_ioctl(struct tcb *tcp, const unsigned int code, const long arg)
{
@@ -98,6 +110,14 @@
tprints(", ");
decode_rtc_wkalrm(tcp, arg);
break;
+ case RTC_PLL_GET:
+ if (entering(tcp))
+ return 0;
+ /* fall through */
+ case RTC_PLL_SET:
+ tprints(", ");
+ decode_rtc_pll_info(tcp, arg);
+ break;
#ifdef RTC_VL_READ
case RTC_VL_READ:
if (entering(tcp))