aboutsummaryrefslogtreecommitdiffstats
path: root/driver
diff options
context:
space:
mode:
authorGreg KH <greg@press.(none)>2005-10-14 17:23:05 -0700
committerGreg Kroah-Hartman <gregkh@suse.de>2005-10-14 17:23:05 -0700
commite4b0d747f3d3f5264a70c6260d4147106e8df458 (patch)
tree5221e81474a2520ae553995a371db2f8a52c25cc /driver
parent97f0358110694370d21c8e927c1106908361ddc2 (diff)
downloadpatches-e4b0d747f3d3f5264a70c6260d4147106e8df458.tar.gz
more new patches
Diffstat (limited to 'driver')
-rw-r--r--driver/driver-core-big-kfree-null-check-cleanup-documentation.patch107
-rw-r--r--driver/drivers-base-fix-sparse-warnings.patch138
2 files changed, 139 insertions, 106 deletions
diff --git a/driver/driver-core-big-kfree-null-check-cleanup-documentation.patch b/driver/driver-core-big-kfree-null-check-cleanup-documentation.patch
index 7a1eec792c86e..27d01861cb125 100644
--- a/driver/driver-core-big-kfree-null-check-cleanup-documentation.patch
+++ b/driver/driver-core-big-kfree-null-check-cleanup-documentation.patch
@@ -15,10 +15,7 @@ Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
Documentation/DocBook/writing_usb_driver.tmpl | 3 +--
- Documentation/input/yealink.txt | 25 +++++++++++++++++++------
- MAINTAINERS | 12 ++++++------
- drivers/usb/input/map_to_7segment.h | 2 +-
- 4 files changed, 27 insertions(+), 15 deletions(-)
+ 1 file changed, 1 insertion(+), 2 deletions(-)
--- gregkh-2.6.orig/Documentation/DocBook/writing_usb_driver.tmpl
+++ gregkh-2.6/Documentation/DocBook/writing_usb_driver.tmpl
@@ -32,105 +29,3 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
if (dev->bulk_out_buffer != NULL)
usb_buffer_free (dev->udev, dev->bulk_out_size,
dev->bulk_out_buffer,
---- gregkh-2.6.orig/Documentation/input/yealink.txt
-+++ gregkh-2.6/Documentation/input/yealink.txt
-@@ -2,7 +2,6 @@ Driver documentation for yealink usb-p1k
-
- 0. Status
- ~~~~~~~~~
--
- The p1k is a relatively cheap usb 1.1 phone with:
- - keyboard full support, yealink.ko / input event API
- - LCD full support, yealink.ko / sysfs API
-@@ -17,17 +16,31 @@ For vendor documentation see http://www.
-
- 1. Compilation (stand alone version)
- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
--
- Currently only kernel 2.6.x.y versions are supported.
--In order to build the yealink.ko module do:
-+In order to build the yealink.ko module do
-
- make
-
--If you encounter problems please check if in the MAKE_OPTS variable in
-+If you encounter problems please check if in the MAKE_OPTS variable in
- the Makefile is pointing to the location where your kernel sources
- are located, default /usr/src/linux.
-
-
-+1.1 Troubleshooting
-+~~~~~~~~~~~~~~~~~~~
-+Q: Module yealink compiled and installed without any problem but phone
-+ is not initialized and does not react to any actions.
-+A: If you see something like:
-+ hiddev0: USB HID v1.00 Device [Yealink Network Technology Ltd. VOIP USB Phone
-+ in dmesg, it means that the hid driver has grabbed the device first. Try to
-+ load module yealink before any other usb hid driver. Please see the
-+ instructions provided by your distribution on module configuration.
-+
-+Q: Phone is working now (displays version and accepts keypad input) but I can't
-+ find the sysfs files.
-+A: The sysfs files are located on the particular usb endpoint. On most
-+ distributions you can do: "find /sys/ -name get_icons" for a hint.
-+
-
- 2. keyboard features
- ~~~~~~~~~~~~~~~~~~~~
-@@ -134,7 +147,7 @@ Writing to /sys/../lineX will set the co
- Will update the LCD with the current date & time.
-
-
--4.2 get_icons
-+4.2 get_icons
- ~~~~~~~~~~~~~
- Reading will return all available icon names and its current settings:
-
-@@ -159,7 +172,7 @@ Reading will return all available icon n
- RINGTONE
-
-
--4.3 show/hide icons
-+4.3 show/hide icons
- ~~~~~~~~~~~~~~~~~~~
- Writing to these files will update the state of the icon.
- Only one icon at a time can be updated.
---- gregkh-2.6.orig/MAINTAINERS
-+++ gregkh-2.6/MAINTAINERS
-@@ -116,12 +116,6 @@ M: ajk@iehk.rwth-aachen.de
- L: linux-hams@vger.kernel.org
- S: Maintained
-
--YEALINK PHONE DRIVER
--P: Henk Vergonet
--M: Henk.Vergonet@gmail.com
--L: usbb2k-api-dev@nongnu.org
--S: Maintained
--
- 8139CP 10/100 FAST ETHERNET DRIVER
- P: Jeff Garzik
- M: jgarzik@pobox.com
-@@ -2854,6 +2848,12 @@ M: jpr@f6fbb.org
- L: linux-hams@vger.kernel.org
- S: Maintained
-
-+YEALINK PHONE DRIVER
-+P: Henk Vergonet
-+M: Henk.Vergonet@gmail.com
-+L: usbb2k-api-dev@nongnu.org
-+S: Maintained
-+
- YMFPCI YAMAHA PCI SOUND (Use ALSA instead)
- P: Pete Zaitcev
- M: zaitcev@yahoo.com
---- gregkh-2.6.orig/drivers/usb/input/map_to_7segment.h
-+++ gregkh-2.6/drivers/usb/input/map_to_7segment.h
-@@ -79,7 +79,7 @@ struct seg7_conversion_map {
-
- static inline int map_to_seg7(struct seg7_conversion_map *map, int c)
- {
-- return c & 0x7f ? map->table[c] : -EINVAL;
-+ return c >= 0 && c < sizeof(map->table) ? map->table[c] : -EINVAL;
- }
-
- #define SEG7_CONVERSION_MAP(_name, _map) \
diff --git a/driver/drivers-base-fix-sparse-warnings.patch b/driver/drivers-base-fix-sparse-warnings.patch
new file mode 100644
index 0000000000000..95f3404d06c49
--- /dev/null
+++ b/driver/drivers-base-fix-sparse-warnings.patch
@@ -0,0 +1,138 @@
+From ben@fluff.org.uk Thu Oct 13 10:05:58 2005
+Date: Thu, 13 Oct 2005 17:54:41 +0100
+From: Ben Dooks <ben-linux@fluff.org>
+To: linux-kernel@vger.kernel.org, gregkh@suse.de
+Subject: [PATCH] drivers/base - fix sparse warnings
+Message-ID: <20051013165441.GA18360@home.fluff.org>
+Content-Disposition: inline
+
+There are a number of sparse warnings from the latest sparse
+snapshot being generated from the drivers/base build. The
+main culprits are due to the initialisation functions not
+being declared in a header file.
+
+Also, the firmware.c file should include <linux/device.h>
+to get the prototype of firmware_register() and
+firmware_unregister().
+
+This patch moves the init function declerations from the
+init.c file to the base.h, and ensures it is included in
+all the relevant c sources. It also adds <linux/device.h>
+to the included headers for firmware.c.
+
+The patch does not solve all the sparse errors generated,
+but reduces the count significantly.
+
+drivers/base/core.c:161:1: warning: symbol 'devices_subsys' was not declared. Should it be static?
+drivers/base/core.c:417:12: warning: symbol 'devices_init' was not declared. Should it be static?
+drivers/base/sys.c:253:6: warning: symbol 'sysdev_shutdown' was not declared. Should it be static?
+drivers/base/sys.c:326:5: warning: symbol 'sysdev_suspend' was not declared. Should it be static?
+drivers/base/sys.c:428:5: warning: symbol 'sysdev_resume' was not declared. Should it be static?
+drivers/base/sys.c:450:12: warning: symbol 'system_bus_init' was not declared. Should it be static?
+drivers/base/bus.c:133:1: warning: symbol 'bus_subsys' was not declared. Should it be static?
+drivers/base/bus.c:667:12: warning: symbol 'buses_init' was not declared. Should it be static?
+drivers/base/class.c:759:12: warning: symbol 'classes_init' was not declared. Should it be static?
+drivers/base/platform.c:313:12: warning: symbol 'platform_bus_init' was not declared. Should it be static?
+drivers/base/cpu.c:110:12: warning: symbol 'cpu_dev_init' was not declared. Should it be static?
+drivers/base/firmware.c:17:5: warning: symbol 'firmware_register' was not declared. Should it be static?
+drivers/base/firmware.c:23:6: warning: symbol 'firmware_unregister' was not declared. Should it be static?
+drivers/base/firmware.c:28:12: warning: symbol 'firmware_init' was not declared. Should it be static?
+drivers/base/init.c:28:13: warning: symbol 'driver_init' was not declared. Should it be static?
+drivers/base/dmapool.c:174:10: warning: implicit cast from nocast type
+drivers/base/attribute_container.c:439:1: warning: symbol 'attribute_container_init' was not declared. Should it be static?
+drivers/base/power/runtime.c:76:6: warning: symbol 'dpm_set_power_state' was not declared. Should it be static?
+
+Signed-off-by: Ben Dooks <ben-linux@fluff.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+
+---
+ drivers/base/attribute_container.c | 2 ++
+ drivers/base/base.h | 12 ++++++++++++
+ drivers/base/cpu.c | 1 +
+ drivers/base/firmware.c | 3 +++
+ drivers/base/init.c | 10 ++--------
+ drivers/base/platform.c | 2 ++
+ 6 files changed, 22 insertions(+), 8 deletions(-)
+
+--- gregkh-2.6.orig/drivers/base/attribute_container.c
++++ gregkh-2.6/drivers/base/attribute_container.c
+@@ -19,6 +19,8 @@
+ #include <linux/list.h>
+ #include <linux/module.h>
+
++#include "base.h"
++
+ /* This is a private structure used to tie the classdev and the
+ * container .. it should never be visible outside this file */
+ struct internal_container {
+--- gregkh-2.6.orig/drivers/base/base.h
++++ gregkh-2.6/drivers/base/base.h
+@@ -1,3 +1,15 @@
++
++/* initialisation functions */
++
++extern int devices_init(void);
++extern int buses_init(void);
++extern int classes_init(void);
++extern int firmware_init(void);
++extern int platform_bus_init(void);
++extern int system_bus_init(void);
++extern int cpu_dev_init(void);
++extern int attribute_container_init(void);
++
+ extern int bus_add_device(struct device * dev);
+ extern void bus_remove_device(struct device * dev);
+
+--- gregkh-2.6.orig/drivers/base/cpu.c
++++ gregkh-2.6/drivers/base/cpu.c
+@@ -9,6 +9,7 @@
+ #include <linux/topology.h>
+ #include <linux/device.h>
+
++#include "base.h"
+
+ struct sysdev_class cpu_sysdev_class = {
+ set_kset_name("cpu"),
+--- gregkh-2.6.orig/drivers/base/firmware.c
++++ gregkh-2.6/drivers/base/firmware.c
+@@ -11,6 +11,9 @@
+ #include <linux/kobject.h>
+ #include <linux/module.h>
+ #include <linux/init.h>
++#include <linux/device.h>
++
++#include "base.h"
+
+ static decl_subsys(firmware, NULL, NULL);
+
+--- gregkh-2.6.orig/drivers/base/init.c
++++ gregkh-2.6/drivers/base/init.c
+@@ -10,14 +10,8 @@
+ #include <linux/device.h>
+ #include <linux/init.h>
+
+-extern int devices_init(void);
+-extern int buses_init(void);
+-extern int classes_init(void);
+-extern int firmware_init(void);
+-extern int platform_bus_init(void);
+-extern int system_bus_init(void);
+-extern int cpu_dev_init(void);
+-extern int attribute_container_init(void);
++#include "base.h"
++
+ /**
+ * driver_init - initialize driver model.
+ *
+--- gregkh-2.6.orig/drivers/base/platform.c
++++ gregkh-2.6/drivers/base/platform.c
+@@ -17,6 +17,8 @@
+ #include <linux/bootmem.h>
+ #include <linux/err.h>
+
++#include "base.h"
++
+ struct device platform_bus = {
+ .bus_id = "platform",
+ };