From: Stephen Rothwell <sfr@canb•auug.org.au>
To: Alexandre Belloni <alexandre.belloni@bootlin•com>
Cc: Daniel Palmer <daniel@0x0f•com>,
Finn Thain <fthain@linux-m68k•org>,
Geert Uytterhoeven <geert@linux-m68k•org>,
Linux Kernel Mailing List <linux-kernel@vger•kernel.org>,
Linux Next Mailing List <linux-next@vger•kernel.org>
Subject: linux-next: manual merge of the rtc tree with Linus' tree
Date: Mon, 25 Nov 2024 13:50:19 +1100 [thread overview]
Message-ID: <20241125135019.2f2653ff@canb.auug.org.au> (raw)
[-- Attachment #1: Type: text/plain, Size: 2658 bytes --]
Hi all,
Today's linux-next merge of the rtc tree got a conflict in:
arch/m68k/mvme147/config.c
between commits:
2a9517b6f9c4 ("m68k: mvme147: Make mvme147_sched_init() __init")
077b33b9e283 ("m68k: mvme147: Reinstate early console")
from Linus' tree and commit:
1ec371bab200 ("m68k: mvme147, mvme16x: Adopt rtc-m48t59 platform driver")
from the rtc tree.
I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging. You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.
--
Cheers,
Stephen Rothwell
diff --cc arch/m68k/mvme147/config.c
index 824c42a302c6,2e8f41636efb..000000000000
--- a/arch/m68k/mvme147/config.c
+++ b/arch/m68k/mvme147/config.c
@@@ -32,11 -33,9 +33,10 @@@
#include <asm/mvme147hw.h>
#include <asm/config.h>
+#include "mvme147.h"
static void mvme147_get_model(char *model);
-extern void mvme147_sched_init(void);
+static void __init mvme147_sched_init(void);
- extern int mvme147_hwclk (int, struct rtc_time *);
extern void mvme147_reset (void);
@@@ -162,56 -179,3 +180,31 @@@ static u64 mvme147_read_clk(struct cloc
return ticks;
}
- static int bcd2int (unsigned char b)
- {
- return ((b>>4)*10 + (b&15));
- }
-
- int mvme147_hwclk(int op, struct rtc_time *t)
- {
- if (!op) {
- m147_rtc->ctrl = RTC_READ;
- t->tm_year = bcd2int (m147_rtc->bcd_year);
- t->tm_mon = bcd2int(m147_rtc->bcd_mth) - 1;
- t->tm_mday = bcd2int (m147_rtc->bcd_dom);
- t->tm_hour = bcd2int (m147_rtc->bcd_hr);
- t->tm_min = bcd2int (m147_rtc->bcd_min);
- t->tm_sec = bcd2int (m147_rtc->bcd_sec);
- m147_rtc->ctrl = 0;
- if (t->tm_year < 70)
- t->tm_year += 100;
- } else {
- /* FIXME Setting the time is not yet supported */
- return -EOPNOTSUPP;
- }
- return 0;
- }
-
+static void scc_delay(void)
+{
+ __asm__ __volatile__ ("nop; nop;");
+}
+
+static void scc_write(char ch)
+{
+ do {
+ scc_delay();
+ } while (!(in_8(M147_SCC_A_ADDR) & BIT(2)));
+ scc_delay();
+ out_8(M147_SCC_A_ADDR, 8);
+ scc_delay();
+ out_8(M147_SCC_A_ADDR, ch);
+}
+
+void mvme147_scc_write(struct console *co, const char *str, unsigned int count)
+{
+ unsigned long flags;
+
+ local_irq_save(flags);
+ while (count--) {
+ if (*str == '\n')
+ scc_write('\r');
+ scc_write(*str++);
+ }
+ local_irq_restore(flags);
+}
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
next reply other threads:[~2024-11-25 2:50 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-25 2:50 Stephen Rothwell [this message]
-- strict thread matches above, loose matches on Subject: below --
2017-07-10 3:57 linux-next: manual merge of the rtc tree with Linus' tree Stephen Rothwell
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=20241125135019.2f2653ff@canb.auug.org.au \
--to=sfr@canb$(echo .)auug.org.au \
--cc=alexandre.belloni@bootlin$(echo .)com \
--cc=daniel@0x0f$(echo .)com \
--cc=fthain@linux-m68k$(echo .)org \
--cc=geert@linux-m68k$(echo .)org \
--cc=linux-kernel@vger$(echo .)kernel.org \
--cc=linux-next@vger$(echo .)kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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