linux-alpha.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/4][PULL] Alpha fixes
@ 2011-04-17 20:05 Richard Henderson
  2011-04-17 20:05 ` [PATCH 1/4] alpha: Don't force -Werror Richard Henderson
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Richard Henderson @ 2011-04-17 20:05 UTC (permalink / raw)
  To: linux-kernel; +Cc: torvalds, mattst88, linux-alpha

These patches are present in

  git://repo.or.cz/linux-2.6/rth.git for-linus

They fix compilation with gcc 4.6, a crash during bootup, and a
hang during bootup.


r~


Richard Henderson (4):
  alpha: Don't force -Werror.
  alpha: Remove set but unused variables.
  alpha: Fix RTC interrupt setup.
  alpha: Fix uninitialized value in read_persistent_clock.

 arch/alpha/kernel/Makefile       |    2 +-
 arch/alpha/kernel/core_mcpcia.c  |   12 +++++-------
 arch/alpha/kernel/err_titan.c    |    4 +---
 arch/alpha/kernel/irq_alpha.c    |    2 +-
 arch/alpha/kernel/setup.c        |    6 +++---
 arch/alpha/kernel/smc37c93x.c    |    3 +--
 arch/alpha/kernel/sys_wildfire.c |    5 +++--
 arch/alpha/kernel/time.c         |    1 +
 8 files changed, 16 insertions(+), 19 deletions(-)

-- 
1.7.4.2


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH 1/4] alpha: Don't force -Werror.
  2011-04-17 20:05 [PATCH 0/4][PULL] Alpha fixes Richard Henderson
@ 2011-04-17 20:05 ` Richard Henderson
  2011-04-17 20:05 ` [PATCH 2/4] alpha: Remove set but unused variables Richard Henderson
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: Richard Henderson @ 2011-04-17 20:05 UTC (permalink / raw)
  To: linux-kernel; +Cc: torvalds, mattst88, linux-alpha

There are outstanding gcc 4.6 warnings that need to be cleaned up
in the subdirectory.  No sense forcing the issue immediately.

Signed-off-by: Richard Henderson <rth@twiddle.net>
---
 arch/alpha/kernel/Makefile |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/alpha/kernel/Makefile b/arch/alpha/kernel/Makefile
index 9bb7b85..7a6d908 100644
--- a/arch/alpha/kernel/Makefile
+++ b/arch/alpha/kernel/Makefile
@@ -4,7 +4,7 @@
 
 extra-y		:= head.o vmlinux.lds
 asflags-y	:= $(KBUILD_CFLAGS)
-ccflags-y	:= -Werror -Wno-sign-compare
+ccflags-y	:= -Wno-sign-compare
 
 obj-y    := entry.o traps.o process.o init_task.o osf_sys.o irq.o \
 	    irq_alpha.o signal.o setup.o ptrace.o time.o \
-- 
1.7.4.2


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH 2/4] alpha: Remove set but unused variables.
  2011-04-17 20:05 [PATCH 0/4][PULL] Alpha fixes Richard Henderson
  2011-04-17 20:05 ` [PATCH 1/4] alpha: Don't force -Werror Richard Henderson
@ 2011-04-17 20:05 ` Richard Henderson
  2011-04-17 20:05 ` [PATCH 3/4] alpha: Fix RTC interrupt setup Richard Henderson
  2011-04-17 20:05 ` [PATCH 4/4] alpha: Fix uninitialized value in read_persistent_clock Richard Henderson
  3 siblings, 0 replies; 5+ messages in thread
From: Richard Henderson @ 2011-04-17 20:05 UTC (permalink / raw)
  To: linux-kernel; +Cc: torvalds, mattst88, linux-alpha

This is a new warning in gcc 4.6.  Several of these variables are
used within #if 0 code, which probably ought to be removed.  Most
of the changes are legitimate cleanups.

Signed-off-by: Richard Henderson <rth@twiddle.net>
---
 arch/alpha/kernel/core_mcpcia.c  |   12 +++++-------
 arch/alpha/kernel/err_titan.c    |    4 +---
 arch/alpha/kernel/setup.c        |    6 +++---
 arch/alpha/kernel/smc37c93x.c    |    3 +--
 arch/alpha/kernel/sys_wildfire.c |    5 +++--
 5 files changed, 13 insertions(+), 17 deletions(-)

diff --git a/arch/alpha/kernel/core_mcpcia.c b/arch/alpha/kernel/core_mcpcia.c
index 381fec0..da7bcc3 100644
--- a/arch/alpha/kernel/core_mcpcia.c
+++ b/arch/alpha/kernel/core_mcpcia.c
@@ -88,7 +88,7 @@ conf_read(unsigned long addr, unsigned char type1,
 {
 	unsigned long flags;
 	unsigned long mid = MCPCIA_HOSE2MID(hose->index);
-	unsigned int stat0, value, temp, cpu;
+	unsigned int stat0, value, cpu;
 
 	cpu = smp_processor_id();
 
@@ -101,7 +101,7 @@ conf_read(unsigned long addr, unsigned char type1,
 	stat0 = *(vuip)MCPCIA_CAP_ERR(mid);
 	*(vuip)MCPCIA_CAP_ERR(mid) = stat0;
 	mb();
-	temp = *(vuip)MCPCIA_CAP_ERR(mid);
+	*(vuip)MCPCIA_CAP_ERR(mid);
 	DBG_CFG(("conf_read: MCPCIA_CAP_ERR(%d) was 0x%x\n", mid, stat0));
 
 	mb();
@@ -136,7 +136,7 @@ conf_write(unsigned long addr, unsigned int value, unsigned char type1,
 {
 	unsigned long flags;
 	unsigned long mid = MCPCIA_HOSE2MID(hose->index);
-	unsigned int stat0, temp, cpu;
+	unsigned int stat0, cpu;
 
 	cpu = smp_processor_id();
 
@@ -145,7 +145,7 @@ conf_write(unsigned long addr, unsigned int value, unsigned char type1,
 	/* Reset status register to avoid losing errors.  */
 	stat0 = *(vuip)MCPCIA_CAP_ERR(mid);
 	*(vuip)MCPCIA_CAP_ERR(mid) = stat0; mb();
-	temp = *(vuip)MCPCIA_CAP_ERR(mid);
+	*(vuip)MCPCIA_CAP_ERR(mid);
 	DBG_CFG(("conf_write: MCPCIA CAP_ERR(%d) was 0x%x\n", mid, stat0));
 
 	draina();
@@ -157,7 +157,7 @@ conf_write(unsigned long addr, unsigned int value, unsigned char type1,
 	*((vuip)addr) = value;
 	mb();
 	mb();  /* magic */
-	temp = *(vuip)MCPCIA_CAP_ERR(mid); /* read to force the write */
+	*(vuip)MCPCIA_CAP_ERR(mid); /* read to force the write */
 	mcheck_expected(cpu) = 0;
 	mb();
 
@@ -572,12 +572,10 @@ mcpcia_print_system_area(unsigned long la_ptr)
 void
 mcpcia_machine_check(unsigned long vector, unsigned long la_ptr)
 {
-	struct el_common *mchk_header;
 	struct el_MCPCIA_uncorrected_frame_mcheck *mchk_logout;
 	unsigned int cpu = smp_processor_id();
 	int expected;
 
-	mchk_header = (struct el_common *)la_ptr;
 	mchk_logout = (struct el_MCPCIA_uncorrected_frame_mcheck *)la_ptr;
 	expected = mcheck_expected(cpu);
 
diff --git a/arch/alpha/kernel/err_titan.c b/arch/alpha/kernel/err_titan.c
index c3b3781..14b26c4 100644
--- a/arch/alpha/kernel/err_titan.c
+++ b/arch/alpha/kernel/err_titan.c
@@ -533,8 +533,6 @@ static struct el_subpacket_annotation el_titan_annotations[] = {
 static struct el_subpacket *
 el_process_regatta_subpacket(struct el_subpacket *header)
 {
-	int status;
-
 	if (header->class != EL_CLASS__REGATTA_FAMILY) {
 		printk("%s  ** Unexpected header CLASS %d TYPE %d, aborting\n",
 		       err_print_prefix,
@@ -551,7 +549,7 @@ el_process_regatta_subpacket(struct el_subpacket *header)
 		printk("%s  ** Occurred on CPU %d:\n", 
 		       err_print_prefix,
 		       (int)header->by_type.regatta_frame.cpuid);
-		status = privateer_process_logout_frame((struct el_common *)
+		privateer_process_logout_frame((struct el_common *)
 			header->by_type.regatta_frame.data_start, 1);
 		break;
 	default:
diff --git a/arch/alpha/kernel/setup.c b/arch/alpha/kernel/setup.c
index d2634e4..edbddcb 100644
--- a/arch/alpha/kernel/setup.c
+++ b/arch/alpha/kernel/setup.c
@@ -1404,8 +1404,6 @@ determine_cpu_caches (unsigned int cpu_type)
 	case PCA56_CPU:
 	case PCA57_CPU:
 	  {
-		unsigned long cbox_config, size;
-
 		if (cpu_type == PCA56_CPU) {
 			L1I = CSHAPE(16*1024, 6, 1);
 			L1D = CSHAPE(8*1024, 5, 1);
@@ -1415,10 +1413,12 @@ determine_cpu_caches (unsigned int cpu_type)
 		}
 		L3 = -1;
 
+#if 0
+		unsigned long cbox_config, size;
+
 		cbox_config = *(vulp) phys_to_virt (0xfffff00008UL);
 		size = 512*1024 * (1 << ((cbox_config >> 12) & 3));
 
-#if 0
 		L2 = ((cbox_config >> 31) & 1 ? CSHAPE (size, 6, 1) : -1);
 #else
 		L2 = external_cache_probe(512*1024, 6);
diff --git a/arch/alpha/kernel/smc37c93x.c b/arch/alpha/kernel/smc37c93x.c
index 3e6a289..6886b83 100644
--- a/arch/alpha/kernel/smc37c93x.c
+++ b/arch/alpha/kernel/smc37c93x.c
@@ -79,7 +79,6 @@
 static unsigned long __init SMCConfigState(unsigned long baseAddr)
 {
 	unsigned char devId;
-	unsigned char devRev;
 
 	unsigned long configPort;
 	unsigned long indexPort;
@@ -100,7 +99,7 @@ static unsigned long __init SMCConfigState(unsigned long baseAddr)
 		devId = inb(dataPort);
 		if (devId == VALID_DEVICE_ID) {
 			outb(DEVICE_REV, indexPort);
-			devRev = inb(dataPort);
+			/* unsigned char devRev = */ inb(dataPort);
 			break;
 		}
 		else
diff --git a/arch/alpha/kernel/sys_wildfire.c b/arch/alpha/kernel/sys_wildfire.c
index d3cb28b..d92cdc7 100644
--- a/arch/alpha/kernel/sys_wildfire.c
+++ b/arch/alpha/kernel/sys_wildfire.c
@@ -156,7 +156,6 @@ static void __init
 wildfire_init_irq_per_pca(int qbbno, int pcano)
 {
 	int i, irq_bias;
-	unsigned long io_bias;
 	static struct irqaction isa_enable = {
 		.handler	= no_action,
 		.name		= "isa_enable",
@@ -165,10 +164,12 @@ wildfire_init_irq_per_pca(int qbbno, int pcano)
 	irq_bias = qbbno * (WILDFIRE_PCA_PER_QBB * WILDFIRE_IRQ_PER_PCA)
 		 + pcano * WILDFIRE_IRQ_PER_PCA;
 
+#if 0
+	unsigned long io_bias;
+
 	/* Only need the following for first PCI bus per PCA. */
 	io_bias = WILDFIRE_IO(qbbno, pcano<<1) - WILDFIRE_IO_BIAS;
 
-#if 0
 	outb(0, DMA1_RESET_REG + io_bias);
 	outb(0, DMA2_RESET_REG + io_bias);
 	outb(DMA_MODE_CASCADE, DMA2_MODE_REG + io_bias);
-- 
1.7.4.2


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH 3/4] alpha: Fix RTC interrupt setup.
  2011-04-17 20:05 [PATCH 0/4][PULL] Alpha fixes Richard Henderson
  2011-04-17 20:05 ` [PATCH 1/4] alpha: Don't force -Werror Richard Henderson
  2011-04-17 20:05 ` [PATCH 2/4] alpha: Remove set but unused variables Richard Henderson
@ 2011-04-17 20:05 ` Richard Henderson
  2011-04-17 20:05 ` [PATCH 4/4] alpha: Fix uninitialized value in read_persistent_clock Richard Henderson
  3 siblings, 0 replies; 5+ messages in thread
From: Richard Henderson @ 2011-04-17 20:05 UTC (permalink / raw)
  To: linux-kernel; +Cc: torvalds, mattst88, linux-alpha

Following 091738a266fc74329ae186f22ff2b3f01319112d we removed
an automatic conversion of no_irq_chip to dummy_irq_chip.  This
change needs to be propagated back into the alpha backend.

Signed-off-by: Richard Henderson <rth@twiddle.net>
---
 arch/alpha/kernel/irq_alpha.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/alpha/kernel/irq_alpha.c b/arch/alpha/kernel/irq_alpha.c
index 1479dc6..51b7fbd 100644
--- a/arch/alpha/kernel/irq_alpha.c
+++ b/arch/alpha/kernel/irq_alpha.c
@@ -228,7 +228,7 @@ struct irqaction timer_irqaction = {
 void __init
 init_rtc_irq(void)
 {
-	irq_set_chip_and_handler_name(RTC_IRQ, &no_irq_chip,
+	irq_set_chip_and_handler_name(RTC_IRQ, &dummy_irq_chip,
 				      handle_simple_irq, "RTC");
 	setup_irq(RTC_IRQ, &timer_irqaction);
 }
-- 
1.7.4.2


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH 4/4] alpha: Fix uninitialized value in read_persistent_clock.
  2011-04-17 20:05 [PATCH 0/4][PULL] Alpha fixes Richard Henderson
                   ` (2 preceding siblings ...)
  2011-04-17 20:05 ` [PATCH 3/4] alpha: Fix RTC interrupt setup Richard Henderson
@ 2011-04-17 20:05 ` Richard Henderson
  3 siblings, 0 replies; 5+ messages in thread
From: Richard Henderson @ 2011-04-17 20:05 UTC (permalink / raw)
  To: linux-kernel; +Cc: torvalds, mattst88, linux-alpha

Signed-off-by: Richard Henderson <rth@twiddle.net>
---
 arch/alpha/kernel/time.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/arch/alpha/kernel/time.c b/arch/alpha/kernel/time.c
index a58e84f..918e8e0 100644
--- a/arch/alpha/kernel/time.c
+++ b/arch/alpha/kernel/time.c
@@ -153,6 +153,7 @@ void read_persistent_clock(struct timespec *ts)
 		year += 100;
 
 	ts->tv_sec = mktime(year, mon, day, hour, min, sec);
+	ts->tv_nsec = 0;
 }
 
 
-- 
1.7.4.2


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2011-04-17 20:05 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-04-17 20:05 [PATCH 0/4][PULL] Alpha fixes Richard Henderson
2011-04-17 20:05 ` [PATCH 1/4] alpha: Don't force -Werror Richard Henderson
2011-04-17 20:05 ` [PATCH 2/4] alpha: Remove set but unused variables Richard Henderson
2011-04-17 20:05 ` [PATCH 3/4] alpha: Fix RTC interrupt setup Richard Henderson
2011-04-17 20:05 ` [PATCH 4/4] alpha: Fix uninitialized value in read_persistent_clock Richard Henderson

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).