Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit de339e4b authored by Geert Uytterhoeven's avatar Geert Uytterhoeven
Browse files

m68k/atari: Rename "scc" to "atari_scc"



It's a way too generic name for a global #define and conflicts with a variable
with the same name, causing build errors like:

| drivers/staging/brcm80211/brcmfmac/../util/siutils.c: In function ‘_si_clkctl_cc’:
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1364: error: expected identifier or ‘(’ before ‘volatile’
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1364: error: expected ‘)’ before ‘(’ token
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1421: error: incompatible types in assignment
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1422: error: invalid operands to binary &
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1423: error: invalid operands to binary &
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1424: error: invalid operands to binary |
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1425: error: aggregate value used where an integer was expected
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1425: error: aggregate value used where an integer was expected
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1425: error: aggregate value used where an integer was expected
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1425: error: aggregate value used where an integer was expected
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1425: error: aggregate value used where an integer was expected
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1425: error: aggregate value used where an integer was expected
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1425: error: aggregate value used where an integer was expected
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1425: error: aggregate value used where an integer was expected
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1425: error: aggregate value used where an integer was expected
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1425: error: aggregate value used where an integer was expected
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1425: error: aggregate value used where an integer was expected
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1425: error: incompatible type for argument 4 of ‘bcmsdh_reg_write’
| drivers/staging/brcm80211/brcmfmac/../util/siutils.c:1428: error: invalid operands to binary &
| make[8]: *** [drivers/staging/brcm80211/brcmfmac/../util/siutils.o] Error 1

Signed-off-by: default avatarGeert Uytterhoeven <geert@linux-m68k.org>
parent f9b07897
Loading
Loading
Loading
Loading
+2 −2
Original line number Original line Diff line number Diff line
@@ -388,9 +388,9 @@ void __init atari_init_IRQ(void)
	}
	}


	if (ATARIHW_PRESENT(SCC) && !atari_SCC_reset_done) {
	if (ATARIHW_PRESENT(SCC) && !atari_SCC_reset_done) {
		scc.cha_a_ctrl = 9;
		atari_scc.cha_a_ctrl = 9;
		MFPDELAY();
		MFPDELAY();
		scc.cha_a_ctrl = (char) 0xc0; /* hardware reset */
		atari_scc.cha_a_ctrl = (char) 0xc0; /* hardware reset */
	}
	}


	if (ATARIHW_PRESENT(SCU)) {
	if (ATARIHW_PRESENT(SCU)) {
+1 −1
Original line number Original line Diff line number Diff line
@@ -315,7 +315,7 @@ void __init config_atari(void)
		ATARIHW_SET(SCC_DMA);
		ATARIHW_SET(SCC_DMA);
		printk("SCC_DMA ");
		printk("SCC_DMA ");
	}
	}
	if (scc_test(&scc.cha_a_ctrl)) {
	if (scc_test(&atari_scc.cha_a_ctrl)) {
		ATARIHW_SET(SCC);
		ATARIHW_SET(SCC);
		printk("SCC ");
		printk("SCC ");
	}
	}
+7 −7
Original line number Original line Diff line number Diff line
@@ -53,9 +53,9 @@ static inline void ata_scc_out(char c)
{
{
	do {
	do {
		MFPDELAY();
		MFPDELAY();
	} while (!(scc.cha_b_ctrl & 0x04)); /* wait for tx buf empty */
	} while (!(atari_scc.cha_b_ctrl & 0x04)); /* wait for tx buf empty */
	MFPDELAY();
	MFPDELAY();
	scc.cha_b_data = c;
	atari_scc.cha_b_data = c;
}
}


static void atari_scc_console_write(struct console *co, const char *str,
static void atari_scc_console_write(struct console *co, const char *str,
@@ -140,9 +140,9 @@ int atari_scc_console_wait_key(struct console *co)
{
{
	do {
	do {
		MFPDELAY();
		MFPDELAY();
	} while (!(scc.cha_b_ctrl & 0x01)); /* wait for rx buf filled */
	} while (!(atari_scc.cha_b_ctrl & 0x01)); /* wait for rx buf filled */
	MFPDELAY();
	MFPDELAY();
	return scc.cha_b_data;
	return atari_scc.cha_b_data;
}
}


int atari_midi_console_wait_key(struct console *co)
int atari_midi_console_wait_key(struct console *co)
@@ -185,9 +185,9 @@ static void __init atari_init_mfp_port(int cflag)


#define SCC_WRITE(reg, val)				\
#define SCC_WRITE(reg, val)				\
	do {						\
	do {						\
		scc.cha_b_ctrl = (reg);			\
		atari_scc.cha_b_ctrl = (reg);		\
		MFPDELAY();				\
		MFPDELAY();				\
		scc.cha_b_ctrl = (val);			\
		atari_scc.cha_b_ctrl = (val);		\
		MFPDELAY();				\
		MFPDELAY();				\
	} while (0)
	} while (0)


@@ -240,7 +240,7 @@ static void __init atari_init_scc_port(int cflag)
	reg3 = (cflag & CSIZE) == CS8 ? 0xc0 : 0x40;
	reg3 = (cflag & CSIZE) == CS8 ? 0xc0 : 0x40;
	reg5 = (cflag & CSIZE) == CS8 ? 0x60 : 0x20 | 0x82 /* assert DTR/RTS */;
	reg5 = (cflag & CSIZE) == CS8 ? 0x60 : 0x20 | 0x82 /* assert DTR/RTS */;


	(void)scc.cha_b_ctrl;		/* reset reg pointer */
	(void)atari_scc.cha_b_ctrl;	/* reset reg pointer */
	SCC_WRITE(9, 0xc0);		/* reset */
	SCC_WRITE(9, 0xc0);		/* reset */
	LONG_DELAY();			/* extra delay after WR9 access */
	LONG_DELAY();			/* extra delay after WR9 access */
	SCC_WRITE(4, (cflag & PARENB) ? ((cflag & PARODD) ? 0x01 : 0x03)
	SCC_WRITE(4, (cflag & PARENB) ? ((cflag & PARODD) ? 0x01 : 0x03)
+1 −1
Original line number Original line Diff line number Diff line
@@ -449,7 +449,7 @@ struct SCC
  u_char char_dummy3;
  u_char char_dummy3;
  u_char cha_b_data;
  u_char cha_b_data;
 };
 };
# define scc ((*(volatile struct SCC*)SCC_BAS))
# define atari_scc ((*(volatile struct SCC*)SCC_BAS))


/* The ESCC (Z85230) in an Atari ST. The channels are reversed! */
/* The ESCC (Z85230) in an Atari ST. The channels are reversed! */
# define st_escc ((*(volatile struct SCC*)0xfffffa31))
# define st_escc ((*(volatile struct SCC*)0xfffffa31))