linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Geert Uytterhoeven <geert@linux-m68k.org>
To: Marcelo Tosatti <marcelo@conectiva.com.br>
Cc: Linux Kernel Development <linux-kernel@vger.kernel.org>,
	Geert Uytterhoeven <geert@linux-m68k.org>
Subject: [PATCH] M68k RTC updates
Date: Fri, 29 Aug 2003 16:50:57 +0200	[thread overview]
Message-ID: <200308291450.h7TEovIR005871@callisto.of.borg> (raw)

M68k: Use genrtc on all m68k platforms

--- linux-2.4.23-pre1/arch/m68k/atari/time.c	Wed May 29 10:12:36 2002
+++ linux-m68k-2.4.23-pre1/arch/m68k/atari/time.c	Mon Jun 30 15:15:40 2003
@@ -16,7 +16,7 @@
 #include <linux/init.h>
 #include <linux/rtc.h>
 
-#include <asm/rtc.h>
+#include <asm/atariints.h>
 
 void __init
 atari_sched_init(void (*timer_routine)(int, void *, struct pt_regs *))
--- linux-2.4.23-pre1/arch/m68k/config.in	Mon Jul 21 16:52:40 2003
+++ linux-m68k-2.4.23-pre1/arch/m68k/config.in	Wed Jul  9 13:38:18 2003
@@ -527,14 +513,10 @@
    bool '  Disable watchdog shutdown on close' CONFIG_WATCHDOG_NOWAYOUT
    bool '  Software Watchdog' CONFIG_SOFT_WATCHDOG
 fi
-if [ "$CONFIG_ATARI" = "y" ]; then
-   bool 'Enhanced Real Time Clock Support' CONFIG_RTC
+if [ "$CONFIG_SUN3" = "y" ]; then
+   define_bool CONFIG_GEN_RTC y
 else
-   if [ "$CONFIG_SUN3" = "y" ]; then
-      define_bool CONFIG_GEN_RTC y
-   else
-      tristate 'Generic /dev/rtc emulation' CONFIG_GEN_RTC      
-   fi
+   tristate 'Generic /dev/rtc emulation' CONFIG_GEN_RTC      
 fi
 if [ "$CONFIG_GEN_RTC" != "n" ]; then
    bool '   Extended RTC operation' CONFIG_GEN_RTC_X
--- linux-2.4.23-pre1/include/asm-m68k/mc146818rtc.h	Wed Oct 17 12:41:21 2001
+++ linux-m68k-2.4.23-pre1/include/asm-m68k/mc146818rtc.h	Mon Jun 30 15:15:42 2003
@@ -4,37 +4,12 @@
 #ifndef _ASM_MC146818RTC_H
 #define _ASM_MC146818RTC_H
 
-#include <linux/config.h>
-#include <asm/atarihw.h>
-
 #ifdef CONFIG_ATARI
 /* RTC in Atari machines */
 
 #include <asm/atarihw.h>
-#include <asm/atariints.h>
-#include <asm/io.h>
-#define RTC_HAS_IRQ	(ATARIHW_PRESENT(TT_MFP))
-#define RTC_IRQ 	IRQ_TT_MFP_RTC
-#define RTC_IRQ_FLAGS	IRQ_TYPE_FAST
-#define RTC_PORT(x)	(TT_RTC_BAS + 2*(x))
-#define RTC_ALWAYS_BCD	0	/* TOS uses binary mode, Linux should be able
-				 * to deal with both modes */
 
-#define RTC_CHECK_DRIVER_INIT() (MACH_IS_ATARI && ATARIHW_PRESENT(TT_CLK))
-#define RTC_MACH_INIT()							\
-    do {								\
-	epoch = atari_rtc_year_offset + 1900;				\
-	if (RTC_HAS_IRQ)						\
-	    /* select RTC int on H->L edge */				\
-	    tt_mfp.active_edge &= ~0x40;				\
-    } while(0)
-#define RTC_MACH_EXIT()
-
-/* On Atari, the year was stored with base 1970 in old TOS versions (before
- * 3.06). Later, Atari recognized that this broke leap year recognition, and
- * changed the base to 1968. Medusa and Hades always use the new version. */
-#define RTC_CENTURY_SWITCH	-1	/* no century switch */
-#define RTC_MINYEAR		epoch
+#define RTC_PORT(x)	(TT_RTC_BAS + 2*(x))
 
 #define CMOS_READ(addr) ({ \
 atari_outb_p((addr),RTC_PORT(0)); \

Gr{oetje,eeting}s,

						Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
							    -- Linus Torvalds

             reply	other threads:[~2003-08-29 14:55 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-08-29 14:50 Geert Uytterhoeven [this message]
  -- strict thread matches above, loose matches on Subject: below --
2003-07-26 14:51 [PATCH] M68k RTC updates Geert Uytterhoeven

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200308291450.h7TEovIR005871@callisto.of.borg \
    --to=geert@linux-m68k.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=marcelo@conectiva.com.br \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).