[kernel] r6913 - in dists/trunk/linux-2.6/debian/patches: series

Martin Michlmayr tbm at costa.debian.org
Wed Jun 28 13:26:55 UTC 2006


Author: tbm
Date: Wed Jun 28 13:26:47 2006
New Revision: 6913

Added:
   dists/trunk/linux-2.6/debian/patches/mips-dec-rtc.patch
   dists/trunk/linux-2.6/debian/patches/mips-dec-scsi.patch
   dists/trunk/linux-2.6/debian/patches/mips-dec-serial.patch
   dists/trunk/linux-2.6/debian/patches/series/2-extra

Log:
more patches that got lost from 2.6.16-15


Added: dists/trunk/linux-2.6/debian/patches/mips-dec-rtc.patch
==============================================================================
--- (empty file)
+++ dists/trunk/linux-2.6/debian/patches/mips-dec-rtc.patch	Wed Jun 28 13:26:47 2006
@@ -0,0 +1,127 @@
+# Upstream status: in linux-mips tree, submitted to Dmitry Torokhov
+
+[PATCH] char/rtc: Handle memory-mapped chips properly.
+
+From: Maciej W. Rozycki <macro at linux-mips.org>
+
+Handle memory-mapped chips properly, needed for example on DECstations.
+
+Signed-off-by: Maciej W. Rozycki <macro at linux-mips.org>
+Signed-off-by: Martin Michlmayr <tbm at cyrius.com>
+
+
+--- a/include/linux/mc146818rtc.h	2006-03-05 20:35:09.000000000 +0100
++++ b/include/linux/mc146818rtc.h	2006-03-05 19:51:19.000000000 +0100
+@@ -89,4 +89,12 @@
+ # define RTC_VRT 0x80		/* valid RAM and time */
+ /**********************************************************************/
+ 
++#ifndef RTC_IO_EXTENT
++#define RTC_IO_EXTENT	0x8
++#endif
++
++#ifndef RTC_IOMAPPED
++#define RTC_IOMAPPED	1	/* Default to I/O mapping. */
++#endif
++
+ #endif /* _MC146818RTC_H */
+--- a/drivers/char/rtc.c	2006-03-05 20:35:03.000000000 +0100
++++ b/drivers/char/rtc.c	2006-05-24 18:10:33.000000000 +0200
+@@ -46,13 +46,12 @@
+  *      1.11a   Daniele Bellucci: Audit create_proc_read_entry in rtc_init
+  *	1.12	Venkatesh Pallipadi: Hooks for emulating rtc on HPET base-timer
+  *		CONFIG_HPET_EMULATE_RTC
++ *	1.12a	Maciej W. Rozycki: Handle memory-mapped chips properly.
+  *	1.12ac	Alan Cox: Allow read access to the day of week register
+  */
+ 
+ #define RTC_VERSION		"1.12ac"
+ 
+-#define RTC_IO_EXTENT	0x8
+-
+ /*
+  *	Note that *all* calls to CMOS_READ and CMOS_WRITE are done with
+  *	interrupts disabled. Due to the index-port/data-port (0x70/0x71)
+@@ -338,7 +337,15 @@
+ 	if (rtc_has_irq == 0)
+ 		return -EIO;
+ 
+-	if (count < sizeof(unsigned))
++	/*
++	 * Historically this function used to assume that sizeof(unsigned long)
++	 * is the same in userspace and kernelspace.  This lead to problems
++	 * for configurations with multiple ABIs such a the MIPS o32 and 64
++	 * ABIs supported on the same kernel.  So now we support read of both
++	 * 4 and 8 bytes and assume that's the sizeof(unsigned long) in the
++	 * userspace ABI.
++	 */
++	if (count != sizeof(unsigned int) && count !=  sizeof(unsigned long))
+ 		return -EINVAL;
+ 
+ 	add_wait_queue(&rtc_wait, &wait);
+@@ -369,10 +376,12 @@
+ 		schedule();
+ 	} while (1);
+ 
+-	if (count < sizeof(unsigned long))
+-		retval = put_user(data, (unsigned int __user *)buf) ?: sizeof(int); 
++	if (count == sizeof(unsigned int))
++		retval = put_user(data, (unsigned int __user *)buf) ?: sizeof(int);
+ 	else
+ 		retval = put_user(data, (unsigned long __user *)buf) ?: sizeof(long);
++	if (!retval)
++		retval = count;
+  out:
+ 	current->state = TASK_RUNNING;
+ 	remove_wait_queue(&rtc_wait, &wait);
+@@ -924,6 +933,9 @@
+ 	struct sparc_isa_device *isa_dev;
+ #endif
+ #endif
++#ifndef __sparc__
++	void *r;
++#endif
+ 
+ #ifdef __sparc__
+ 	for_each_ebus(ebus) {
+@@ -969,8 +981,13 @@
+ 	}
+ no_irq:
+ #else
+-	if (!request_region(RTC_PORT(0), RTC_IO_EXTENT, "rtc")) {
+-		printk(KERN_ERR "rtc: I/O port %d is not free.\n", RTC_PORT (0));
++	if (RTC_IOMAPPED)
++		r = request_region(RTC_PORT(0), RTC_IO_EXTENT, "rtc");
++	else
++		r = request_mem_region(RTC_PORT(0), RTC_IO_EXTENT, "rtc");
++	if (!r) {
++		printk(KERN_ERR "rtc: I/O resource %lx is not free.\n",
++		       (long)(RTC_PORT(0)));
+ 		return -EIO;
+ 	}
+ 
+@@ -984,7 +1001,10 @@
+ 	if(request_irq(RTC_IRQ, rtc_int_handler_ptr, SA_INTERRUPT, "rtc", NULL)) {
+ 		/* Yeah right, seeing as irq 8 doesn't even hit the bus. */
+ 		printk(KERN_ERR "rtc: IRQ %d is not free.\n", RTC_IRQ);
+-		release_region(RTC_PORT(0), RTC_IO_EXTENT);
++		if (RTC_IOMAPPED)
++			release_region(RTC_PORT(0), RTC_IO_EXTENT);
++		else
++			release_mem_region(RTC_PORT(0), RTC_IO_EXTENT);
+ 		return -EIO;
+ 	}
+ 	hpet_rtc_timer_init();
+@@ -1084,7 +1104,10 @@
+ 	if (rtc_has_irq)
+ 		free_irq (rtc_irq, &rtc_port);
+ #else
+-	release_region (RTC_PORT (0), RTC_IO_EXTENT);
++	if (RTC_IOMAPPED)
++		release_region(RTC_PORT(0), RTC_IO_EXTENT);
++	else
++		release_mem_region(RTC_PORT(0), RTC_IO_EXTENT);
+ #ifdef RTC_IRQ
+ 	if (rtc_has_irq)
+ 		free_irq (RTC_IRQ, NULL);
+

Added: dists/trunk/linux-2.6/debian/patches/mips-dec-scsi.patch
==============================================================================
--- (empty file)
+++ dists/trunk/linux-2.6/debian/patches/mips-dec-scsi.patch	Wed Jun 28 13:26:47 2006
@@ -0,0 +1,21 @@
+# Upstream status: in linux-mips tree; someone needs to figure out how to
+# integrate this into the Linux tree...
+
+From: Maciej W. Rozycki <macro at linux-mips.org>
+
+--- a/drivers/scsi/NCR53C9x.h	2006-03-05 20:35:04.000000000 +0100
++++ b/drivers/scsi/NCR53C9x.h	2006-03-05 19:51:16.000000000 +0100
+@@ -145,12 +145,7 @@
+ 
+ #ifndef MULTIPLE_PAD_SIZES
+ 
+-#ifdef CONFIG_CPU_HAS_WB
+-#include <asm/wbflush.h>
+-#define esp_write(__reg, __val) do{(__reg) = (__val); wbflush();} while(0)
+-#else
+-#define esp_write(__reg, __val) ((__reg) = (__val))
+-#endif
++#define esp_write(__reg, __val) do{(__reg) = (__val); iob();} while(0)
+ #define esp_read(__reg) (__reg)
+ 
+ struct ESP_regs {

Added: dists/trunk/linux-2.6/debian/patches/mips-dec-serial.patch
==============================================================================
--- (empty file)
+++ dists/trunk/linux-2.6/debian/patches/mips-dec-serial.patch	Wed Jun 28 13:26:47 2006
@@ -0,0 +1,135 @@
+# Upstream status: won't go into Linus' tree like this but is in the
+# linux-mips tree.  The drivers/char serial drivers need to be converted to
+# real serial drivers in drivers/serial
+
+# Author: Martin Michlmayr <tbm at cyrius.com>, mostly taken from the
+# linux-mips tree
+
+
+--- b/drivers/char/Kconfig~	2006-05-25 12:51:58.000000000 +0200
++++ b/drivers/char/Kconfig	2006-05-25 12:53:03.000000000 +0200
+@@ -362,6 +362,41 @@
+ 	bool "Console on BCM1xxx DUART"
+ 	depends on SIBYTE_SB1250_DUART
+ 
++config SERIAL_DEC
++	bool "DECstation serial support"
++	depends on MACH_DECSTATION
++	default y
++	help
++	  This selects whether you want to be asked about drivers for
++	  DECstation serial ports.
++
++	  Note that the answer to this question won't directly affect the
++	  kernel: saying N will just cause the configurator to skip all
++	  the questions about DECstation serial ports.
++
++	  If unsure, say Y.
++
++config SERIAL_DEC_CONSOLE
++	bool "Support for console on a DECstation serial port"
++	depends on SERIAL_DEC
++	default y
++	help
++	  If you say Y here, it will be possible to use a serial port as the
++	  system console (the system console is the device which receives all
++	  kernel messages and warnings and which allows logins in single user
++	  mode).  Note that the firmware uses ttyS0 as the serial console on
++	  the Maxine and ttyS2 on the others.
++
++	  If unsure, say Y.
++
++config ZS
++	bool "Z85C30 Serial Support"
++	depends on SERIAL_DEC
++	default y
++	help
++	  Documentation on the Zilog 85C350 serial communications controller
++	  is downloadable at <http://www.zilog.com/pdfs/serial/z85c30.pdf>.
++
+ config QTRONIX_KEYBOARD
+ 	bool "Enable Qtronix 990P Keyboard Support"
+ 	depends on IT8712
+--- b/drivers/char/Makefile~	2006-05-25 12:51:52.000000000 +0200
++++ b/drivers/char/Makefile	2006-05-25 12:52:27.000000000 +0200
+@@ -50,6 +50,7 @@
+ obj-$(CONFIG_VIOTAPE)		+= viotape.o
+ obj-$(CONFIG_HVCS)		+= hvcs.o
+ obj-$(CONFIG_SGI_MBCS)		+= mbcs.o
++obj-$(CONFIG_SERIAL_DEC)	+= decserial.o
+ 
+ obj-$(CONFIG_PRINTER) += lp.o
+ obj-$(CONFIG_TIPAR) += tipar.o
+--- a/drivers/char/decserial.c
++++ b/drivers/char/decserial.c
+@@ -24,17 +24,17 @@
+ extern int zs_init(void);
+ #endif
+ 
+-#ifdef CONFIG_DZ
++#ifdef CONFIG_SERIAL_DZ
+ extern int dz_init(void);
+ #endif
+ 
+-#ifdef CONFIG_SERIAL_CONSOLE
++#ifdef CONFIG_SERIAL_CORE_CONSOLE
+ 
+ #ifdef CONFIG_ZS
+ extern void zs_serial_console_init(void);
+ #endif
+ 
+-#ifdef CONFIG_DZ
++#ifdef CONFIG_SERIAL_DZ
+ extern void dz_serial_console_init(void);
+ #endif
+ 
+@@ -43,12 +43,12 @@ extern void dz_serial_console_init(void)
+ /* rs_init - starts up the serial interface -
+    handle normal case of starting up the serial interface */
+ 
+-#ifdef CONFIG_SERIAL
++#ifdef CONFIG_SERIAL_CORE
+ 
+ int __init rs_init(void)
+ {
+ 
+-#if defined(CONFIG_ZS) && defined(CONFIG_DZ)
++#if defined(CONFIG_ZS) && defined(CONFIG_SERIAL_DZ)
+     if (IOASIC)
+ 	return zs_init();
+     else
+@@ -59,7 +59,7 @@ int __init rs_init(void)
+     return zs_init();
+ #endif
+ 
+-#ifdef CONFIG_DZ
++#ifdef CONFIG_SERIAL_DZ
+     return dz_init();
+ #endif
+ 
+@@ -70,14 +70,14 @@ __initcall(rs_init);
+ 
+ #endif
+ 
+-#ifdef CONFIG_SERIAL_CONSOLE
++#ifdef CONFIG_SERIAL_CORE_CONSOLE
+ 
+ /* serial_console_init handles the special case of starting
+  *   up the console on the serial port
+  */
+ static int __init decserial_console_init(void)
+ {
+-#if defined(CONFIG_ZS) && defined(CONFIG_DZ)
++#if defined(CONFIG_ZS) && defined(CONFIG_SERIAL_DZ)
+     if (IOASIC)
+ 	zs_serial_console_init();
+     else
+@@ -88,7 +88,7 @@ static int __init decserial_console_init
+     zs_serial_console_init();
+ #endif
+ 
+-#ifdef CONFIG_DZ
++#ifdef CONFIG_SERIAL_DZ
+     dz_serial_console_init();
+ #endif
+ 

Added: dists/trunk/linux-2.6/debian/patches/series/2-extra
==============================================================================
--- (empty file)
+++ dists/trunk/linux-2.6/debian/patches/series/2-extra	Wed Jun 28 13:26:47 2006
@@ -0,0 +1,3 @@
++ mips-dec-rtc.patch mipsel
++ mips-dec-scsi.patch mipsel
++ mips-dec-serial.patch mipsel



More information about the Kernel-svn-changes mailing list