* [Qemu-devel] [PATCH] rtc: remove dead SQW IRQ code
@ 2013-08-14 11:29 Jan Kiszka
2013-11-04 13:30 ` Jan Kiszka
0 siblings, 1 reply; 2+ messages in thread
From: Jan Kiszka @ 2013-08-14 11:29 UTC (permalink / raw)
To: qemu-devel, Anthony Liguori; +Cc: Gerd Hoffmann
This was once introduced by commit 100d9891d6 but was never used in-tree
and then got broken by commit 32e0c8260d. Time to clean up.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
hw/timer/mc146818rtc.c | 9 +--------
1 files changed, 1 insertions(+), 8 deletions(-)
diff --git a/hw/timer/mc146818rtc.c b/hw/timer/mc146818rtc.c
index 3c3baac..b3f1baa 100644
--- a/hw/timer/mc146818rtc.c
+++ b/hw/timer/mc146818rtc.c
@@ -70,7 +70,6 @@ typedef struct RTCState {
uint64_t last_update;
int64_t offset;
qemu_irq irq;
- qemu_irq sqw_irq;
int it_shift;
/* periodic timer */
QEMUTimer *periodic_timer;
@@ -151,8 +150,7 @@ static void periodic_timer_update(RTCState *s, int64_t current_time)
period_code = s->cmos_data[RTC_REG_A] & 0x0f;
if (period_code != 0
- && ((s->cmos_data[RTC_REG_B] & REG_B_PIE)
- || ((s->cmos_data[RTC_REG_B] & REG_B_SQWE) && s->sqw_irq))) {
+ && (s->cmos_data[RTC_REG_B] & REG_B_PIE)) {
if (period_code <= 2)
period_code += 7;
/* period in 32 Khz cycles */
@@ -202,11 +200,6 @@ static void rtc_periodic_timer(void *opaque)
#endif
qemu_irq_raise(s->irq);
}
- if (s->cmos_data[RTC_REG_B] & REG_B_SQWE) {
- /* Not square wave at all but we don't want 2048Hz interrupts!
- Must be seen as a pulse. */
- qemu_irq_raise(s->sqw_irq);
- }
}
/* handle update-ended timer */
--
1.7.3.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Qemu-devel] [PATCH] rtc: remove dead SQW IRQ code
2013-08-14 11:29 [Qemu-devel] [PATCH] rtc: remove dead SQW IRQ code Jan Kiszka
@ 2013-11-04 13:30 ` Jan Kiszka
0 siblings, 0 replies; 2+ messages in thread
From: Jan Kiszka @ 2013-11-04 13:30 UTC (permalink / raw)
To: qemu-devel, Anthony Liguori; +Cc: Gerd Hoffmann
On 2013-08-14 13:29, Jan Kiszka wrote:
> This was once introduced by commit 100d9891d6 but was never used in-tree
> and then got broken by commit 32e0c8260d. Time to clean up.
>
> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
> ---
> hw/timer/mc146818rtc.c | 9 +--------
> 1 files changed, 1 insertions(+), 8 deletions(-)
>
> diff --git a/hw/timer/mc146818rtc.c b/hw/timer/mc146818rtc.c
> index 3c3baac..b3f1baa 100644
> --- a/hw/timer/mc146818rtc.c
> +++ b/hw/timer/mc146818rtc.c
> @@ -70,7 +70,6 @@ typedef struct RTCState {
> uint64_t last_update;
> int64_t offset;
> qemu_irq irq;
> - qemu_irq sqw_irq;
> int it_shift;
> /* periodic timer */
> QEMUTimer *periodic_timer;
> @@ -151,8 +150,7 @@ static void periodic_timer_update(RTCState *s, int64_t current_time)
>
> period_code = s->cmos_data[RTC_REG_A] & 0x0f;
> if (period_code != 0
> - && ((s->cmos_data[RTC_REG_B] & REG_B_PIE)
> - || ((s->cmos_data[RTC_REG_B] & REG_B_SQWE) && s->sqw_irq))) {
> + && (s->cmos_data[RTC_REG_B] & REG_B_PIE)) {
> if (period_code <= 2)
> period_code += 7;
> /* period in 32 Khz cycles */
> @@ -202,11 +200,6 @@ static void rtc_periodic_timer(void *opaque)
> #endif
> qemu_irq_raise(s->irq);
> }
> - if (s->cmos_data[RTC_REG_B] & REG_B_SQWE) {
> - /* Not square wave at all but we don't want 2048Hz interrupts!
> - Must be seen as a pulse. */
> - qemu_irq_raise(s->sqw_irq);
> - }
> }
>
> /* handle update-ended timer */
>
ping
Jan
--
Siemens AG, Corporate Technology, CT RTC ITP SES-DE
Corporate Competence Center Embedded Linux
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-11-04 13:30 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-08-14 11:29 [Qemu-devel] [PATCH] rtc: remove dead SQW IRQ code Jan Kiszka
2013-11-04 13:30 ` Jan Kiszka
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).