aboutsummaryrefslogtreecommitdiffstats
diff options
authorGreg Kroah-Hartman <gregkh@suse.de>2009-11-04 15:16:19 -0800
committerGreg Kroah-Hartman <gregkh@suse.de>2009-11-04 15:16:19 -0800
commit39874450fa07821078746db7b99cc931ca9478cc (patch)
treeb12c6ab1c6fc5f24ea88e96d672736fd28aa3cd2
parent9eec869b2703574cc62bb452ed9a84732195698b (diff)
downloadpatches-39874450fa07821078746db7b99cc931ca9478cc.tar.gz
sync with .32-rc6
-rw-r--r--driver-core.current/documentation-abi-document-sys-devices-system-cpu.patch39
-rw-r--r--driver-core.current/documentation-abi-rename-sysfs-devices-cache_disable-properly.patch65
-rw-r--r--driver-core.current/documentation-abi-sys-devices-system-cpu-cpu-node.patch43
-rw-r--r--driver-core.current/documentation-abi-sys-devices-system-cpu-cpu-topology-files.patch178
-rw-r--r--driver-core.current/documentation-abi-sys-devices-system-cpu-cpuidle.patch50
-rw-r--r--driver-core.current/documentation-abi-sys-devices-system-cpu-sched__power_savings.patch54
-rw-r--r--driver-core.current/documentation-abi-sys-devices-system-cpu-topology-files.patch67
-rw-r--r--driver-core.current/driver-core-allow-certain-drivers-prohibit-bind-unbind-via-sysfs.patch97
-rw-r--r--driver-core.current/driver-core-fix-driver_register-return-value.patch35
-rw-r--r--driver-core/driver-core-devtmpfs-set-root-directory-mode-to-0755.patch29
-rw-r--r--series32
-rw-r--r--staging.current/staging-android-mark-subsystem-as-broken.patch25
-rw-r--r--staging.current/staging-fix-wireless-drivers-depends.patch53
-rw-r--r--staging.current/staging-hv-fix-null-pointer-error-after-vmbus-loading.patch52
-rw-r--r--staging.current/staging-hv-fix-oops-in-vmbus-missing-include.patch41
-rw-r--r--staging.current/staging-hv-fix-oops-in-vmbus-netvsc-list_head.patch61
-rw-r--r--staging.current/staging-hv-fix-oops-in-vmbus-udev-events.patch66
-rw-r--r--staging.current/staging-hv-fix-vmbus-load-hang-caused-by-faulty-data-packing.patch31
-rw-r--r--staging.current/staging-hv-todo-patches.patch39
-rw-r--r--staging.current/staging-panel-prevent-driver-from-calling-misc_deregister-twice-on-same-ressource.patch72
-rw-r--r--staging.current/staging-remove-stlc45xx-driver.patch3380
-rw-r--r--staging.current/staging-rtl8187se-rtl8192e-rtl8192su-allow-module-unload.patch420
-rw-r--r--staging.current/staging-vt6656-fix-the-memory-free-bug-in-vntwusb_disconnect.patch119
-rw-r--r--staging.current/staging-wireless-drivers-kconfig-change.patch79
-rw-r--r--tty.current/tty-mark-generic_serial-users-as-broken.patch78
-rw-r--r--usb.current/usb-fsl_udc_core-fix-kernel-oops-on-module-removal.patch53
-rw-r--r--usb.current/usb-option-tlaytech-tue800-support.patch40
-rw-r--r--usb.current/usb-r8a66597-hcd-fix-cannot-detect-a-device-when-uses_new_polling-is-set.patch57
-rw-r--r--usb.current/usb-rndis_host-debug-info-clobbered-before-it-is-logged.patch42
-rw-r--r--usb.current/usb-serial-sierra-driver-autopm-fixes.patch85
-rw-r--r--usb.current/usb-serial-sierra-driver-send_setup-autopm-fix.patch82
-rw-r--r--version2
32 files changed, 32 insertions, 5534 deletions
diff --git a/driver-core.current/documentation-abi-document-sys-devices-system-cpu.patch b/driver-core.current/documentation-abi-document-sys-devices-system-cpu.patch
deleted file mode 100644
index d247eb7643115b..00000000000000
--- a/driver-core.current/documentation-abi-document-sys-devices-system-cpu.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From achiang@hp.com Tue Oct 27 11:25:08 2009
-From: Alex Chiang <achiang@hp.com>
-Date: Wed, 21 Oct 2009 21:45:20 -0600
-Subject: Documentation: ABI: document /sys/devices/system/cpu/
-To: randy.dunlap@oracle.com, greg@kroah.com
-Cc: akpm@linux-foundation.org, linux-kernel@vger.kernel.org, rientjes@google.com
-Message-ID: <20091022034520.13399.23985.stgit@bob.kio>
-
-
-This interface has been around for a long time, but hasn't been
-officially documented.
-
-Document the top level sysfs directory for CPU attributes.
-
-Signed-off-by: Alex Chiang <achiang@hp.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- Documentation/ABI/testing/sysfs-devices-system-cpu | 12 ++++++++++++
- 1 file changed, 12 insertions(+)
-
---- a/Documentation/ABI/testing/sysfs-devices-system-cpu
-+++ b/Documentation/ABI/testing/sysfs-devices-system-cpu
-@@ -1,3 +1,15 @@
-+What: /sys/devices/system/cpu/
-+Date: pre-git history
-+Contact: Linux kernel mailing list <linux-kernel@vger.kernel.org>
-+Description:
-+ A collection of both global and individual CPU attributes
-+
-+ Individual CPU attributes are contained in subdirectories
-+ named by the kernel's logical CPU number, e.g.:
-+
-+ /sys/devices/system/cpu/cpu#/
-+
-+
- What: /sys/devices/system/cpu/cpu*/cache/index*/cache_disable_X
- Date: August 2008
- KernelVersion: 2.6.27
diff --git a/driver-core.current/documentation-abi-rename-sysfs-devices-cache_disable-properly.patch b/driver-core.current/documentation-abi-rename-sysfs-devices-cache_disable-properly.patch
deleted file mode 100644
index 1357c46bef3f46..00000000000000
--- a/driver-core.current/documentation-abi-rename-sysfs-devices-cache_disable-properly.patch
+++ /dev/null
@@ -1,65 +0,0 @@
-From achiang@hp.com Tue Oct 27 11:24:45 2009
-From: Alex Chiang <achiang@hp.com>
-Date: Wed, 21 Oct 2009 21:45:15 -0600
-Subject: Documentation: ABI: rename sysfs-devices-cache_disable properly
-To: randy.dunlap@oracle.com, greg@kroah.com
-Cc: akpm@linux-foundation.org, linux-kernel@vger.kernel.org, David Rientjes <rientjes@google.com>
-Message-ID: <20091022034515.13399.39630.stgit@bob.kio>
-
-
-Rename sysfs-devices-cache_disable to sysfs-devices-system-cpu, in
-order to keep a stricter correlation between a sysfs directory and
-its documentation.
-
-Reported-by: David Rientjes <rientjes@google.com>
-Signed-off-by: Alex Chiang <achiang@hp.com>
-Acked-by: David Rientjes <rientjes@google.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- Documentation/ABI/testing/sysfs-devices-cache_disable | 18 ------------------
- Documentation/ABI/testing/sysfs-devices-system-cpu | 18 ++++++++++++++++++
- 2 files changed, 18 insertions(+), 18 deletions(-)
-
---- a/Documentation/ABI/testing/sysfs-devices-cache_disable
-+++ /dev/null
-@@ -1,18 +0,0 @@
--What: /sys/devices/system/cpu/cpu*/cache/index*/cache_disable_X
--Date: August 2008
--KernelVersion: 2.6.27
--Contact: mark.langsdorf@amd.com
--Description: These files exist in every cpu's cache index directories.
-- There are currently 2 cache_disable_# files in each
-- directory. Reading from these files on a supported
-- processor will return that cache disable index value
-- for that processor and node. Writing to one of these
-- files will cause the specificed cache index to be disabled.
--
-- Currently, only AMD Family 10h Processors support cache index
-- disable, and only for their L3 caches. See the BIOS and
-- Kernel Developer's Guide at
-- http://www.amd.com/us-en/assets/content_type/white_papers_and_tech_docs/31116-Public-GH-BKDG_3.20_2-4-09.pdf
-- for formatting information and other details on the
-- cache index disable.
--Users: joachim.deguara@amd.com
---- /dev/null
-+++ b/Documentation/ABI/testing/sysfs-devices-system-cpu
-@@ -0,0 +1,18 @@
-+What: /sys/devices/system/cpu/cpu*/cache/index*/cache_disable_X
-+Date: August 2008
-+KernelVersion: 2.6.27
-+Contact: mark.langsdorf@amd.com
-+Description: These files exist in every cpu's cache index directories.
-+ There are currently 2 cache_disable_# files in each
-+ directory. Reading from these files on a supported
-+ processor will return that cache disable index value
-+ for that processor and node. Writing to one of these
-+ files will cause the specificed cache index to be disabled.
-+
-+ Currently, only AMD Family 10h Processors support cache index
-+ disable, and only for their L3 caches. See the BIOS and
-+ Kernel Developer's Guide at
-+ http://www.amd.com/us-en/assets/content_type/white_papers_and_tech_docs/31116-Public-GH-BKDG_3.20_2-4-09.pdf
-+ for formatting information and other details on the
-+ cache index disable.
-+Users: joachim.deguara@amd.com
diff --git a/driver-core.current/documentation-abi-sys-devices-system-cpu-cpu-node.patch b/driver-core.current/documentation-abi-sys-devices-system-cpu-cpu-node.patch
deleted file mode 100644
index 26e24d6da09d55..00000000000000
--- a/driver-core.current/documentation-abi-sys-devices-system-cpu-cpu-node.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From achiang@hp.com Tue Oct 27 11:26:41 2009
-From: Alex Chiang <achiang@hp.com>
-Date: Wed, 21 Oct 2009 22:15:30 -0600
-Subject: Documentation: ABI: /sys/devices/system/cpu/cpu#/node
-To: akpm@linux-foundation.org
-Cc: Randy Dunlap <randy.dunlap@oracle.com>, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Greg KH <greg@kroah.com>
-Message-ID: <20091022041530.15705.29051.stgit@bob.kio>
-
-
-Describe NUMA node symlink created for CPUs when CONFIG_NUMA is set.
-
-Cc: Randy Dunlap <randy.dunlap@oracle.com>
-Signed-off-by: Alex Chiang <achiang@hp.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- Documentation/ABI/testing/sysfs-devices-system-cpu | 15 +++++++++++++++
- 1 file changed, 15 insertions(+)
-
---- a/Documentation/ABI/testing/sysfs-devices-system-cpu
-+++ b/Documentation/ABI/testing/sysfs-devices-system-cpu
-@@ -62,6 +62,21 @@ Description: CPU topology files that des
- See Documentation/cputopology.txt for more information.
-
-
-+
-+What: /sys/devices/system/cpu/cpu#/node
-+Date: October 2009
-+Contact: Linux memory management mailing list <linux-mm@kvack.org>
-+Description: Discover NUMA node a CPU belongs to
-+
-+ When CONFIG_NUMA is enabled, a symbolic link that points
-+ to the corresponding NUMA node directory.
-+
-+ For example, the following symlink is created for cpu42
-+ in NUMA node 2:
-+
-+ /sys/devices/system/cpu/cpu42/node2 -> ../../node/node2
-+
-+
- What: /sys/devices/system/cpu/cpu#/topology/core_id
- /sys/devices/system/cpu/cpu#/topology/core_siblings
- /sys/devices/system/cpu/cpu#/topology/core_siblings_list
diff --git a/driver-core.current/documentation-abi-sys-devices-system-cpu-cpu-topology-files.patch b/driver-core.current/documentation-abi-sys-devices-system-cpu-cpu-topology-files.patch
deleted file mode 100644
index 05130e438ae9ca..00000000000000
--- a/driver-core.current/documentation-abi-sys-devices-system-cpu-cpu-topology-files.patch
+++ /dev/null
@@ -1,178 +0,0 @@
-From achiang@hp.com Tue Oct 27 11:25:38 2009
-From: Alex Chiang <achiang@hp.com>
-Date: Wed, 21 Oct 2009 21:45:31 -0600
-Subject: Documentation: ABI: /sys/devices/system/cpu/cpu#/ topology files
-To: randy.dunlap@oracle.com, greg@kroah.com
-Cc: akpm@linux-foundation.org, Mike Travis <travis@sgi.com>, linux-kernel@vger.kernel.org, Rusty Russell <rusty@rustcorp.com.au>, rientjes@google.com
-Message-ID: <20091022034530.13399.65380.stgit@bob.kio>
-
-
-Add brief descriptions for the following sysfs files:
-
- /sys/devices/system/cpu/cpu#/topology/core_id
- /sys/devices/system/cpu/cpu#/topology/core_siblings
- /sys/devices/system/cpu/cpu#/topology/core_siblings_list
- /sys/devices/system/cpu/cpu#/topology/physical_package_id
- /sys/devices/system/cpu/cpu#/topology/thread_siblings
- /sys/devices/system/cpu/cpu#/topology/thread_siblings_list
-
-The descriptions in Documentation/cputopology.txt weren't very
-informative, so I attempted a better description based on code
-reading and hopeful guessing.
-
-Updated Documentation/cputopology.txt with the better descriptions and
-fixed some style issues.
-
-Cc: Mike Travis <travis@sgi.com>
-Cc: Rusty Russell <rusty@rustcorp.com.au>
-Signed-off-by: Alex Chiang <achiang@hp.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- Documentation/ABI/testing/sysfs-devices-system-cpu | 39 +++++++++++++++++
- Documentation/cputopology.txt | 47 +++++++++++++--------
- 2 files changed, 69 insertions(+), 17 deletions(-)
-
---- a/Documentation/ABI/testing/sysfs-devices-system-cpu
-+++ b/Documentation/ABI/testing/sysfs-devices-system-cpu
-@@ -38,6 +38,45 @@ Description: CPU topology files that des
- See Documentation/cputopology.txt for more information.
-
-
-+What: /sys/devices/system/cpu/cpu#/topology/core_id
-+ /sys/devices/system/cpu/cpu#/topology/core_siblings
-+ /sys/devices/system/cpu/cpu#/topology/core_siblings_list
-+ /sys/devices/system/cpu/cpu#/topology/physical_package_id
-+ /sys/devices/system/cpu/cpu#/topology/thread_siblings
-+ /sys/devices/system/cpu/cpu#/topology/thread_siblings_list
-+Date: December 2008
-+Contact: Linux kernel mailing list <linux-kernel@vger.kernel.org>
-+Description: CPU topology files that describe a logical CPU's relationship
-+ to other cores and threads in the same physical package.
-+
-+ One cpu# directory is created per logical CPU in the system,
-+ e.g. /sys/devices/system/cpu/cpu42/.
-+
-+ Briefly, the files above are:
-+
-+ core_id: the CPU core ID of cpu#. Typically it is the
-+ hardware platform's identifier (rather than the kernel's).
-+ The actual value is architecture and platform dependent.
-+
-+ core_siblings: internal kernel map of cpu#'s hardware threads
-+ within the same physical_package_id.
-+
-+ core_siblings_list: human-readable list of the logical CPU
-+ numbers within the same physical_package_id as cpu#.
-+
-+ physical_package_id: physical package id of cpu#. Typically
-+ corresponds to a physical socket number, but the actual value
-+ is architecture and platform dependent.
-+
-+ thread_siblings: internel kernel map of cpu#'s hardware
-+ threads within the same core as cpu#
-+
-+ thread_siblings_list: human-readable list of cpu#'s hardware
-+ threads within the same core as cpu#
-+
-+ See Documentation/cputopology.txt for more information.
-+
-+
- What: /sys/devices/system/cpu/cpu*/cache/index*/cache_disable_X
- Date: August 2008
- KernelVersion: 2.6.27
---- a/Documentation/cputopology.txt
-+++ b/Documentation/cputopology.txt
-@@ -1,15 +1,28 @@
-
--Export cpu topology info via sysfs. Items (attributes) are similar
-+Export CPU topology info via sysfs. Items (attributes) are similar
- to /proc/cpuinfo.
-
- 1) /sys/devices/system/cpu/cpuX/topology/physical_package_id:
--represent the physical package id of cpu X;
-+
-+ physical package id of cpuX. Typically corresponds to a physical
-+ socket number, but the actual value is architecture and platform
-+ dependent.
-+
- 2) /sys/devices/system/cpu/cpuX/topology/core_id:
--represent the cpu core id to cpu X;
-+
-+ the CPU core ID of cpuX. Typically it is the hardware platform's
-+ identifier (rather than the kernel's). The actual value is
-+ architecture and platform dependent.
-+
- 3) /sys/devices/system/cpu/cpuX/topology/thread_siblings:
--represent the thread siblings to cpu X in the same core;
-+
-+ internel kernel map of cpuX's hardware threads within the same
-+ core as cpuX
-+
- 4) /sys/devices/system/cpu/cpuX/topology/core_siblings:
--represent the thread siblings to cpu X in the same physical package;
-+
-+ internal kernel map of cpuX's hardware threads within the same
-+ physical_package_id.
-
- To implement it in an architecture-neutral way, a new source file,
- drivers/base/topology.c, is to export the 4 attributes.
-@@ -32,32 +45,32 @@ not defined by include/asm-XXX/topology.
- 3) thread_siblings: just the given CPU
- 4) core_siblings: just the given CPU
-
--Additionally, cpu topology information is provided under
-+Additionally, CPU topology information is provided under
- /sys/devices/system/cpu and includes these files. The internal
- source for the output is in brackets ("[]").
-
-- kernel_max: the maximum cpu index allowed by the kernel configuration.
-+ kernel_max: the maximum CPU index allowed by the kernel configuration.
- [NR_CPUS-1]
-
-- offline: cpus that are not online because they have been
-+ offline: CPUs that are not online because they have been
- HOTPLUGGED off (see cpu-hotplug.txt) or exceed the limit
-- of cpus allowed by the kernel configuration (kernel_max
-+ of CPUs allowed by the kernel configuration (kernel_max
- above). [~cpu_online_mask + cpus >= NR_CPUS]
-
-- online: cpus that are online and being scheduled [cpu_online_mask]
-+ online: CPUs that are online and being scheduled [cpu_online_mask]
-
-- possible: cpus that have been allocated resources and can be
-+ possible: CPUs that have been allocated resources and can be
- brought online if they are present. [cpu_possible_mask]
-
-- present: cpus that have been identified as being present in the
-+ present: CPUs that have been identified as being present in the
- system. [cpu_present_mask]
-
- The format for the above output is compatible with cpulist_parse()
- [see <linux/cpumask.h>]. Some examples follow.
-
--In this example, there are 64 cpus in the system but cpus 32-63 exceed
-+In this example, there are 64 CPUs in the system but cpus 32-63 exceed
- the kernel max which is limited to 0..31 by the NR_CPUS config option
--being 32. Note also that cpus 2 and 4-31 are not online but could be
-+being 32. Note also that CPUs 2 and 4-31 are not online but could be
- brought online as they are both present and possible.
-
- kernel_max: 31
-@@ -67,8 +80,8 @@ brought online as they are both present
- present: 0-31
-
- In this example, the NR_CPUS config option is 128, but the kernel was
--started with possible_cpus=144. There are 4 cpus in the system and cpu2
--was manually taken offline (and is the only cpu that can be brought
-+started with possible_cpus=144. There are 4 CPUs in the system and cpu2
-+was manually taken offline (and is the only CPU that can be brought
- online.)
-
- kernel_max: 127
-@@ -78,4 +91,4 @@ online.)
- present: 0-3
-
- See cpu-hotplug.txt for the possible_cpus=NUM kernel start parameter
--as well as more information on the various cpumask's.
-+as well as more information on the various cpumasks.
diff --git a/driver-core.current/documentation-abi-sys-devices-system-cpu-cpuidle.patch b/driver-core.current/documentation-abi-sys-devices-system-cpu-cpuidle.patch
deleted file mode 100644
index 16851fdf26d351..00000000000000
--- a/driver-core.current/documentation-abi-sys-devices-system-cpu-cpuidle.patch
+++ /dev/null
@@ -1,50 +0,0 @@
-From achiang@hp.com Tue Oct 27 11:26:00 2009
-From: Alex Chiang <achiang@hp.com>
-Date: Wed, 21 Oct 2009 21:45:41 -0600
-Subject: Documentation: ABI: /sys/devices/system/cpu/cpuidle/
-To: randy.dunlap@oracle.com, greg@kroah.com
-Cc: akpm@linux-foundation.org, Venki Pallipadi <venkatesh.pallipadi@intel.com>, linux-kernel@vger.kernel.org, Len Brown <lenb@kernel.org>, rientjes@google.com
-Message-ID: <20091022034541.13399.59424.stgit@bob.kio>
-
-
-Document cpuidle sysfs attributes by reading code, Documentation/cpuidle/,
-and git logs.
-
-Cc: Venki Pallipadi <venkatesh.pallipadi@intel.com>
-Cc: Len Brown <lenb@kernel.org>
-Signed-off-by: Alex Chiang <achiang@hp.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- Documentation/ABI/testing/sysfs-devices-system-cpu | 20 ++++++++++++++++++++
- 1 file changed, 20 insertions(+)
-
---- a/Documentation/ABI/testing/sysfs-devices-system-cpu
-+++ b/Documentation/ABI/testing/sysfs-devices-system-cpu
-@@ -101,6 +101,26 @@ Description: CPU topology files that des
- See Documentation/cputopology.txt for more information.
-
-
-+What: /sys/devices/system/cpu/cpuidle/current_driver
-+ /sys/devices/system/cpu/cpuidle/current_governer_ro
-+Date: September 2007
-+Contact: Linux kernel mailing list <linux-kernel@vger.kernel.org>
-+Description: Discover cpuidle policy and mechanism
-+
-+ Various CPUs today support multiple idle levels that are
-+ differentiated by varying exit latencies and power
-+ consumption during idle.
-+
-+ Idle policy (governor) is differentiated from idle mechanism
-+ (driver)
-+
-+ current_driver: displays current idle mechanism
-+
-+ current_governor_ro: displays current idle policy
-+
-+ See files in Documentation/cpuidle/ for more information.
-+
-+
- What: /sys/devices/system/cpu/cpu*/cache/index*/cache_disable_X
- Date: August 2008
- KernelVersion: 2.6.27
diff --git a/driver-core.current/documentation-abi-sys-devices-system-cpu-sched__power_savings.patch b/driver-core.current/documentation-abi-sys-devices-system-cpu-sched__power_savings.patch
deleted file mode 100644
index 6c7d219f70436d..00000000000000
--- a/driver-core.current/documentation-abi-sys-devices-system-cpu-sched__power_savings.patch
+++ /dev/null
@@ -1,54 +0,0 @@
-From achiang@hp.com Tue Oct 27 11:25:50 2009
-From: Alex Chiang <achiang@hp.com>
-Date: Wed, 21 Oct 2009 21:45:36 -0600
-Subject: Documentation: ABI: /sys/devices/system/cpu/sched_[mc|smt]_power_savings
-To: randy.dunlap@oracle.com, greg@kroah.com
-Cc: Suresh Siddha <suresh.b.siddha@intel.com>, akpm@linux-foundation.org, Ingo Molnar <mingo@elte.hu>, linux-kernel@vger.kernel.org, rientjes@google.com
-Message-ID: <20091022034536.13399.98197.stgit@bob.kio>
-
-
-Document sched_[mc|smt]_power_savings by reading existing code and
-git logs.
-
-Cc: Suresh Siddha <suresh.b.siddha@intel.com>
-Cc: Ingo Molnar <mingo@elte.hu>
-Signed-off-by: Alex Chiang <achiang@hp.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- Documentation/ABI/testing/sysfs-devices-system-cpu | 24 +++++++++++++++++++++
- 1 file changed, 24 insertions(+)
-
---- a/Documentation/ABI/testing/sysfs-devices-system-cpu
-+++ b/Documentation/ABI/testing/sysfs-devices-system-cpu
-@@ -9,6 +9,30 @@ Description:
-
- /sys/devices/system/cpu/cpu#/
-
-+What: /sys/devices/system/cpu/sched_mc_power_savings
-+ /sys/devices/system/cpu/sched_smt_power_savings
-+Date: June 2006
-+Contact: Linux kernel mailing list <linux-kernel@vger.kernel.org>
-+Description: Discover and adjust the kernel's multi-core scheduler support.
-+
-+ Possible values are:
-+
-+ 0 - No power saving load balance (default value)
-+ 1 - Fill one thread/core/package first for long running threads
-+ 2 - Also bias task wakeups to semi-idle cpu package for power
-+ savings
-+
-+ sched_mc_power_savings is dependent upon SCHED_MC, which is
-+ itself architecture dependent.
-+
-+ sched_smt_power_savings is dependent upon SCHED_SMT, which
-+ is itself architecture dependent.
-+
-+ The two files are independent of each other. It is possible
-+ that one file may be present without the other.
-+
-+ Introduced by git commit 5c45bf27.
-+
-
- What: /sys/devices/system/cpu/kernel_max
- /sys/devices/system/cpu/offline
diff --git a/driver-core.current/documentation-abi-sys-devices-system-cpu-topology-files.patch b/driver-core.current/documentation-abi-sys-devices-system-cpu-topology-files.patch
deleted file mode 100644
index f20df8d775c33e..00000000000000
--- a/driver-core.current/documentation-abi-sys-devices-system-cpu-topology-files.patch
+++ /dev/null
@@ -1,67 +0,0 @@
-From achiang@hp.com Tue Oct 27 11:25:22 2009
-From: Alex Chiang <achiang@hp.com>
-Date: Wed, 21 Oct 2009 21:45:25 -0600
-Subject: Documentation: ABI: /sys/devices/system/cpu/ topology files
-To: randy.dunlap@oracle.com, greg@kroah.com
-Cc: akpm@linux-foundation.org, Mike Travis <travis@sgi.com>, linux-kernel@vger.kernel.org, Rusty Russell <rusty@rustcorp.com.au>, rientjes@google.com
-Message-ID: <20091022034525.13399.4286.stgit@bob.kio>
-
-
-Add brief descriptions for the following sysfs files:
-
- /sys/devices/system/cpu/kernel_max
- /sys/devices/system/cpu/offline
- /sys/devices/system/cpu/online
- /sys/devices/system/cpu/possible
- /sys/devices/system/cpu/present
-
-Excerpted the relevant information from Documentation/cputopology.txt
-and pointed back to cputopology.txt as the authoritative source of
-information.
-
-Cc: Mike Travis <travis@sgi.com>
-Cc: Rusty Russell <rusty@rustcorp.com.au>
-Signed-off-by: Alex Chiang <achiang@hp.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- Documentation/ABI/testing/sysfs-devices-system-cpu | 28 +++++++++++++++++++++
- 1 file changed, 28 insertions(+)
-
---- a/Documentation/ABI/testing/sysfs-devices-system-cpu
-+++ b/Documentation/ABI/testing/sysfs-devices-system-cpu
-@@ -10,6 +10,34 @@ Description:
- /sys/devices/system/cpu/cpu#/
-
-
-+What: /sys/devices/system/cpu/kernel_max
-+ /sys/devices/system/cpu/offline
-+ /sys/devices/system/cpu/online
-+ /sys/devices/system/cpu/possible
-+ /sys/devices/system/cpu/present
-+Date: December 2008
-+Contact: Linux kernel mailing list <linux-kernel@vger.kernel.org>
-+Description: CPU topology files that describe kernel limits related to
-+ hotplug. Briefly:
-+
-+ kernel_max: the maximum cpu index allowed by the kernel
-+ configuration.
-+
-+ offline: cpus that are not online because they have been
-+ HOTPLUGGED off or exceed the limit of cpus allowed by the
-+ kernel configuration (kernel_max above).
-+
-+ online: cpus that are online and being scheduled.
-+
-+ possible: cpus that have been allocated resources and can be
-+ brought online if they are present.
-+
-+ present: cpus that have been identified as being present in
-+ the system.
-+
-+ See Documentation/cputopology.txt for more information.
-+
-+
- What: /sys/devices/system/cpu/cpu*/cache/index*/cache_disable_X
- Date: August 2008
- KernelVersion: 2.6.27
diff --git a/driver-core.current/driver-core-allow-certain-drivers-prohibit-bind-unbind-via-sysfs.patch b/driver-core.current/driver-core-allow-certain-drivers-prohibit-bind-unbind-via-sysfs.patch
deleted file mode 100644
index fe88cddb75a63b..00000000000000
--- a/driver-core.current/driver-core-allow-certain-drivers-prohibit-bind-unbind-via-sysfs.patch
+++ /dev/null
@@ -1,97 +0,0 @@
-From dmitry.torokhov@gmail.com Mon Oct 26 16:01:05 2009
-From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-Date: Mon, 12 Oct 2009 20:17:41 -0700
-Subject: Driver core: allow certain drivers prohibit bind/unbind via sysfs
-To: Greg KH <gregkh@suse.de>
-Cc: �ric Piel <eric.piel@tremplin-utc.net>
-Message-ID: <20091013031741.GB2887@core.coreip.homeip.net>
-Content-Disposition: inline
-
-
-From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
-Platform drivers registered via platform_driver_probe() can be bound
-to devices only once, upon registration, because discard their probe()
-routines to save memory. Unbinding the driver through sysfs 'unbind'
-leaves the device stranded and confuses users so let's not create
-bind and unbind attributes for such drivers.
-
-Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
-Cc: �ric Piel <eric.piel@tremplin-utc.net>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/base/bus.c | 17 +++++++++++------
- drivers/base/platform.c | 6 +++++-
- include/linux/device.h | 4 +++-
- 3 files changed, 19 insertions(+), 8 deletions(-)
-
---- a/drivers/base/bus.c
-+++ b/drivers/base/bus.c
-@@ -689,15 +689,19 @@ int bus_add_driver(struct device_driver
- printk(KERN_ERR "%s: driver_add_attrs(%s) failed\n",
- __func__, drv->name);
- }
-- error = add_bind_files(drv);
-- if (error) {
-- /* Ditto */
-- printk(KERN_ERR "%s: add_bind_files(%s) failed\n",
-- __func__, drv->name);
-+
-+ if (!drv->suppress_bind_attrs) {
-+ error = add_bind_files(drv);
-+ if (error) {
-+ /* Ditto */
-+ printk(KERN_ERR "%s: add_bind_files(%s) failed\n",
-+ __func__, drv->name);
-+ }
- }
-
- kobject_uevent(&priv->kobj, KOBJ_ADD);
- return 0;
-+
- out_unregister:
- kfree(drv->p);
- drv->p = NULL;
-@@ -720,7 +724,8 @@ void bus_remove_driver(struct device_dri
- if (!drv->bus)
- return;
-
-- remove_bind_files(drv);
-+ if (!drv->suppress_bind_attrs)
-+ remove_bind_files(drv);
- driver_remove_attrs(drv->bus, drv);
- driver_remove_file(drv, &driver_attr_uevent);
- klist_remove(&drv->p->knode_bus);
---- a/drivers/base/platform.c
-+++ b/drivers/base/platform.c
-@@ -521,11 +521,15 @@ int __init_or_module platform_driver_pro
- {
- int retval, code;
-
-+ /* make sure driver won't have bind/unbind attributes */
-+ drv->driver.suppress_bind_attrs = true;
-+
- /* temporary section violation during probe() */
- drv->probe = probe;
- retval = code = platform_driver_register(drv);
-
-- /* Fixup that section violation, being paranoid about code scanning
-+ /*
-+ * Fixup that section violation, being paranoid about code scanning
- * the list of drivers in order to probe new devices. Check to see
- * if the probe was successful, and make sure any forced probes of
- * new devices fail.
---- a/include/linux/device.h
-+++ b/include/linux/device.h
-@@ -124,7 +124,9 @@ struct device_driver {
- struct bus_type *bus;
-
- struct module *owner;
-- const char *mod_name; /* used for built-in modules */
-+ const char *mod_name; /* used for built-in modules */
-+
-+ bool suppress_bind_attrs; /* disables bind/unbind via sysfs */
-
- int (*probe) (struct device *dev);
- int (*remove) (struct device *dev);
diff --git a/driver-core.current/driver-core-fix-driver_register-return-value.patch b/driver-core.current/driver-core-fix-driver_register-return-value.patch
deleted file mode 100644
index 19616583d0c56a..00000000000000
--- a/driver-core.current/driver-core-fix-driver_register-return-value.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From stsp@aknet.ru Mon Oct 26 16:00:03 2009
-From: Stas Sergeev <stsp@aknet.ru>
-Date: Sun, 18 Oct 2009 00:31:38 +0400
-Subject: Driver core: fix driver_register() return value
-To: Greg KH <gregkh@suse.de>
-Cc: Linux kernel <linux-kernel@vger.kernel.org>
-Message-ID: <4ADA29AA.9070907@aknet.ru>
-
-In this patch:
-http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=16dc42e018c2868211b4928f20a957c0c216126c
-the check was added for another driver to already claim the same device
-on the same bus. But the returned error code was wrong: to modprobe, the
--EEXIST means that _this_ driver is already installed. It therefore
-doesn't produce the needed error message when _another_ driver is trying
-to register for the same device. Returning -EBUSY fixes the problem.
-
-Signed-off-by: Stas Sergeev <stsp@aknet.ru>
-Cc: stable <stable@kernel.org>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/base/driver.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
---- a/drivers/base/driver.c
-+++ b/drivers/base/driver.c
-@@ -236,7 +236,7 @@ int driver_register(struct device_driver
- put_driver(other);
- printk(KERN_ERR "Error: Driver '%s' is already registered, "
- "aborting...\n", drv->name);
-- return -EEXIST;
-+ return -EBUSY;
- }
-
- ret = bus_add_driver(drv);
diff --git a/driver-core/driver-core-devtmpfs-set-root-directory-mode-to-0755.patch b/driver-core/driver-core-devtmpfs-set-root-directory-mode-to-0755.patch
new file mode 100644
index 00000000000000..0d86cd68e869a2
--- /dev/null
+++ b/driver-core/driver-core-devtmpfs-set-root-directory-mode-to-0755.patch
@@ -0,0 +1,29 @@
+From kay.sievers@vrfy.org Mon Nov 2 12:59:49 2009
+From: Kay Sievers <kay.sievers@vrfy.org>
+Date: Fri, 30 Oct 2009 12:48:32 +0100
+Subject: Driver-Core: devtmpfs - set root directory mode to 0755
+To: Mark Rosenstand <rosenstand@gmail.com>
+Cc: Greg KH <greg@kroah.com>
+Message-ID: <1256903312.18012.4.camel@yio.site>
+
+From: Kay Sievers <kay.sievers@vrfy.org>
+
+Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
+Cc: Mark Rosenstand <rosenstand@gmail.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/base/devtmpfs.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/base/devtmpfs.c
++++ b/drivers/base/devtmpfs.c
+@@ -359,7 +359,7 @@ int __init devtmpfs_init(void)
+ return err;
+ }
+
+- mnt = kern_mount(&dev_fs_type);
++ mnt = kern_mount_data(&dev_fs_type, "mode=0755");
+ if (IS_ERR(mnt)) {
+ err = PTR_ERR(mnt);
+ printk(KERN_ERR "devtmpfs: unable to create devtmpfs %i\n", err);
diff --git a/series b/series
index 2be9f35274e1f8..bfd2c8b107e6b9 100644
--- a/series
+++ b/series
@@ -9,48 +9,19 @@ gregkh/gkh-version.patch
#################################
# Driver core patches for 2.6.32
#################################
-driver-core.current/driver-core-fix-driver_register-return-value.patch
-driver-core.current/driver-core-allow-certain-drivers-prohibit-bind-unbind-via-sysfs.patch
-driver-core.current/documentation-abi-rename-sysfs-devices-cache_disable-properly.patch
-driver-core.current/documentation-abi-document-sys-devices-system-cpu.patch
-driver-core.current/documentation-abi-sys-devices-system-cpu-topology-files.patch
-driver-core.current/documentation-abi-sys-devices-system-cpu-cpu-topology-files.patch
-driver-core.current/documentation-abi-sys-devices-system-cpu-sched__power_savings.patch
-driver-core.current/documentation-abi-sys-devices-system-cpu-cpuidle.patch
-driver-core.current/documentation-abi-sys-devices-system-cpu-cpu-node.patch
#################################
# TTY patches for 2.6.32
#################################
-tty.current/tty-mark-generic_serial-users-as-broken.patch
#################################
# USB patches for 2.6.32
#################################
-usb.current/usb-rndis_host-debug-info-clobbered-before-it-is-logged.patch
-usb.current/usb-serial-sierra-driver-send_setup-autopm-fix.patch
-usb.current/usb-serial-sierra-driver-autopm-fixes.patch
-usb.current/usb-r8a66597-hcd-fix-cannot-detect-a-device-when-uses_new_polling-is-set.patch
-usb.current/usb-option-tlaytech-tue800-support.patch
-usb.current/usb-fsl_udc_core-fix-kernel-oops-on-module-removal.patch
-
#################################
# Staging patches for 2.6.32
#################################
-staging.current/staging-hv-todo-patches.patch
-staging.current/staging-hv-fix-null-pointer-error-after-vmbus-loading.patch
-staging.current/staging-hv-fix-vmbus-load-hang-caused-by-faulty-data-packing.patch
-staging.current/staging-hv-fix-oops-in-vmbus-udev-events.patch
-staging.current/staging-hv-fix-oops-in-vmbus-netvsc-list_head.patch
-staging.current/staging-hv-fix-oops-in-vmbus-missing-include.patch
-staging.current/staging-panel-prevent-driver-from-calling-misc_deregister-twice-on-same-ressource.patch
-staging.current/staging-vt6656-fix-the-memory-free-bug-in-vntwusb_disconnect.patch
-staging.current/staging-rtl8187se-rtl8192e-rtl8192su-allow-module-unload.patch
-staging.current/staging-remove-stlc45xx-driver.patch
-staging.current/staging-android-mark-subsystem-as-broken.patch
-staging.current/staging-wireless-drivers-kconfig-change.patch
-staging.current/staging-fix-wireless-drivers-depends.patch
+
#####################################################################
# Stuff to be merged after 2.6.32 is out
@@ -66,6 +37,7 @@ driver-core/driver-core-devtmpfs-prevent-concurrent-subdirectory-creation-and-re
driver-core/driver-core-devtmpfs-use-sys_mount.patch
driver-core/driver-core-devtmpfs-do-not-remove-non-kernel-created-directories.patch
driver-core/driver-core-devtmpfs-cleanup-node-on-device-creation-error.patch
+driver-core/driver-core-devtmpfs-set-root-directory-mode-to-0755.patch
driver-core/firmware_class-make-request_firmware_nowait-more-useful.patch
diff --git a/staging.current/staging-android-mark-subsystem-as-broken.patch b/staging.current/staging-android-mark-subsystem-as-broken.patch
deleted file mode 100644
index 7b49342c3b6771..00000000000000
--- a/staging.current/staging-android-mark-subsystem-as-broken.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From foo@baz Mon Oct 26 16:03:51 PDT 2009
-Date: Mon, 26 Oct 2009 16:03:51 -0700
-To: Greg KH <greg@kroah.com>
-From: Greg Kroah-Hartman <gregkh@suse.de>
-Subject: Staging: android: mark subsystem as broken
-
-It's causing lots of build errors, so just mark it as broken. It is
-scheduled to be removed in 2.6.33 anyway.
-
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/staging/android/Kconfig | 1 +
- 1 file changed, 1 insertion(+)
-
---- a/drivers/staging/android/Kconfig
-+++ b/drivers/staging/android/Kconfig
-@@ -2,6 +2,7 @@ menu "Android"
-
- config ANDROID
- bool "Android Drivers"
-+ depends on BROKEN
- default N
- ---help---
- Enable support for various drivers needed on the Android platform
diff --git a/staging.current/staging-fix-wireless-drivers-depends.patch b/staging.current/staging-fix-wireless-drivers-depends.patch
deleted file mode 100644
index 1f370c1eab2399..00000000000000
--- a/staging.current/staging-fix-wireless-drivers-depends.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-From randy.dunlap@oracle.com Thu Oct 29 11:40:30 2009
-From: Randy Dunlap <randy.dunlap@oracle.com>
-Date: Thu, 29 Oct 2009 09:52:02 -0700
-Subject: Staging: fix wireless drivers depends
-To: Stephen Rothwell <sfr@canb.auug.org.au>, gregkh@suse.de
-Message-ID: <20091029095202.09161c1e.randy.dunlap@oracle.com>
-
-
-From: Randy Dunlap <randy.dunlap@oracle.com>
-
-These drivers can (erroneously) be enabled even when
-CONFIG_NET=n, CONFIG_NETDEVICES=n, CONFIG_WLAN=n, etc.
-Stop this.
-
-Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/staging/rtl8187se/Kconfig | 2 +-
- drivers/staging/rtl8192e/Kconfig | 2 +-
- drivers/staging/rtl8192su/Kconfig | 2 +-
- 3 files changed, 3 insertions(+), 3 deletions(-)
-
---- a/drivers/staging/rtl8187se/Kconfig
-+++ b/drivers/staging/rtl8187se/Kconfig
-@@ -1,6 +1,6 @@
- config RTL8187SE
- tristate "RealTek RTL8187SE Wireless LAN NIC driver"
-- depends on PCI
-+ depends on PCI && WLAN
- depends on WIRELESS_EXT
- default N
- ---help---
---- a/drivers/staging/rtl8192e/Kconfig
-+++ b/drivers/staging/rtl8192e/Kconfig
-@@ -1,6 +1,6 @@
- config RTL8192E
- tristate "RealTek RTL8192E Wireless LAN NIC driver"
-- depends on PCI
-+ depends on PCI && WLAN
- depends on WIRELESS_EXT
- default N
- ---help---
---- a/drivers/staging/rtl8192su/Kconfig
-+++ b/drivers/staging/rtl8192su/Kconfig
-@@ -1,6 +1,6 @@
- config RTL8192SU
- tristate "RealTek RTL8192SU Wireless LAN NIC driver"
-- depends on PCI
-+ depends on PCI && WLAN
- depends on WIRELESS_EXT
- default N
- ---help---
diff --git a/staging.current/staging-hv-fix-null-pointer-error-after-vmbus-loading.patch b/staging.current/staging-hv-fix-null-pointer-error-after-vmbus-loading.patch
deleted file mode 100644
index a090cc1b79f2b2..00000000000000
--- a/staging.current/staging-hv-fix-null-pointer-error-after-vmbus-loading.patch
+++ /dev/null
@@ -1,52 +0,0 @@
-From haiyangz@microsoft.com Mon Oct 26 12:20:37 2009
-From: Haiyang Zhang <haiyangz@microsoft.com>
-Date: Fri, 23 Oct 2009 18:14:24 +0000
-Subject: Staging: hv: Fix null pointer error after vmbus loading
-To: <gregkh@suse.de>, Hank Janssen <hjanssen@microsoft.com>
-Message-ID: <1FB5E1D5CA062146B38059374562DF72180B4422@TK5EX14MBXC126.redmond.corp.microsoft.com>
-
-
-From: Haiyang Zhang <haiyangz@microsoft.com>
-
-Fix null pointer error after vmbus loading. Remove code that checks for
-dev_name, the affected structure is kzalloc-ed prior to this routine, so
-it is always null at this stage.
-
-Signed-off-by: Hank Janssen <hjanssen@microsoft.com>
-Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/staging/hv/vmbus_drv.c | 14 +-------------
- 1 file changed, 1 insertion(+), 13 deletions(-)
-
---- a/drivers/staging/hv/vmbus_drv.c
-+++ b/drivers/staging/hv/vmbus_drv.c
-@@ -537,18 +537,7 @@ static int vmbus_child_device_register(s
- DPRINT_DBG(VMBUS_DRV, "child device (%p) registering",
- child_device_ctx);
-
-- /* Make sure we are not registered already */
-- if (strlen(dev_name(&child_device_ctx->device)) != 0) {
-- DPRINT_ERR(VMBUS_DRV,
-- "child device (%p) already registered - busid %s",
-- child_device_ctx,
-- dev_name(&child_device_ctx->device));
--
-- ret = -1;
-- goto Cleanup;
-- }
--
-- /* Set the device bus id. Otherwise, device_register()will fail. */
-+ /* Set the device name. Otherwise, device_register() will fail. */
- dev_set_name(&child_device_ctx->device, "vmbus_0_%d",
- atomic_inc_return(&device_num));
-
-@@ -573,7 +562,6 @@ static int vmbus_child_device_register(s
- DPRINT_INFO(VMBUS_DRV, "child device (%p) registered",
- &child_device_ctx->device);
-
--Cleanup:
- DPRINT_EXIT(VMBUS_DRV);
-
- return ret;
diff --git a/staging.current/staging-hv-fix-oops-in-vmbus-missing-include.patch b/staging.current/staging-hv-fix-oops-in-vmbus-missing-include.patch
deleted file mode 100644
index e1b1f6d04a20b7..00000000000000
--- a/staging.current/staging-hv-fix-oops-in-vmbus-missing-include.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From milan@dadok.name Wed Oct 28 18:15:47 2009
-From: Milan Dadok <milan@dadok.name>
-Date: Wed, 28 Oct 2009 23:23:50 +0100
-Subject: Staging: hv: fix oops in vmbus - missing #include
-To: 'Greg Kroah-Hartman' <gregkh@suse.de>
-Cc: 'Hank Janssen' <hjanssen@microsoft.com>, 'Haiyang Zhang' <haiyangz@microsoft.com>
-Message-ID: <001601ca581d$5390e0e0$fab2a2a0$@name>
-
-
-Add missing #includes to make hv module compile successfull.
-
-Signed-off-by: Milan Dadok <milan@dadok.name>
-Cc: Hank Janssen <hjanssen@microsoft.com>
-Cc: Haiyang Zhang <haiyangz@microsoft.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/staging/hv/ChannelMgmt.h | 1 +
- drivers/staging/hv/osd.h | 1 +
- 2 files changed, 2 insertions(+)
-
---- a/drivers/staging/hv/ChannelMgmt.h
-+++ b/drivers/staging/hv/ChannelMgmt.h
-@@ -26,6 +26,7 @@
- #define _CHANNEL_MGMT_H_
-
- #include <linux/list.h>
-+#include <linux/timer.h>
- #include "RingBuffer.h"
- #include "VmbusChannelInterface.h"
- #include "VmbusPacketFormat.h"
---- a/drivers/staging/hv/osd.h
-+++ b/drivers/staging/hv/osd.h
-@@ -25,6 +25,7 @@
- #ifndef _OSD_H_
- #define _OSD_H_
-
-+#include <linux/workqueue.h>
-
- /* Defines */
- #define ALIGN_UP(value, align) (((value) & (align-1)) ? \
diff --git a/staging.current/staging-hv-fix-oops-in-vmbus-netvsc-list_head.patch b/staging.current/staging-hv-fix-oops-in-vmbus-netvsc-list_head.patch
deleted file mode 100644
index e81177e0ab42aa..00000000000000
--- a/staging.current/staging-hv-fix-oops-in-vmbus-netvsc-list_head.patch
+++ /dev/null
@@ -1,61 +0,0 @@
-From milan@dadok.name Wed Oct 28 18:10:53 2009
-From: Milan Dadok <milan@dadok.name>
-Date: Wed, 28 Oct 2009 23:23:37 +0100
-Subject: Staging: hv: fix oops in vmbus - netvsc list_head
-To: 'Greg Kroah-Hartman' <gregkh@suse.de>
-Cc: 'Hank Janssen' <hjanssen@microsoft.com>, 'Haiyang Zhang' <haiyangz@microsoft.com>
-Message-ID: <001501ca581d$4c201fb0$e4605f10$@name>
-
-
-Remove incorrect list_head usage. Variable of type list_head was used in
-some function's arguments as list item.
-
-Signed-off-by: Milan Dadok <milan@dadok.name>
-Cc: Hank Janssen <hjanssen@microsoft.com>
-Cc: Haiyang Zhang <haiyangz@microsoft.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/staging/hv/NetVsc.c | 10 ++++------
- 1 file changed, 4 insertions(+), 6 deletions(-)
-
---- a/drivers/staging/hv/NetVsc.c
-+++ b/drivers/staging/hv/NetVsc.c
-@@ -1052,7 +1052,7 @@ static void NetVscOnReceive(struct hv_de
- */
- spin_lock_irqsave(&netDevice->receive_packet_list_lock, flags);
- while (!list_empty(&netDevice->ReceivePacketList)) {
-- list_move_tail(&netDevice->ReceivePacketList, &listHead);
-+ list_move_tail(netDevice->ReceivePacketList.next, &listHead);
- if (++count == vmxferpagePacket->RangeCount + 1)
- break;
- }
-@@ -1071,7 +1071,7 @@ static void NetVscOnReceive(struct hv_de
- /* Return it to the freelist */
- spin_lock_irqsave(&netDevice->receive_packet_list_lock, flags);
- for (i = count; i != 0; i--) {
-- list_move_tail(&listHead,
-+ list_move_tail(listHead.next,
- &netDevice->ReceivePacketList);
- }
- spin_unlock_irqrestore(&netDevice->receive_packet_list_lock,
-@@ -1085,8 +1085,7 @@ static void NetVscOnReceive(struct hv_de
- }
-
- /* Remove the 1st packet to represent the xfer page packet itself */
-- xferpagePacket = list_entry(&listHead, struct xferpage_packet,
-- ListEntry);
-+ xferpagePacket = (struct xferpage_packet*)listHead.next;
- list_del(&xferpagePacket->ListEntry);
-
- /* This is how much we can satisfy */
-@@ -1102,8 +1101,7 @@ static void NetVscOnReceive(struct hv_de
-
- /* Each range represents 1 RNDIS pkt that contains 1 ethernet frame */
- for (i = 0; i < (count - 1); i++) {
-- netvscPacket = list_entry(&listHead, struct hv_netvsc_packet,
-- ListEntry);
-+ netvscPacket = (struct hv_netvsc_packet*)listHead.next;
- list_del(&netvscPacket->ListEntry);
-
- /* Initialize the netvsc packet */
diff --git a/staging.current/staging-hv-fix-oops-in-vmbus-udev-events.patch b/staging.current/staging-hv-fix-oops-in-vmbus-udev-events.patch
deleted file mode 100644
index 1947f55f0ad83c..00000000000000
--- a/staging.current/staging-hv-fix-oops-in-vmbus-udev-events.patch
+++ /dev/null
@@ -1,66 +0,0 @@
-From milan@dadok.name Wed Oct 28 18:07:41 2009
-From: Milan Dadok <milan@dadok.name>
-Date: Wed, 28 Oct 2009 23:23:27 +0100
-Subject: Staging: hv: fix oops in vmbus - udev events
-To: 'Greg Kroah-Hartman' <gregkh@suse.de>
-Cc: 'Hank Janssen' <hjanssen@microsoft.com>, 'Haiyang Zhang' <haiyangz@microsoft.com>
-Message-ID: <001401ca581d$456c45e0$d044d1a0$@name>
-
-
-Fix typos in udev event send and guid variables copy
-
-Signed-off-by: Milan Dadok <milan@dadok.name>
-Cc: Hank Janssen <hjanssen@microsoft.com>
-Cc: Haiyang Zhang <haiyangz@microsoft.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/staging/hv/vmbus_drv.c | 14 ++++----------
- 1 file changed, 4 insertions(+), 10 deletions(-)
-
---- a/drivers/staging/hv/vmbus_drv.c
-+++ b/drivers/staging/hv/vmbus_drv.c
-@@ -507,12 +507,12 @@ static struct hv_device *vmbus_child_dev
-
- child_device_obj = &child_device_ctx->device_obj;
- child_device_obj->context = context;
-- memcpy(&child_device_obj->deviceType, &type, sizeof(struct hv_guid));
-- memcpy(&child_device_obj->deviceInstance, &instance,
-+ memcpy(&child_device_obj->deviceType, type, sizeof(struct hv_guid));
-+ memcpy(&child_device_obj->deviceInstance, instance,
- sizeof(struct hv_guid));
-
-- memcpy(&child_device_ctx->class_id, &type, sizeof(struct hv_guid));
-- memcpy(&child_device_ctx->device_id, &instance, sizeof(struct hv_guid));
-+ memcpy(&child_device_ctx->class_id, type, sizeof(struct hv_guid));
-+ memcpy(&child_device_ctx->device_id, instance, sizeof(struct hv_guid));
-
- DPRINT_EXIT(VMBUS_DRV);
-
-@@ -611,8 +611,6 @@ static void vmbus_child_device_destroy(s
- static int vmbus_uevent(struct device *device, struct kobj_uevent_env *env)
- {
- struct device_context *device_ctx = device_to_device_context(device);
-- int i = 0;
-- int len = 0;
- int ret;
-
- DPRINT_ENTER(VMBUS_DRV);
-@@ -632,8 +630,6 @@ static int vmbus_uevent(struct device *d
- device_ctx->class_id.data[14],
- device_ctx->class_id.data[15]);
-
-- env->envp_idx = i;
-- env->buflen = len;
- ret = add_uevent_var(env, "VMBUS_DEVICE_CLASS_GUID={"
- "%02x%02x%02x%02x-%02x%02x-%02x%02x-"
- "%02x%02x%02x%02x%02x%02x%02x%02x}",
-@@ -679,8 +675,6 @@ static int vmbus_uevent(struct device *d
- if (ret)
- return ret;
-
-- env->envp[env->envp_idx] = NULL;
--
- DPRINT_EXIT(VMBUS_DRV);
-
- return 0;
diff --git a/staging.current/staging-hv-fix-vmbus-load-hang-caused-by-faulty-data-packing.patch b/staging.current/staging-hv-fix-vmbus-load-hang-caused-by-faulty-data-packing.patch
deleted file mode 100644
index c4a0bc8e7d50c7..00000000000000
--- a/staging.current/staging-hv-fix-vmbus-load-hang-caused-by-faulty-data-packing.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From hjanssen@microsoft.com Mon Oct 26 12:22:08 2009
-From: Hank Janssen <hjanssen@microsoft.com>
-Date: Fri, 16 Oct 2009 20:11:36 +0000
-Subject: Staging: hv: Fix vmbus load hang caused by faulty data packing
-To: Greg Kroah-Hartman <gregkh@suse.de>
-Cc: Tom Hanrahan <hanrahat@microsoft.com>, Hashir Abdi <habdi@microsoft.com>, Haiyang Zhang <haiyangz@microsoft.com>
-Message-ID: <8AFC7968D54FB448A30D8F38F259C5620E7B5F30@TK5EX14MBXC114.redmond.corp.microsoft.com>
-
-From: Hank Janssen <hjanssen@microsoft.com>
-
-Fix vmbus load hang caused by wrong data packing.
-
-Signed-off-by: Hank Janssen<hjanssen@microsoft.com>
-Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/staging/hv/ChannelMgmt.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
---- a/drivers/staging/hv/ChannelMgmt.h
-+++ b/drivers/staging/hv/ChannelMgmt.h
-@@ -54,7 +54,7 @@ enum vmbus_channel_message_type {
- ChannelMessageViewRangeRemove = 18,
- #endif
- ChannelMessageCount
--} __attribute__((packed));
-+};
-
- struct vmbus_channel_message_header {
- enum vmbus_channel_message_type MessageType;
diff --git a/staging.current/staging-hv-todo-patches.patch b/staging.current/staging-hv-todo-patches.patch
deleted file mode 100644
index 3c977de7280d31..00000000000000
--- a/staging.current/staging-hv-todo-patches.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From shemminger@vyatta.com Fri Oct 9 15:54:24 2009
-From: Stephen Hemminger <shemminger@vyatta.com>
-Date: Fri, 9 Oct 2009 15:47:50 -0700
-Subject: Staging: hv TODO patches
-To: Greg KH <greg@kroah.com>, Haiyang Zhang <haiyangz@microsoft.com>
-Message-ID: <20091009154750.0ece1faa@s6510>
-
-
-Update for more items
-
-Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
-Cc: Hank Janssen <hjanssen@microsoft.com>
-Cc: Haiyang Zhang <haiyangz@microsoft.com>.
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/staging/hv/TODO | 6 ++++++
- 1 file changed, 6 insertions(+)
-
---- a/drivers/staging/hv/TODO
-+++ b/drivers/staging/hv/TODO
-@@ -1,11 +1,17 @@
- TODO:
- - fix remaining checkpatch warnings and errors
-+ - use of /** when it is not a kerneldoc header
- - remove RingBuffer.c to us in-kernel ringbuffer functions instead.
- - audit the vmbus to verify it is working properly with the
- driver model
-+ - convert vmbus driver interface function pointer tables
-+ to constant, a.k.a vmbus_ops
- - see if the vmbus can be merged with the other virtual busses
- in the kernel
- - audit the network driver
-+ - use existing net_device_stats struct in network device
-+ - checking for carrier inside open is wrong, network device API
-+ confusion??
- - audit the block driver
- - audit the scsi driver
-
diff --git a/staging.current/staging-panel-prevent-driver-from-calling-misc_deregister-twice-on-same-ressource.patch b/staging.current/staging-panel-prevent-driver-from-calling-misc_deregister-twice-on-same-ressource.patch
deleted file mode 100644
index cbd2441ac134d8..00000000000000
--- a/staging.current/staging-panel-prevent-driver-from-calling-misc_deregister-twice-on-same-ressource.patch
+++ /dev/null
@@ -1,72 +0,0 @@
-From PeterHuewe@gmx.de Mon Oct 26 14:30:49 2009
-From: Peter Huewe <PeterHuewe@gmx.de>
-Date: Tue, 29 Sep 2009 01:22:40 +0200
-Subject: Staging: Panel: prevent driver from calling misc_deregister twice on same ressource
-To: "Greg Kroah-Hartman" <gregkh@suse.de>
-Cc: Willy Tarreau <w@1wt.eu>, Sudhakar Rajashekhara <sudhakar.raj@ti.com>, Costantino Leandro <lcostantino@gmail.com>, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org
-Message-ID: <200909290122.40485.PeterHuewe@gmx.de>
-Content-Disposition: inline
-
-
-From: Peter Huewe <peterhuewe@gmx.de>
-
-This patch prevents the driver from calling misc_deregister twice on the same
-ressouce when unloading the driver.
-Unloading the driver without this patch results in a Kernel BUG like this:
-Panel driver version 0.9.5 registered on parport0 (io=0x378).
-BUG: unable to handle kernel paging request at 0000000000100108
-IP: [<ffffffff803c02ee>] misc_deregister+0x2d/0x90
-PGD 6caff067 PUD 762b7067 PMD 0
-Oops: 0002 [#1] PREEMPT SMP
-last sysfs file: /sys/devices/platform/w83627hf.656/in8_input
-...
-
-This patch fixes this issue, although maybe not in the best way possible :)
-
-linux version v2.6.32-rc1 - linus git tree, Di 29. Sep 01:10:18 CEST 2009
-
-Signed-off-by: Peter Huewe <peterhuewe@gmx.de>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/staging/panel/panel.c | 13 ++++++++++---
- 1 file changed, 10 insertions(+), 3 deletions(-)
-
---- a/drivers/staging/panel/panel.c
-+++ b/drivers/staging/panel/panel.c
-@@ -2071,11 +2071,15 @@ static void panel_detach(struct parport
- return;
- }
-
-- if (keypad_enabled && keypad_initialized)
-+ if (keypad_enabled && keypad_initialized) {
- misc_deregister(&keypad_dev);
-+ keypad_initialized = 0;
-+ }
-
-- if (lcd_enabled && lcd_initialized)
-+ if (lcd_enabled && lcd_initialized) {
- misc_deregister(&lcd_dev);
-+ lcd_initialized = 0;
-+ }
-
- parport_release(pprt);
- parport_unregister_device(pprt);
-@@ -2211,13 +2215,16 @@ static void __exit panel_cleanup_module(
- del_timer(&scan_timer);
-
- if (pprt != NULL) {
-- if (keypad_enabled)
-+ if (keypad_enabled) {
- misc_deregister(&keypad_dev);
-+ keypad_initialized = 0;
-+ }
-
- if (lcd_enabled) {
- panel_lcd_print("\x0cLCD driver " PANEL_VERSION
- "\nunloaded.\x1b[Lc\x1b[Lb\x1b[L-");
- misc_deregister(&lcd_dev);
-+ lcd_initialized = 0;
- }
-
- /* TODO: free all input signals */
diff --git a/staging.current/staging-remove-stlc45xx-driver.patch b/staging.current/staging-remove-stlc45xx-driver.patch
deleted file mode 100644
index 6b8169f27023c1..00000000000000
--- a/staging.current/staging-remove-stlc45xx-driver.patch
+++ /dev/null
@@ -1,3380 +0,0 @@
-From foo@baz Mon Oct 26 16:35:32 PDT 2009
-Date: Mon, 26 Oct 2009 16:35:32 -0700
-To: Greg KH <greg@kroah.com>
-From: Greg Kroah-Hartman <gregkh@suse.de>
-Subject: Staging: remove stlc45xx driver
-
-It's no longer needed as the p54spi driver is the same thing,
-under a different name and in the correct portion of the kernel tree.
-
-
-Cc: Javier Martinez Canillas <martinez.javier@gmail.com>
-Cc: Christian Lamparter <chunkeey@googlemail.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/staging/Kconfig | 2
- drivers/staging/Makefile | 1
- drivers/staging/stlc45xx/Kconfig | 8
- drivers/staging/stlc45xx/Makefile | 1
- drivers/staging/stlc45xx/stlc45xx.c | 2594 -------------------------------
- drivers/staging/stlc45xx/stlc45xx.h | 283 ---
- drivers/staging/stlc45xx/stlc45xx_lmac.h | 434 -----
- 7 files changed, 3323 deletions(-)
-
---- a/drivers/staging/Kconfig
-+++ b/drivers/staging/Kconfig
-@@ -93,8 +93,6 @@ source "drivers/staging/dst/Kconfig"
-
- source "drivers/staging/pohmelfs/Kconfig"
-
--source "drivers/staging/stlc45xx/Kconfig"
--
- source "drivers/staging/b3dfg/Kconfig"
-
- source "drivers/staging/phison/Kconfig"
---- a/drivers/staging/Makefile
-+++ b/drivers/staging/Makefile
-@@ -29,7 +29,6 @@ obj-$(CONFIG_ANDROID) += android/
- obj-$(CONFIG_ANDROID) += dream/
- obj-$(CONFIG_DST) += dst/
- obj-$(CONFIG_POHMELFS) += pohmelfs/
--obj-$(CONFIG_STLC45XX) += stlc45xx/
- obj-$(CONFIG_B3DFG) += b3dfg/
- obj-$(CONFIG_IDE_PHISON) += phison/
- obj-$(CONFIG_PLAN9AUTH) += p9auth/
---- a/drivers/staging/stlc45xx/Kconfig
-+++ /dev/null
-@@ -1,8 +0,0 @@
--config STLC45XX
-- tristate "stlc4550/4560 support"
-- depends on MAC80211 && WLAN_80211 && SPI_MASTER && GENERIC_HARDIRQS
-- ---help---
-- This is a driver for stlc4550 and stlc4560 chipsets.
--
-- To compile this driver as a module, choose M here: the module will be
-- called stlc45xx. If unsure, say N.
---- a/drivers/staging/stlc45xx/Makefile
-+++ /dev/null
-@@ -1 +0,0 @@
--obj-$(CONFIG_STLC45XX) += stlc45xx.o
---- a/drivers/staging/stlc45xx/stlc45xx.c
-+++ /dev/null
-@@ -1,2594 +0,0 @@
--/*
-- * This file is part of stlc45xx
-- *
-- * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies).
-- *
-- * Contact: Kalle Valo <kalle.valo@nokia.com>
-- *
-- * This program is free software; you can redistribute it and/or
-- * modify it under the terms of the GNU General Public License
-- * version 2 as published by the Free Software Foundation.
-- *
-- * This program is distributed in the hope that it will be useful, but
-- * WITHOUT ANY WARRANTY; without even the implied warranty of
-- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-- * General Public License for more details.
-- *
-- * You should have received a copy of the GNU General Public License
-- * along with this program; if not, write to the Free Software
-- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-- * 02110-1301 USA
-- *
-- */
--
--#include "stlc45xx.h"
--
--#include <linux/module.h>
--#include <linux/platform_device.h>
--#include <linux/interrupt.h>
--#include <linux/firmware.h>
--#include <linux/delay.h>
--#include <linux/irq.h>
--#include <linux/spi/spi.h>
--#include <linux/etherdevice.h>
--#include <linux/gpio.h>
--#include <linux/moduleparam.h>
--
--#include "stlc45xx_lmac.h"
--
--/*
-- * gpios should be handled in board files and provided via platform data,
-- * but because it's currently impossible for stlc45xx to have a header file
-- * in include/linux, let's use module paramaters for now
-- */
--static int stlc45xx_gpio_power = 97;
--module_param(stlc45xx_gpio_power, int, 0444);
--MODULE_PARM_DESC(stlc45xx_gpio_power, "stlc45xx gpio number for power line");
--
--static int stlc45xx_gpio_irq = 87;
--module_param(stlc45xx_gpio_irq, int, 0444);
--MODULE_PARM_DESC(stlc45xx_gpio_irq, "stlc45xx gpio number for irq line");
--
--static const u8 default_cal_channels[] = {
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6c, 0x09,
-- 0x00, 0x00, 0xc9, 0xff, 0xd8, 0xff, 0x00, 0x00, 0x00, 0x01, 0x10,
-- 0x01, 0x10, 0x01, 0x10, 0x01, 0x10, 0x01, 0xe0, 0x00, 0xe0, 0x00,
-- 0xe0, 0x00, 0xe0, 0x00, 0xd0, 0x00, 0xd0, 0x00, 0xd0, 0x00, 0xd0,
-- 0x00, 0x54, 0x01, 0xab, 0xf6, 0xc0, 0x42, 0xc0, 0x42, 0xc0, 0x42,
-- 0xc0, 0x42, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00,
-- 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x22, 0x01, 0x37, 0xa9,
-- 0xc0, 0x33, 0xc0, 0x33, 0xc0, 0x33, 0xc0, 0x33, 0x00, 0xbc, 0x00,
-- 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc,
-- 0x00, 0xbc, 0xfb, 0x00, 0xca, 0x79, 0xc0, 0x2b, 0xc0, 0x2b, 0xc0,
-- 0x2b, 0xc0, 0x2b, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4,
-- 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0xd0, 0x00, 0x5d,
-- 0x54, 0xc0, 0x21, 0xc0, 0x21, 0xc0, 0x21, 0xc0, 0x21, 0x00, 0xaa,
-- 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00,
-- 0xaa, 0x00, 0xaa, 0xa7, 0x00, 0xa9, 0x3d, 0xc0, 0x17, 0xc0, 0x17,
-- 0xc0, 0x17, 0xc0, 0x17, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00,
-- 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x7a, 0x00,
-- 0x06, 0x2c, 0xc0, 0x0d, 0xc0, 0x0d, 0xc0, 0x0d, 0xc0, 0x0d, 0x00,
-- 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96,
-- 0x00, 0x96, 0x00, 0x96, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x06, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x71, 0x09, 0x00, 0x00, 0xc9, 0xff, 0xd8,
-- 0xff, 0x00, 0x00, 0x00, 0x01, 0x10, 0x01, 0x10, 0x01, 0x10, 0x01,
-- 0x10, 0x01, 0xf0, 0x00, 0xf0, 0x00, 0xf0, 0x00, 0xf0, 0x00, 0xd0,
-- 0x00, 0xd0, 0x00, 0xd0, 0x00, 0xd0, 0x00, 0x54, 0x01, 0xab, 0xf6,
-- 0xc0, 0x42, 0xc0, 0x42, 0xc0, 0x42, 0xc0, 0x42, 0x00, 0xcb, 0x00,
-- 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb,
-- 0x00, 0xcb, 0x22, 0x01, 0x37, 0xa9, 0xc0, 0x33, 0xc0, 0x33, 0xc0,
-- 0x33, 0xc0, 0x33, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc,
-- 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0xfb, 0x00, 0xca,
-- 0x79, 0xc0, 0x2b, 0xc0, 0x2b, 0xc0, 0x2b, 0xc0, 0x2b, 0x00, 0xb4,
-- 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00,
-- 0xb4, 0x00, 0xb4, 0xd0, 0x00, 0x5d, 0x54, 0xc0, 0x21, 0xc0, 0x21,
-- 0xc0, 0x21, 0xc0, 0x21, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00,
-- 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0xa7, 0x00,
-- 0xa9, 0x3d, 0xc0, 0x17, 0xc0, 0x17, 0xc0, 0x17, 0xc0, 0x17, 0x00,
-- 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0,
-- 0x00, 0xa0, 0x00, 0xa0, 0x7a, 0x00, 0x06, 0x2c, 0xc0, 0x0d, 0xc0,
-- 0x0d, 0xc0, 0x0d, 0xc0, 0x0d, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96,
-- 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x80, 0x80,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x76,
-- 0x09, 0x00, 0x00, 0xc9, 0xff, 0xd8, 0xff, 0x00, 0x00, 0x00, 0x01,
-- 0x10, 0x01, 0x10, 0x01, 0x10, 0x01, 0x10, 0x01, 0xf0, 0x00, 0xf0,
-- 0x00, 0xf0, 0x00, 0xf0, 0x00, 0xd0, 0x00, 0xd0, 0x00, 0xd0, 0x00,
-- 0xd0, 0x00, 0x54, 0x01, 0xab, 0xf6, 0xc0, 0x42, 0xc0, 0x42, 0xc0,
-- 0x42, 0xc0, 0x42, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb,
-- 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x22, 0x01, 0x37,
-- 0xa9, 0xc0, 0x33, 0xc0, 0x33, 0xc0, 0x33, 0xc0, 0x33, 0x00, 0xbc,
-- 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00,
-- 0xbc, 0x00, 0xbc, 0xfb, 0x00, 0xca, 0x79, 0xc0, 0x2b, 0xc0, 0x2b,
-- 0xc0, 0x2b, 0xc0, 0x2b, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00,
-- 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0xd0, 0x00,
-- 0x5d, 0x54, 0xc0, 0x21, 0xc0, 0x21, 0xc0, 0x21, 0xc0, 0x21, 0x00,
-- 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa,
-- 0x00, 0xaa, 0x00, 0xaa, 0xa7, 0x00, 0xa9, 0x3d, 0xc0, 0x17, 0xc0,
-- 0x17, 0xc0, 0x17, 0xc0, 0x17, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0,
-- 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x7a,
-- 0x00, 0x06, 0x2c, 0xc0, 0x0d, 0xc0, 0x0d, 0xc0, 0x0d, 0xc0, 0x0d,
-- 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00,
-- 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x06, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x7b, 0x09, 0x00, 0x00, 0xc9, 0xff,
-- 0xd8, 0xff, 0x00, 0x00, 0x00, 0x01, 0x10, 0x01, 0x10, 0x01, 0x10,
-- 0x01, 0x10, 0x01, 0xf0, 0x00, 0xf0, 0x00, 0xf0, 0x00, 0xf0, 0x00,
-- 0xd0, 0x00, 0xd0, 0x00, 0xd0, 0x00, 0xd0, 0x00, 0x54, 0x01, 0xab,
-- 0xf6, 0xc0, 0x42, 0xc0, 0x42, 0xc0, 0x42, 0xc0, 0x42, 0x00, 0xcb,
-- 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00,
-- 0xcb, 0x00, 0xcb, 0x22, 0x01, 0x37, 0xa9, 0xc0, 0x33, 0xc0, 0x33,
-- 0xc0, 0x33, 0xc0, 0x33, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00,
-- 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0xfb, 0x00,
-- 0xca, 0x79, 0xc0, 0x2b, 0xc0, 0x2b, 0xc0, 0x2b, 0xc0, 0x2b, 0x00,
-- 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4,
-- 0x00, 0xb4, 0x00, 0xb4, 0xd0, 0x00, 0x5d, 0x54, 0xc0, 0x21, 0xc0,
-- 0x21, 0xc0, 0x21, 0xc0, 0x21, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa,
-- 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0xa7,
-- 0x00, 0xa9, 0x3d, 0xc0, 0x17, 0xc0, 0x17, 0xc0, 0x17, 0xc0, 0x17,
-- 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00,
-- 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x7a, 0x00, 0x06, 0x2c, 0xc0, 0x0d,
-- 0xc0, 0x0d, 0xc0, 0x0d, 0xc0, 0x0d, 0x00, 0x96, 0x00, 0x96, 0x00,
-- 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x80,
-- 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x80, 0x09, 0x00, 0x00, 0xc9, 0xff, 0xd8, 0xff, 0x00, 0x00, 0x00,
-- 0x01, 0x10, 0x01, 0x10, 0x01, 0x10, 0x01, 0x10, 0x01, 0xf0, 0x00,
-- 0xf0, 0x00, 0xf0, 0x00, 0xf0, 0x00, 0xd0, 0x00, 0xd0, 0x00, 0xd0,
-- 0x00, 0xd0, 0x00, 0x54, 0x01, 0xab, 0xf6, 0xc0, 0x42, 0xc0, 0x42,
-- 0xc0, 0x42, 0xc0, 0x42, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00,
-- 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x22, 0x01,
-- 0x37, 0xa9, 0xc0, 0x33, 0xc0, 0x33, 0xc0, 0x33, 0xc0, 0x33, 0x00,
-- 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc,
-- 0x00, 0xbc, 0x00, 0xbc, 0xfb, 0x00, 0xca, 0x79, 0xc0, 0x2b, 0xc0,
-- 0x2b, 0xc0, 0x2b, 0xc0, 0x2b, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4,
-- 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0xd0,
-- 0x00, 0x5d, 0x54, 0xc0, 0x21, 0xc0, 0x21, 0xc0, 0x21, 0xc0, 0x21,
-- 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00,
-- 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0xa7, 0x00, 0xa9, 0x3d, 0xc0, 0x17,
-- 0xc0, 0x17, 0xc0, 0x17, 0xc0, 0x17, 0x00, 0xa0, 0x00, 0xa0, 0x00,
-- 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0,
-- 0x7a, 0x00, 0x06, 0x2c, 0xc0, 0x0d, 0xc0, 0x0d, 0xc0, 0x0d, 0xc0,
-- 0x0d, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96,
-- 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x06, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x85, 0x09, 0x00, 0x00, 0xc9,
-- 0xff, 0xd8, 0xff, 0x00, 0x00, 0x00, 0x01, 0x10, 0x01, 0x10, 0x01,
-- 0x10, 0x01, 0x10, 0x01, 0xf0, 0x00, 0xf0, 0x00, 0xf0, 0x00, 0xf0,
-- 0x00, 0xd0, 0x00, 0xd0, 0x00, 0xd0, 0x00, 0xd0, 0x00, 0x54, 0x01,
-- 0xab, 0xf6, 0xc0, 0x42, 0xc0, 0x42, 0xc0, 0x42, 0xc0, 0x42, 0x00,
-- 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb,
-- 0x00, 0xcb, 0x00, 0xcb, 0x22, 0x01, 0x37, 0xa9, 0xc0, 0x33, 0xc0,
-- 0x33, 0xc0, 0x33, 0xc0, 0x33, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc,
-- 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0xfb,
-- 0x00, 0xca, 0x79, 0xc0, 0x2b, 0xc0, 0x2b, 0xc0, 0x2b, 0xc0, 0x2b,
-- 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00,
-- 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0xd0, 0x00, 0x5d, 0x54, 0xc0, 0x21,
-- 0xc0, 0x21, 0xc0, 0x21, 0xc0, 0x21, 0x00, 0xaa, 0x00, 0xaa, 0x00,
-- 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa,
-- 0xa7, 0x00, 0xa9, 0x3d, 0xc0, 0x17, 0xc0, 0x17, 0xc0, 0x17, 0xc0,
-- 0x17, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0,
-- 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x7a, 0x00, 0x06, 0x2c, 0xc0,
-- 0x0d, 0xc0, 0x0d, 0xc0, 0x0d, 0xc0, 0x0d, 0x00, 0x96, 0x00, 0x96,
-- 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00,
-- 0x96, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06,
-- 0x80, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x8a, 0x09, 0x00, 0x00, 0xc9, 0xff, 0xd8, 0xff, 0x00, 0x00,
-- 0x00, 0x01, 0x10, 0x01, 0x10, 0x01, 0x10, 0x01, 0x10, 0x01, 0xf0,
-- 0x00, 0xf0, 0x00, 0xf0, 0x00, 0xf0, 0x00, 0xd0, 0x00, 0xd0, 0x00,
-- 0xd0, 0x00, 0xd0, 0x00, 0x54, 0x01, 0xab, 0xf6, 0xc0, 0x42, 0xc0,
-- 0x42, 0xc0, 0x42, 0xc0, 0x42, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb,
-- 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x22,
-- 0x01, 0x37, 0xa9, 0xc0, 0x33, 0xc0, 0x33, 0xc0, 0x33, 0xc0, 0x33,
-- 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00,
-- 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0xfb, 0x00, 0xca, 0x79, 0xc0, 0x2b,
-- 0xc0, 0x2b, 0xc0, 0x2b, 0xc0, 0x2b, 0x00, 0xb4, 0x00, 0xb4, 0x00,
-- 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4,
-- 0xd0, 0x00, 0x5d, 0x54, 0xc0, 0x21, 0xc0, 0x21, 0xc0, 0x21, 0xc0,
-- 0x21, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa,
-- 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0xa7, 0x00, 0xa9, 0x3d, 0xc0,
-- 0x17, 0xc0, 0x17, 0xc0, 0x17, 0xc0, 0x17, 0x00, 0xa0, 0x00, 0xa0,
-- 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00,
-- 0xa0, 0x7a, 0x00, 0x06, 0x2c, 0xc0, 0x0d, 0xc0, 0x0d, 0xc0, 0x0d,
-- 0xc0, 0x0d, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00,
-- 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x80, 0x80, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x8f, 0x09, 0x00, 0x00,
-- 0xc9, 0xff, 0xd8, 0xff, 0x00, 0x00, 0x00, 0x01, 0x10, 0x01, 0x10,
-- 0x01, 0x10, 0x01, 0x10, 0x01, 0xf0, 0x00, 0xf0, 0x00, 0xf0, 0x00,
-- 0xf0, 0x00, 0xd0, 0x00, 0xd0, 0x00, 0xd0, 0x00, 0xd0, 0x00, 0x54,
-- 0x01, 0xab, 0xf6, 0xc0, 0x42, 0xc0, 0x42, 0xc0, 0x42, 0xc0, 0x42,
-- 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00,
-- 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x22, 0x01, 0x37, 0xa9, 0xc0, 0x33,
-- 0xc0, 0x33, 0xc0, 0x33, 0xc0, 0x33, 0x00, 0xbc, 0x00, 0xbc, 0x00,
-- 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc,
-- 0xfb, 0x00, 0xca, 0x79, 0xc0, 0x2b, 0xc0, 0x2b, 0xc0, 0x2b, 0xc0,
-- 0x2b, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4,
-- 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0xd0, 0x00, 0x5d, 0x54, 0xc0,
-- 0x21, 0xc0, 0x21, 0xc0, 0x21, 0xc0, 0x21, 0x00, 0xaa, 0x00, 0xaa,
-- 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00,
-- 0xaa, 0xa7, 0x00, 0xa9, 0x3d, 0xc0, 0x17, 0xc0, 0x17, 0xc0, 0x17,
-- 0xc0, 0x17, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00,
-- 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x7a, 0x00, 0x06, 0x2c,
-- 0xc0, 0x0d, 0xc0, 0x0d, 0xc0, 0x0d, 0xc0, 0x0d, 0x00, 0x96, 0x00,
-- 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96,
-- 0x00, 0x96, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x06, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x94, 0x09, 0x00, 0x00, 0xc9, 0xff, 0xd8, 0xff, 0x00,
-- 0x00, 0x00, 0x01, 0x10, 0x01, 0x10, 0x01, 0x10, 0x01, 0x10, 0x01,
-- 0xf0, 0x00, 0xf0, 0x00, 0xf0, 0x00, 0xf0, 0x00, 0xd0, 0x00, 0xd0,
-- 0x00, 0xd0, 0x00, 0xd0, 0x00, 0x54, 0x01, 0xab, 0xf6, 0xc0, 0x42,
-- 0xc0, 0x42, 0xc0, 0x42, 0xc0, 0x42, 0x00, 0xcb, 0x00, 0xcb, 0x00,
-- 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb,
-- 0x22, 0x01, 0x37, 0xa9, 0xc0, 0x33, 0xc0, 0x33, 0xc0, 0x33, 0xc0,
-- 0x33, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc,
-- 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0xfb, 0x00, 0xca, 0x79, 0xc0,
-- 0x2b, 0xc0, 0x2b, 0xc0, 0x2b, 0xc0, 0x2b, 0x00, 0xb4, 0x00, 0xb4,
-- 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00,
-- 0xb4, 0xd0, 0x00, 0x5d, 0x54, 0xc0, 0x21, 0xc0, 0x21, 0xc0, 0x21,
-- 0xc0, 0x21, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00,
-- 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0xa7, 0x00, 0xa9, 0x3d,
-- 0xc0, 0x17, 0xc0, 0x17, 0xc0, 0x17, 0xc0, 0x17, 0x00, 0xa0, 0x00,
-- 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0,
-- 0x00, 0xa0, 0x7a, 0x00, 0x06, 0x2c, 0xc0, 0x0d, 0xc0, 0x0d, 0xc0,
-- 0x0d, 0xc0, 0x0d, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96,
-- 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x80, 0x80, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x99, 0x09, 0x00,
-- 0x00, 0xc9, 0xff, 0xd8, 0xff, 0x00, 0x00, 0x00, 0x01, 0x10, 0x01,
-- 0x10, 0x01, 0x10, 0x01, 0x10, 0x01, 0xf0, 0x00, 0xf0, 0x00, 0xf0,
-- 0x00, 0xf0, 0x00, 0xd0, 0x00, 0xd0, 0x00, 0xd0, 0x00, 0xd0, 0x00,
-- 0x54, 0x01, 0xab, 0xf6, 0xc0, 0x42, 0xc0, 0x42, 0xc0, 0x42, 0xc0,
-- 0x42, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb,
-- 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x22, 0x01, 0x37, 0xa9, 0xc0,
-- 0x33, 0xc0, 0x33, 0xc0, 0x33, 0xc0, 0x33, 0x00, 0xbc, 0x00, 0xbc,
-- 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00,
-- 0xbc, 0xfb, 0x00, 0xca, 0x79, 0xc0, 0x2b, 0xc0, 0x2b, 0xc0, 0x2b,
-- 0xc0, 0x2b, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00,
-- 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0xd0, 0x00, 0x5d, 0x54,
-- 0xc0, 0x21, 0xc0, 0x21, 0xc0, 0x21, 0xc0, 0x21, 0x00, 0xaa, 0x00,
-- 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa,
-- 0x00, 0xaa, 0xa7, 0x00, 0xa9, 0x3d, 0xc0, 0x17, 0xc0, 0x17, 0xc0,
-- 0x17, 0xc0, 0x17, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0,
-- 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x7a, 0x00, 0x06,
-- 0x2c, 0xc0, 0x0d, 0xc0, 0x0d, 0xc0, 0x0d, 0xc0, 0x0d, 0x00, 0x96,
-- 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00,
-- 0x96, 0x00, 0x96, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x06, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x9e, 0x09, 0x00, 0x00, 0xc9, 0xff, 0xd8, 0xff,
-- 0x00, 0x00, 0x00, 0x01, 0x10, 0x01, 0x10, 0x01, 0x10, 0x01, 0x10,
-- 0x01, 0xf0, 0x00, 0xf0, 0x00, 0xf0, 0x00, 0xf0, 0x00, 0xd0, 0x00,
-- 0xd0, 0x00, 0xd0, 0x00, 0xd0, 0x00, 0x54, 0x01, 0xab, 0xf6, 0xc0,
-- 0x42, 0xc0, 0x42, 0xc0, 0x42, 0xc0, 0x42, 0x00, 0xcb, 0x00, 0xcb,
-- 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00, 0xcb, 0x00,
-- 0xcb, 0x22, 0x01, 0x37, 0xa9, 0xc0, 0x33, 0xc0, 0x33, 0xc0, 0x33,
-- 0xc0, 0x33, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00,
-- 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0x00, 0xbc, 0xfb, 0x00, 0xca, 0x79,
-- 0xc0, 0x2b, 0xc0, 0x2b, 0xc0, 0x2b, 0xc0, 0x2b, 0x00, 0xb4, 0x00,
-- 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4, 0x00, 0xb4,
-- 0x00, 0xb4, 0xd0, 0x00, 0x5d, 0x54, 0xc0, 0x21, 0xc0, 0x21, 0xc0,
-- 0x21, 0xc0, 0x21, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa,
-- 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0x00, 0xaa, 0xa7, 0x00, 0xa9,
-- 0x3d, 0xc0, 0x17, 0xc0, 0x17, 0xc0, 0x17, 0xc0, 0x17, 0x00, 0xa0,
-- 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00, 0xa0, 0x00,
-- 0xa0, 0x00, 0xa0, 0x7a, 0x00, 0x06, 0x2c, 0xc0, 0x0d, 0xc0, 0x0d,
-- 0xc0, 0x0d, 0xc0, 0x0d, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00,
-- 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x96, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x80, 0x80, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00 };
--
--static const u8 default_cal_rssi[] = {
-- 0x0a, 0x01, 0x72, 0xfe, 0x1a, 0x00, 0x00, 0x00, 0x0a, 0x01, 0x72,
-- 0xfe, 0x1a, 0x00, 0x00, 0x00, 0x0a, 0x01, 0x72, 0xfe, 0x1a, 0x00,
-- 0x00, 0x00, 0x0a, 0x01, 0x72, 0xfe, 0x1a, 0x00, 0x00, 0x00, 0x0a,
-- 0x01, 0x72, 0xfe, 0x1a, 0x00, 0x00, 0x00, 0x0a, 0x01, 0x72, 0xfe,
-- 0x1a, 0x00, 0x00, 0x00, 0x0a, 0x01, 0x72, 0xfe, 0x1a, 0x00, 0x00,
-- 0x00, 0x0a, 0x01, 0x72, 0xfe, 0x1a, 0x00, 0x00, 0x00, 0x0a, 0x01,
-- 0x72, 0xfe, 0x1a, 0x00, 0x00, 0x00, 0x0a, 0x01, 0x72, 0xfe, 0x1a,
-- 0x00, 0x00, 0x00, 0x0a, 0x01, 0x72, 0xfe, 0x1a, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-- 0x00, 0x00, 0x00, 0x00, 0x00 };
--
--static void stlc45xx_tx_edcf(struct stlc45xx *stlc);
--static void stlc45xx_tx_setup(struct stlc45xx *stlc);
--static void stlc45xx_tx_scan(struct stlc45xx *stlc);
--static void stlc45xx_tx_psm(struct stlc45xx *stlc, bool enable);
--static int stlc45xx_tx_nullfunc(struct stlc45xx *stlc, bool powersave);
--static int stlc45xx_tx_pspoll(struct stlc45xx *stlc, bool powersave);
--
--static ssize_t stlc45xx_sysfs_show_cal_rssi(struct device *dev,
-- struct device_attribute *attr,
-- char *buf)
--{
-- struct stlc45xx *stlc = dev_get_drvdata(dev);
-- ssize_t len;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- len = PAGE_SIZE;
--
-- mutex_lock(&stlc->mutex);
--
-- if (stlc->cal_rssi)
-- hex_dump_to_buffer(stlc->cal_rssi, RSSI_CAL_ARRAY_LEN, 16,
-- 2, buf, len, 0);
-- mutex_unlock(&stlc->mutex);
--
-- len = strlen(buf);
--
-- return len;
--}
--
--static ssize_t stlc45xx_sysfs_store_cal_rssi(struct device *dev,
-- struct device_attribute *attr,
-- const char *buf, size_t count)
--{
-- struct stlc45xx *stlc = dev_get_drvdata(dev);
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- mutex_lock(&stlc->mutex);
--
-- if (count != RSSI_CAL_ARRAY_LEN) {
-- stlc45xx_error("invalid cal_rssi length: %zu", count);
-- count = 0;
-- goto out_unlock;
-- }
--
-- kfree(stlc->cal_rssi);
--
-- stlc->cal_rssi = kmemdup(buf, RSSI_CAL_ARRAY_LEN, GFP_KERNEL);
--
-- if (!stlc->cal_rssi) {
-- stlc45xx_error("failed to allocate memory for cal_rssi");
-- count = 0;
-- goto out_unlock;
-- }
--
-- out_unlock:
-- mutex_unlock(&stlc->mutex);
--
-- return count;
--}
--
--static ssize_t stlc45xx_sysfs_show_cal_channels(struct device *dev,
-- struct device_attribute *attr,
-- char *buf)
--{
-- struct stlc45xx *stlc = dev_get_drvdata(dev);
-- ssize_t len;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- len = PAGE_SIZE;
--
-- mutex_lock(&stlc->mutex);
--
-- if (stlc->cal_channels)
-- hex_dump_to_buffer(stlc->cal_channels, CHANNEL_CAL_ARRAY_LEN,
-- 16, 2, buf, len, 0);
--
-- mutex_unlock(&stlc->mutex);
--
-- len = strlen(buf);
--
-- return len;
--}
--
--static ssize_t stlc45xx_sysfs_store_cal_channels(struct device *dev,
-- struct device_attribute *attr,
-- const char *buf, size_t count)
--{
-- struct stlc45xx *stlc = dev_get_drvdata(dev);
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- mutex_lock(&stlc->mutex);
--
-- if (count != CHANNEL_CAL_ARRAY_LEN) {
-- stlc45xx_error("invalid cal_channels size: %zu ", count);
-- count = 0;
-- goto out_unlock;
-- }
--
-- kfree(stlc->cal_channels);
--
-- stlc->cal_channels = kmemdup(buf, count, GFP_KERNEL);
--
-- if (!stlc->cal_channels) {
-- stlc45xx_error("failed to allocate memory for cal_channels");
-- count = 0;
-- goto out_unlock;
-- }
--
--out_unlock:
-- mutex_unlock(&stlc->mutex);
--
-- return count;
--}
--
--static ssize_t stlc45xx_sysfs_show_tx_buf(struct device *dev,
-- struct device_attribute *attr,
-- char *buf)
--{
-- struct stlc45xx *stlc = dev_get_drvdata(dev);
-- struct txbuffer *entry;
-- ssize_t len = 0;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s()", __func__);
--
-- mutex_lock(&stlc->mutex);
--
-- list_for_each_entry(entry, &stlc->tx_sent, tx_list) {
-- len += sprintf(buf + len, "0x%x: 0x%x-0x%x\n",
-- entry->handle, entry->start,
-- entry->end);
-- }
--
-- mutex_unlock(&stlc->mutex);
--
-- return len;
--}
--
--static DEVICE_ATTR(cal_rssi, S_IRUGO | S_IWUSR,
-- stlc45xx_sysfs_show_cal_rssi,
-- stlc45xx_sysfs_store_cal_rssi);
--static DEVICE_ATTR(cal_channels, S_IRUGO | S_IWUSR,
-- stlc45xx_sysfs_show_cal_channels,
-- stlc45xx_sysfs_store_cal_channels);
--static DEVICE_ATTR(tx_buf, S_IRUGO, stlc45xx_sysfs_show_tx_buf, NULL);
--
--static void stlc45xx_spi_read(struct stlc45xx *stlc, unsigned long addr,
-- void *buf, size_t len)
--{
-- struct spi_transfer t[2];
-- struct spi_message m;
--
-- /* We first push the address */
-- addr = (addr << 8) | ADDR_READ_BIT_15;
--
-- spi_message_init(&m);
-- memset(t, 0, sizeof(t));
--
-- t[0].tx_buf = &addr;
-- t[0].len = 2;
-- spi_message_add_tail(&t[0], &m);
--
-- t[1].rx_buf = buf;
-- t[1].len = len;
-- spi_message_add_tail(&t[1], &m);
--
-- spi_sync(stlc->spi, &m);
--}
--
--
--static void stlc45xx_spi_write(struct stlc45xx *stlc, unsigned long addr,
-- void *buf, size_t len)
--{
-- struct spi_transfer t[3];
-- struct spi_message m;
-- u16 last_word;
--
-- /* We first push the address */
-- addr = addr << 8;
--
-- spi_message_init(&m);
-- memset(t, 0, sizeof(t));
--
-- t[0].tx_buf = &addr;
-- t[0].len = 2;
-- spi_message_add_tail(&t[0], &m);
--
-- t[1].tx_buf = buf;
-- t[1].len = len;
-- spi_message_add_tail(&t[1], &m);
--
-- if (len % 2) {
-- last_word = ((u8 *)buf)[len - 1];
--
-- t[2].tx_buf = &last_word;
-- t[2].len = 2;
-- spi_message_add_tail(&t[2], &m);
-- }
--
-- spi_sync(stlc->spi, &m);
--}
--
--static u16 stlc45xx_read16(struct stlc45xx *stlc, unsigned long addr)
--{
-- u16 val;
--
-- stlc45xx_spi_read(stlc, addr, &val, sizeof(val));
--
-- return val;
--}
--
--static u32 stlc45xx_read32(struct stlc45xx *stlc, unsigned long addr)
--{
-- u32 val;
--
-- stlc45xx_spi_read(stlc, addr, &val, sizeof(val));
--
-- return val;
--}
--
--static void stlc45xx_write16(struct stlc45xx *stlc, unsigned long addr, u16 val)
--{
-- stlc45xx_spi_write(stlc, addr, &val, sizeof(val));
--}
--
--static void stlc45xx_write32(struct stlc45xx *stlc, unsigned long addr, u32 val)
--{
-- stlc45xx_spi_write(stlc, addr, &val, sizeof(val));
--}
--
--struct stlc45xx_spi_reg {
-- u16 address;
-- u16 length;
-- char *name;
--};
--
--/* caller must hold tx_lock */
--static void stlc45xx_txbuffer_dump(struct stlc45xx *stlc)
--{
-- struct txbuffer *txbuffer;
-- char *buf, *pos;
-- int buf_len, l, count;
--
-- if (!(DEBUG_LEVEL & DEBUG_TXBUFFER))
-- return;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s()", __func__);
--
-- buf_len = 500;
-- buf = kmalloc(buf_len, GFP_ATOMIC);
-- if (!buf)
-- return;
--
-- pos = buf;
-- count = 0;
--
-- list_for_each_entry(txbuffer, &stlc->txbuffer, buffer_list) {
-- l = snprintf(pos, buf_len, "0x%x-0x%x,",
-- txbuffer->start, txbuffer->end);
-- /* drop the null byte */
-- pos += l;
-- buf_len -= l;
-- count++;
-- }
--
-- if (count == 0)
-- *pos = '\0';
-- else
-- *--pos = '\0';
--
-- stlc45xx_debug(DEBUG_TXBUFFER, "txbuffer: in buffer %d regions: %s",
-- count, buf);
--
-- kfree(buf);
--}
--
--/* caller must hold tx_lock */
--static int stlc45xx_txbuffer_find(struct stlc45xx *stlc, size_t len)
--{
-- struct txbuffer *txbuffer;
-- int pos;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s()", __func__);
--
-- pos = FIRMWARE_TXBUFFER_START;
--
-- if (list_empty(&stlc->txbuffer))
-- goto out;
--
-- /*
-- * the entries in txbuffer must be in the same order as they are in
-- * the real buffer
-- */
-- list_for_each_entry(txbuffer, &stlc->txbuffer, buffer_list) {
-- if (pos + len < txbuffer->start)
-- break;
-- pos = ALIGN(txbuffer->end + 1, 4);
-- }
--
-- if (pos + len > FIRMWARE_TXBUFFER_END)
-- /* not enough room */
-- pos = -1;
--
-- stlc45xx_debug(DEBUG_TXBUFFER, "txbuffer: find %zu B: 0x%x", len, pos);
--
--out:
-- return pos;
--}
--
--static int stlc45xx_txbuffer_add(struct stlc45xx *stlc,
-- struct txbuffer *txbuffer)
--{
-- struct txbuffer *r, *prev = NULL;
--
-- if (list_empty(&stlc->txbuffer)) {
-- list_add(&txbuffer->buffer_list, &stlc->txbuffer);
-- return 0;
-- }
--
-- r = list_first_entry(&stlc->txbuffer, struct txbuffer, buffer_list);
--
-- if (txbuffer->start < r->start) {
-- /* add to the beginning of the list */
-- list_add(&txbuffer->buffer_list, &stlc->txbuffer);
-- return 0;
-- }
--
-- prev = NULL;
-- list_for_each_entry(r, &stlc->txbuffer, buffer_list) {
-- /* skip first entry, we checked for that above */
-- if (!prev) {
-- prev = r;
-- continue;
-- }
--
-- /* double-check overlaps */
-- WARN_ON_ONCE(txbuffer->start >= r->start &&
-- txbuffer->start <= r->end);
-- WARN_ON_ONCE(txbuffer->end >= r->start &&
-- txbuffer->end <= r->end);
--
-- if (prev->end < txbuffer->start &&
-- txbuffer->end < r->start) {
-- /* insert at this spot */
-- list_add_tail(&txbuffer->buffer_list, &r->buffer_list);
-- return 0;
-- }
--
-- prev = r;
-- }
--
-- /* not found */
-- list_add_tail(&txbuffer->buffer_list, &stlc->txbuffer);
--
-- return 0;
--
--}
--
--/* caller must hold tx_lock */
--static struct txbuffer *stlc45xx_txbuffer_alloc(struct stlc45xx *stlc,
-- size_t frame_len)
--{
-- struct txbuffer *entry = NULL;
-- size_t len;
-- int pos;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s()", __func__);
--
-- len = FIRMWARE_TXBUFFER_HEADER + frame_len + FIRMWARE_TXBUFFER_TRAILER;
-- pos = stlc45xx_txbuffer_find(stlc, len);
--
-- if (pos < 0)
-- return NULL;
--
-- WARN_ON_ONCE(pos + len > FIRMWARE_TXBUFFER_END);
-- WARN_ON_ONCE(pos < FIRMWARE_TXBUFFER_START);
--
-- entry = kmalloc(sizeof(*entry), GFP_ATOMIC);
-- entry->start = pos;
-- entry->frame_start = pos + FIRMWARE_TXBUFFER_HEADER;
-- entry->end = entry->start + len - 1;
--
-- stlc45xx_debug(DEBUG_TXBUFFER, "txbuffer: allocated 0x%x-0x%x",
-- entry->start, entry->end);
--
-- stlc45xx_txbuffer_add(stlc, entry);
--
-- stlc45xx_txbuffer_dump(stlc);
--
-- return entry;
--}
--
--/* caller must hold tx_lock */
--static void stlc45xx_txbuffer_free(struct stlc45xx *stlc,
-- struct txbuffer *txbuffer)
--{
-- stlc45xx_debug(DEBUG_FUNC, "%s()", __func__);
--
-- stlc45xx_debug(DEBUG_TXBUFFER, "txbuffer: freed 0x%x-0x%x",
-- txbuffer->start, txbuffer->end);
--
-- list_del(&txbuffer->buffer_list);
-- kfree(txbuffer);
--}
--
--
--static int stlc45xx_wait_bit(struct stlc45xx *stlc, u16 reg, u32 mask,
-- u32 expected)
--{
-- int i;
-- char buffer[4];
--
-- for (i = 0; i < 2000; i++) {
-- stlc45xx_spi_read(stlc, reg, buffer, sizeof(buffer));
-- if (((*(u32 *)buffer) & mask) == expected)
-- return 1;
-- msleep(1);
-- }
--
-- return 0;
--}
--
--static int stlc45xx_request_firmware(struct stlc45xx *stlc)
--{
-- const struct firmware *fw;
-- int ret;
--
-- /* FIXME: should driver use it's own struct device? */
-- ret = request_firmware(&fw, "3826.arm", &stlc->spi->dev);
--
-- if (ret < 0) {
-- stlc45xx_error("request_firmware() failed: %d", ret);
-- return ret;
-- }
--
-- if (fw->size % 4) {
-- stlc45xx_error("firmware size is not multiple of 32bit: %zu",
-- fw->size);
-- return -EILSEQ; /* Illegal byte sequence */;
-- }
--
-- if (fw->size < 1000) {
-- stlc45xx_error("firmware is too small: %zu", fw->size);
-- return -EILSEQ;
-- }
--
-- stlc->fw = kmemdup(fw->data, fw->size, GFP_KERNEL);
-- if (!stlc->fw) {
-- stlc45xx_error("could not allocate memory for firmware");
-- return -ENOMEM;
-- }
--
-- stlc->fw_len = fw->size;
--
-- release_firmware(fw);
--
-- return 0;
--}
--
--static int stlc45xx_upload_firmware(struct stlc45xx *stlc)
--{
-- struct s_dma_regs dma_regs;
-- unsigned long fw_len, fw_addr;
-- long _fw_len;
-- int ret;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- if (!stlc->fw) {
-- ret = stlc45xx_request_firmware(stlc);
-- if (ret < 0)
-- return ret;
-- }
--
-- /* stop the device */
-- stlc45xx_write16(stlc, SPI_ADRS_DEV_CTRL_STAT,
-- SPI_CTRL_STAT_HOST_OVERRIDE | SPI_CTRL_STAT_HOST_RESET
-- | SPI_CTRL_STAT_START_HALTED);
--
-- msleep(TARGET_BOOT_SLEEP);
--
-- stlc45xx_write16(stlc, SPI_ADRS_DEV_CTRL_STAT,
-- SPI_CTRL_STAT_HOST_OVERRIDE
-- | SPI_CTRL_STAT_START_HALTED);
--
-- msleep(TARGET_BOOT_SLEEP);
--
-- fw_addr = FIRMWARE_ADDRESS;
-- fw_len = stlc->fw_len;
--
-- while (fw_len > 0) {
-- _fw_len = (fw_len > SPI_MAX_PACKET_SIZE)
-- ? SPI_MAX_PACKET_SIZE : fw_len;
-- dma_regs.cmd = SPI_DMA_WRITE_CTRL_ENABLE;
-- dma_regs.len = cpu_to_le16(_fw_len);
-- dma_regs.addr = cpu_to_le32(fw_addr);
--
-- fw_len -= _fw_len;
-- fw_addr += _fw_len;
--
-- stlc45xx_write16(stlc, SPI_ADRS_DMA_WRITE_CTRL, dma_regs.cmd);
--
-- if (stlc45xx_wait_bit(stlc, SPI_ADRS_DMA_WRITE_CTRL,
-- HOST_ALLOWED, HOST_ALLOWED) == 0) {
-- stlc45xx_error("fw_upload not allowed to DMA write");
-- return -EAGAIN;
-- }
--
-- stlc45xx_write16(stlc, SPI_ADRS_DMA_WRITE_LEN, dma_regs.len);
-- stlc45xx_write32(stlc, SPI_ADRS_DMA_WRITE_BASE, dma_regs.addr);
--
-- stlc45xx_spi_write(stlc, SPI_ADRS_DMA_DATA, stlc->fw, _fw_len);
--
-- /* FIXME: I think this doesn't work if firmware is large,
-- * this loop goes to second round. fw->data is not
-- * increased at all! */
-- }
--
-- BUG_ON(fw_len != 0);
--
-- /* enable host interrupts */
-- stlc45xx_write32(stlc, SPI_ADRS_HOST_INT_EN, SPI_HOST_INTS_DEFAULT);
--
-- /* boot the device */
-- stlc45xx_write16(stlc, SPI_ADRS_DEV_CTRL_STAT,
-- SPI_CTRL_STAT_HOST_OVERRIDE | SPI_CTRL_STAT_HOST_RESET
-- | SPI_CTRL_STAT_RAM_BOOT);
--
-- msleep(TARGET_BOOT_SLEEP);
--
-- stlc45xx_write16(stlc, SPI_ADRS_DEV_CTRL_STAT,
-- SPI_CTRL_STAT_HOST_OVERRIDE | SPI_CTRL_STAT_RAM_BOOT);
-- msleep(TARGET_BOOT_SLEEP);
--
-- return 0;
--}
--
--/* caller must hold tx_lock */
--static void stlc45xx_check_txsent(struct stlc45xx *stlc)
--{
-- struct txbuffer *entry, *n;
--
-- list_for_each_entry_safe(entry, n, &stlc->tx_sent, tx_list) {
-- if (time_after(jiffies, entry->lifetime)) {
-- if (net_ratelimit())
-- stlc45xx_warning("frame 0x%x lifetime exceeded",
-- entry->start);
-- list_del(&entry->tx_list);
-- skb_pull(entry->skb, entry->header_len);
-- ieee80211_tx_status(stlc->hw, entry->skb);
-- stlc45xx_txbuffer_free(stlc, entry);
-- }
-- }
--}
--
--static void stlc45xx_power_off(struct stlc45xx *stlc)
--{
-- disable_irq(gpio_to_irq(stlc45xx_gpio_irq));
-- gpio_set_value(stlc45xx_gpio_power, 0);
--}
--
--static void stlc45xx_power_on(struct stlc45xx *stlc)
--{
-- gpio_set_value(stlc45xx_gpio_power, 1);
-- enable_irq(gpio_to_irq(stlc45xx_gpio_irq));
--
-- /*
-- * need to wait a while before device can be accessed, the length
-- * is just a guess
-- */
-- msleep(10);
--}
--
--/* caller must hold tx_lock */
--static void stlc45xx_flush_queues(struct stlc45xx *stlc)
--{
-- struct txbuffer *entry;
--
-- while (!list_empty(&stlc->tx_sent)) {
-- entry = list_first_entry(&stlc->tx_sent,
-- struct txbuffer, tx_list);
-- list_del(&entry->tx_list);
-- dev_kfree_skb(entry->skb);
-- stlc45xx_txbuffer_free(stlc, entry);
-- }
--
-- WARN_ON(!list_empty(&stlc->tx_sent));
--
-- while (!list_empty(&stlc->tx_pending)) {
-- entry = list_first_entry(&stlc->tx_pending,
-- struct txbuffer, tx_list);
-- list_del(&entry->tx_list);
-- dev_kfree_skb(entry->skb);
-- stlc45xx_txbuffer_free(stlc, entry);
-- }
--
-- WARN_ON(!list_empty(&stlc->tx_pending));
-- WARN_ON(!list_empty(&stlc->txbuffer));
--}
--
--static void stlc45xx_work_reset(struct work_struct *work)
--{
-- struct stlc45xx *stlc = container_of(work, struct stlc45xx,
-- work_reset);
--
-- mutex_lock(&stlc->mutex);
--
-- if (stlc->fw_state != FW_STATE_RESET)
-- goto out;
--
-- stlc45xx_power_off(stlc);
--
-- mutex_unlock(&stlc->mutex);
--
-- /* wait that all work_structs have finished, we can't hold
-- * stlc->mutex to avoid deadlock */
-- cancel_work_sync(&stlc->work);
--
-- /* FIXME: find out good value to wait for chip power down */
-- msleep(100);
--
-- mutex_lock(&stlc->mutex);
--
-- /* FIXME: we should gracefully handle if the state has changed
-- * after re-acquiring mutex */
-- WARN_ON(stlc->fw_state != FW_STATE_RESET);
--
-- spin_lock_bh(&stlc->tx_lock);
-- stlc45xx_flush_queues(stlc);
-- spin_unlock_bh(&stlc->tx_lock);
--
-- stlc->fw_state = FW_STATE_RESETTING;
--
-- stlc45xx_power_on(stlc);
-- stlc45xx_upload_firmware(stlc);
--
--out:
-- mutex_unlock(&stlc->mutex);
--}
--
--/* caller must hold mutex */
--static void stlc45xx_reset(struct stlc45xx *stlc)
--{
-- stlc45xx_warning("resetting firmware");
-- stlc->fw_state = FW_STATE_RESET;
-- ieee80211_stop_queues(stlc->hw);
-- queue_work(stlc->hw->workqueue, &stlc->work_reset);
--}
--
--static void stlc45xx_work_tx_timeout(struct work_struct *work)
--{
-- struct stlc45xx *stlc = container_of(work, struct stlc45xx,
-- work_tx_timeout.work);
--
-- stlc45xx_warning("tx timeout");
--
-- mutex_lock(&stlc->mutex);
--
-- if (stlc->fw_state != FW_STATE_READY)
-- goto out;
--
-- stlc45xx_reset(stlc);
--
--out:
-- mutex_unlock(&stlc->mutex);
--}
--
--static void stlc45xx_int_ack(struct stlc45xx *stlc, u32 val)
--{
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- stlc45xx_write32(stlc, SPI_ADRS_HOST_INT_ACK, val);
--}
--
--static void stlc45xx_wakeup(struct stlc45xx *stlc)
--{
-- unsigned long timeout;
-- u32 ints;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- /* wake the chip */
-- stlc45xx_write32(stlc, SPI_ADRS_ARM_INTERRUPTS, SPI_TARGET_INT_WAKEUP);
--
-- /* And wait for the READY interrupt */
-- timeout = jiffies + HZ;
--
-- ints = stlc45xx_read32(stlc, SPI_ADRS_HOST_INTERRUPTS);
-- while (!(ints & SPI_HOST_INT_READY)) {
-- if (time_after(jiffies, timeout))
-- goto out;
-- ints = stlc45xx_read32(stlc, SPI_ADRS_HOST_INTERRUPTS);
-- }
--
-- stlc45xx_int_ack(stlc, SPI_HOST_INT_READY);
--
--out:
-- return;
--}
--
--static void stlc45xx_sleep(struct stlc45xx *stlc)
--{
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- stlc45xx_write32(stlc, SPI_ADRS_ARM_INTERRUPTS, SPI_TARGET_INT_SLEEP);
--}
--
--static void stlc45xx_int_ready(struct stlc45xx *stlc)
--{
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- stlc45xx_write32(stlc, SPI_ADRS_HOST_INT_EN,
-- SPI_HOST_INT_UPDATE | SPI_HOST_INT_SW_UPDATE);
--
-- switch (stlc->fw_state) {
-- case FW_STATE_BOOTING:
-- stlc->fw_state = FW_STATE_READY;
-- complete(&stlc->fw_comp);
-- break;
-- case FW_STATE_RESETTING:
-- stlc->fw_state = FW_STATE_READY;
--
-- stlc45xx_tx_scan(stlc);
-- stlc45xx_tx_setup(stlc);
-- stlc45xx_tx_edcf(stlc);
--
-- ieee80211_wake_queues(stlc->hw);
-- break;
-- default:
-- break;
-- }
--}
--
--static int stlc45xx_rx_txack(struct stlc45xx *stlc, struct sk_buff *skb)
--{
-- struct ieee80211_tx_info *info;
-- struct s_lm_control *control;
-- struct s_lmo_tx *tx;
-- struct txbuffer *entry;
-- int found = 0;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- control = (struct s_lm_control *) skb->data;
-- tx = (struct s_lmo_tx *) (control + 1);
--
-- if (list_empty(&stlc->tx_sent)) {
-- if (net_ratelimit())
-- stlc45xx_warning("no frames waiting for "
-- "acknowledgement");
-- return -1;
-- }
--
-- list_for_each_entry(entry, &stlc->tx_sent, tx_list) {
-- if (control->handle == entry->handle) {
-- found = 1;
-- break;
-- }
-- }
--
-- if (!found) {
-- if (net_ratelimit())
-- stlc45xx_warning("couldn't find frame for tx ack 0x%x",
-- control->handle);
-- return -1;
-- }
--
-- stlc45xx_debug(DEBUG_TX, "TX ACK 0x%x", entry->handle);
--
-- if (entry->status_needed) {
-- info = IEEE80211_SKB_CB(entry->skb);
--
-- if (!(tx->flags & LM_TX_FAILED)) {
-- /* frame was acked */
-- info->flags |= IEEE80211_TX_STAT_ACK;
-- info->status.ack_signal = tx->rcpi / 2 - 110;
-- }
--
-- skb_pull(entry->skb, entry->header_len);
--
-- ieee80211_tx_status(stlc->hw, entry->skb);
-- }
--
-- list_del(&entry->tx_list);
--
-- stlc45xx_check_txsent(stlc);
-- if (list_empty(&stlc->tx_sent))
-- /* there are no pending frames, we can stop the tx timeout
-- * timer */
-- cancel_delayed_work(&stlc->work_tx_timeout);
--
-- spin_lock_bh(&stlc->tx_lock);
--
-- stlc45xx_txbuffer_free(stlc, entry);
--
-- if (stlc->tx_queue_stopped &&
-- stlc45xx_txbuffer_find(stlc, MAX_FRAME_LEN) != -1) {
-- stlc45xx_debug(DEBUG_QUEUE, "room in tx buffer, waking queues");
-- ieee80211_wake_queues(stlc->hw);
-- stlc->tx_queue_stopped = 0;
-- }
--
-- spin_unlock_bh(&stlc->tx_lock);
--
-- return 0;
--}
--
--static int stlc45xx_rx_control(struct stlc45xx *stlc, struct sk_buff *skb)
--{
-- struct s_lm_control *control;
-- int ret = 0;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- control = (struct s_lm_control *) skb->data;
--
-- switch (control->oid) {
-- case LM_OID_TX:
-- ret = stlc45xx_rx_txack(stlc, skb);
-- break;
-- case LM_OID_SETUP:
-- case LM_OID_SCAN:
-- case LM_OID_TRAP:
-- case LM_OID_EDCF:
-- case LM_OID_KEYCACHE:
-- case LM_OID_PSM:
-- case LM_OID_STATS:
-- case LM_OID_LED:
-- default:
-- stlc45xx_warning("unhandled rx control oid %d\n",
-- control->oid);
-- break;
-- }
--
-- dev_kfree_skb(skb);
--
-- return ret;
--}
--
--/* copied from mac80211 */
--static void stlc45xx_parse_elems(u8 *start, size_t len,
-- struct stlc45xx_ie_tim **tim,
-- size_t *tim_len)
--{
-- size_t left = len;
-- u8 *pos = start;
--
-- while (left >= 2) {
-- u8 id, elen;
--
-- id = *pos++;
-- elen = *pos++;
-- left -= 2;
--
-- if (elen > left)
-- return;
--
-- switch (id) {
-- case WLAN_EID_TIM:
-- *tim = (struct stlc45xx_ie_tim *) pos;
-- *tim_len = elen;
-- break;
-- default:
-- break;
-- }
--
-- left -= elen;
-- pos += elen;
-- }
--}
--
--/*
-- * mac80211 doesn't have support for asking frames with PS-Poll, so let's
-- * implement in the driver for now. We have to add support to mac80211
-- * later.
-- */
--static int stlc45xx_check_more_data(struct stlc45xx *stlc, struct sk_buff *skb)
--{
-- struct s_lm_data_in *data = (struct s_lm_data_in *) skb->data;
-- struct ieee80211_hdr *hdr;
-- size_t len;
-- u16 fc;
--
-- hdr = (void *) skb->data + sizeof(*data);
-- len = skb->len - sizeof(*data);
--
-- /* minimum frame length is the null frame length 24 bytes */
-- if (len < 24) {
-- stlc45xx_warning("invalid frame length when checking for "
-- "more data");
-- return -EINVAL;
-- }
--
-- fc = le16_to_cpu(hdr->frame_control);
-- if (!(fc & IEEE80211_FCTL_FROMDS))
-- /* this is not from DS */
-- return 0;
--
-- if (compare_ether_addr(hdr->addr1, stlc->mac_addr) != 0)
-- /* the frame was not for us */
-- return 0;
--
-- if (!(fc & IEEE80211_FCTL_MOREDATA)) {
-- /* AP has no more frames buffered for us */
-- stlc45xx_debug(DEBUG_PSM, "all buffered frames retrieved");
-- stlc->pspolling = false;
-- return 0;
-- }
--
-- /* MOREDATA bit is set, let's ask for a new frame from the AP */
-- stlc45xx_tx_pspoll(stlc, stlc->psm);
--
-- return 0;
--}
--
--/*
-- * mac80211 cannot read TIM from beacons, so let's add a hack to the
-- * driver. We have to add support to mac80211 later.
-- */
--static int stlc45xx_rx_data_beacon(struct stlc45xx *stlc, struct sk_buff *skb)
--{
-- struct s_lm_data_in *data = (struct s_lm_data_in *) skb->data;
-- size_t len = skb->len, tim_len = 0, baselen, pvbmap_len;
-- struct ieee80211_mgmt *mgmt;
-- struct stlc45xx_ie_tim *tim = NULL;
-- int bmap_offset, index, aid_bit;
--
-- mgmt = (void *) skb->data + sizeof(*data);
--
-- baselen = (u8 *) mgmt->u.beacon.variable - (u8 *) mgmt;
-- if (baselen > len) {
-- stlc45xx_warning("invalid baselen in beacon");
-- return -EINVAL;
-- }
--
-- stlc45xx_parse_elems(mgmt->u.beacon.variable, len - baselen, &tim,
-- &tim_len);
--
-- if (!tim) {
-- stlc45xx_warning("didn't find tim from a beacon");
-- return -EINVAL;
-- }
--
-- bmap_offset = tim->bmap_control & 0xfe;
-- index = stlc->aid / 8 - bmap_offset;
--
-- pvbmap_len = tim_len - 3;
-- if (index > pvbmap_len)
-- return -EINVAL;
--
-- aid_bit = !!(tim->pvbmap[index] & (1 << stlc->aid % 8));
--
-- stlc45xx_debug(DEBUG_PSM, "fc 0x%x duration %d seq %d dtim %u "
-- "bmap_control 0x%x aid_bit %d",
-- mgmt->frame_control, mgmt->duration, mgmt->seq_ctrl >> 4,
-- tim->dtim_count, tim->bmap_control, aid_bit);
--
-- if (!aid_bit)
-- return 0;
--
-- stlc->pspolling = true;
-- stlc45xx_tx_pspoll(stlc, stlc->psm);
--
-- return 0;
--}
--
--static int stlc45xx_rx_data(struct stlc45xx *stlc, struct sk_buff *skb)
--{
-- struct ieee80211_rx_status status;
-- struct s_lm_data_in *data = (struct s_lm_data_in *) skb->data;
-- int align = 0;
-- u8 *p, align_len;
-- u16 len;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- if (stlc->psm) {
-- if (data->flags & LM_IN_BEACON)
-- stlc45xx_rx_data_beacon(stlc, skb);
-- else if (stlc->pspolling && (data->flags & LM_IN_DATA))
-- stlc45xx_check_more_data(stlc, skb);
-- }
--
-- memset(&status, 0, sizeof(status));
--
-- status.freq = data->frequency;
-- status.signal = data->rcpi / 2 - 110;
--
-- /* let's assume that maximum rcpi value is 140 (= 35 dBm) */
-- status.qual = data->rcpi * 100 / 140;
--
-- status.band = IEEE80211_BAND_2GHZ;
--
-- /*
-- * FIXME: this gives warning from __ieee80211_rx()
-- *
-- * status.rate_idx = data->rate;
-- */
--
-- len = data->length;
--
-- if (data->flags & LM_FLAG_ALIGN)
-- align = 1;
--
-- skb_pull(skb, sizeof(*data));
--
-- if (align) {
-- p = skb->data;
-- align_len = *p;
-- skb_pull(skb, align_len);
-- }
--
-- skb_trim(skb, len);
--
-- stlc45xx_debug(DEBUG_RX, "rx data 0x%p %d B", skb->data, skb->len);
-- stlc45xx_dump(DEBUG_RX_CONTENT, skb->data, skb->len);
--
-- memcpy(IEEE80211_SKB_RXCB(skb), &status, sizeof(status));
-- ieee80211_rx(stlc->hw, skb);
--
-- return 0;
--}
--
--
--
--static int stlc45xx_rx(struct stlc45xx *stlc)
--{
-- struct s_lm_control *control;
-- struct sk_buff *skb;
-- int ret;
-- u16 len;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- stlc45xx_wakeup(stlc);
--
-- /* dummy read to flush SPI DMA controller bug */
-- stlc45xx_read16(stlc, SPI_ADRS_GEN_PURP_1);
--
-- len = stlc45xx_read16(stlc, SPI_ADRS_DMA_DATA);
--
-- if (len == 0) {
-- stlc45xx_warning("rx request of zero bytes");
-- return 0;
-- }
--
-- skb = dev_alloc_skb(len);
-- if (!skb) {
-- stlc45xx_warning("could not alloc skb");
-- return 0;
-- }
--
-- stlc45xx_spi_read(stlc, SPI_ADRS_DMA_DATA, skb_put(skb, len), len);
--
-- stlc45xx_sleep(stlc);
--
-- stlc45xx_debug(DEBUG_RX, "rx frame 0x%p %d B", skb->data, skb->len);
-- stlc45xx_dump(DEBUG_RX_CONTENT, skb->data, skb->len);
--
-- control = (struct s_lm_control *) skb->data;
--
-- if (control->flags & LM_FLAG_CONTROL)
-- ret = stlc45xx_rx_control(stlc, skb);
-- else
-- ret = stlc45xx_rx_data(stlc, skb);
--
-- return ret;
--}
--
--
--static irqreturn_t stlc45xx_interrupt(int irq, void *config)
--{
-- struct spi_device *spi = config;
-- struct stlc45xx *stlc = dev_get_drvdata(&spi->dev);
--
-- stlc45xx_debug(DEBUG_IRQ, "IRQ");
--
-- queue_work(stlc->hw->workqueue, &stlc->work);
--
-- return IRQ_HANDLED;
--}
--
--static int stlc45xx_tx_frame(struct stlc45xx *stlc, u32 address,
-- void *buf, size_t len)
--{
-- struct s_dma_regs dma_regs;
-- unsigned long timeout;
-- int ret = 0;
-- u32 ints;
--
-- stlc->tx_frames++;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- stlc45xx_debug(DEBUG_TX, "tx frame 0x%p %zu B", buf, len);
-- stlc45xx_dump(DEBUG_TX_CONTENT, buf, len);
--
-- stlc45xx_wakeup(stlc);
--
-- dma_regs.cmd = SPI_DMA_WRITE_CTRL_ENABLE;
-- dma_regs.len = cpu_to_le16(len);
-- dma_regs.addr = cpu_to_le32(address);
--
-- stlc45xx_spi_write(stlc, SPI_ADRS_DMA_WRITE_CTRL, &dma_regs,
-- sizeof(dma_regs));
--
-- stlc45xx_spi_write(stlc, SPI_ADRS_DMA_DATA, buf, len);
--
-- timeout = jiffies + 2 * HZ;
-- ints = stlc45xx_read32(stlc, SPI_ADRS_HOST_INTERRUPTS);
-- while (!(ints & SPI_HOST_INT_WR_READY)) {
-- if (time_after(jiffies, timeout)) {
-- stlc45xx_warning("WR_READY timeout");
-- ret = -1;
-- goto out;
-- }
-- ints = stlc45xx_read32(stlc, SPI_ADRS_HOST_INTERRUPTS);
-- }
--
-- stlc45xx_int_ack(stlc, SPI_HOST_INT_WR_READY);
--
-- stlc45xx_sleep(stlc);
--
--out:
-- return ret;
--}
--
--static int stlc45xx_wq_tx(struct stlc45xx *stlc)
--{
-- struct txbuffer *entry;
-- int ret = 0;
--
-- spin_lock_bh(&stlc->tx_lock);
--
-- while (!list_empty(&stlc->tx_pending)) {
-- entry = list_entry(stlc->tx_pending.next,
-- struct txbuffer, tx_list);
--
-- list_del_init(&entry->tx_list);
--
-- spin_unlock_bh(&stlc->tx_lock);
--
-- ret = stlc45xx_tx_frame(stlc, entry->frame_start,
-- entry->skb->data, entry->skb->len);
--
-- spin_lock_bh(&stlc->tx_lock);
--
-- if (ret < 0) {
-- /* frame transfer to firmware buffer failed */
-- /* FIXME: report this to mac80211 */
-- dev_kfree_skb(entry->skb);
-- stlc45xx_txbuffer_free(stlc, entry);
-- goto out;
-- }
--
-- list_add(&entry->tx_list, &stlc->tx_sent);
-- queue_delayed_work(stlc->hw->workqueue,
-- &stlc->work_tx_timeout,
-- msecs_to_jiffies(TX_TIMEOUT));
-- }
--
--out:
-- spin_unlock_bh(&stlc->tx_lock);
-- return ret;
--}
--
--static void stlc45xx_work(struct work_struct *work)
--{
-- struct stlc45xx *stlc = container_of(work, struct stlc45xx, work);
-- u32 ints;
-- int ret;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- mutex_lock(&stlc->mutex);
--
-- if (stlc->fw_state == FW_STATE_OFF &&
-- stlc->fw_state == FW_STATE_RESET)
-- goto out;
--
-- ints = stlc45xx_read32(stlc, SPI_ADRS_HOST_INTERRUPTS);
-- stlc45xx_debug(DEBUG_BH, "begin host_ints 0x%08x", ints);
--
-- if (ints & SPI_HOST_INT_READY) {
-- stlc45xx_int_ready(stlc);
-- stlc45xx_int_ack(stlc, SPI_HOST_INT_READY);
-- }
--
-- if (stlc->fw_state != FW_STATE_READY)
-- goto out;
--
-- if (ints & SPI_HOST_INT_UPDATE) {
-- stlc45xx_int_ack(stlc, SPI_HOST_INT_UPDATE);
-- ret = stlc45xx_rx(stlc);
-- if (ret < 0) {
-- stlc45xx_reset(stlc);
-- goto out;
-- }
-- }
-- if (ints & SPI_HOST_INT_SW_UPDATE) {
-- stlc45xx_int_ack(stlc, SPI_HOST_INT_SW_UPDATE);
-- ret = stlc45xx_rx(stlc);
-- if (ret < 0) {
-- stlc45xx_reset(stlc);
-- goto out;
-- }
-- }
--
-- ret = stlc45xx_wq_tx(stlc);
-- if (ret < 0) {
-- stlc45xx_reset(stlc);
-- goto out;
-- }
--
-- ints = stlc45xx_read32(stlc, SPI_ADRS_HOST_INTERRUPTS);
-- stlc45xx_debug(DEBUG_BH, "end host_ints 0x%08x", ints);
--
--out:
-- mutex_unlock(&stlc->mutex);
--}
--
--static void stlc45xx_tx_edcf(struct stlc45xx *stlc)
--{
-- struct s_lm_control *control;
-- struct s_lmo_edcf *edcf;
-- size_t len, edcf_len;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- edcf_len = sizeof(*edcf);
-- len = sizeof(*control) + edcf_len;
-- control = kzalloc(len, GFP_KERNEL);
-- edcf = (struct s_lmo_edcf *) (control + 1);
--
-- control->flags = LM_FLAG_CONTROL | LM_CTRL_OPSET;
-- control->length = edcf_len;
-- control->oid = LM_OID_EDCF;
--
-- edcf->slottime = 0x14;
-- edcf->sifs = 10;
-- edcf->eofpad = 6;
-- edcf->maxburst = 1500;
--
-- edcf->queues[0].aifs = 2;
-- edcf->queues[0].pad0 = 1;
-- edcf->queues[0].cwmin = 3;
-- edcf->queues[0].cwmax = 7;
-- edcf->queues[0].txop = 47;
-- edcf->queues[1].aifs = 2;
-- edcf->queues[1].pad0 = 0;
-- edcf->queues[1].cwmin = 7;
-- edcf->queues[1].cwmax = 15;
-- edcf->queues[1].txop = 94;
-- edcf->queues[2].aifs = 3;
-- edcf->queues[2].pad0 = 0;
-- edcf->queues[2].cwmin = 15;
-- edcf->queues[2].cwmax = 1023;
-- edcf->queues[2].txop = 0;
-- edcf->queues[3].aifs = 7;
-- edcf->queues[3].pad0 = 0;
-- edcf->queues[3].cwmin = 15;
-- edcf->queues[3].cwmax = 1023;
-- edcf->queues[3].txop = 0;
-- edcf->queues[4].aifs = 13;
-- edcf->queues[4].pad0 = 99;
-- edcf->queues[4].cwmin = 3437;
-- edcf->queues[4].cwmax = 512;
-- edcf->queues[4].txop = 12;
-- edcf->queues[5].aifs = 142;
-- edcf->queues[5].pad0 = 109;
-- edcf->queues[5].cwmin = 8756;
-- edcf->queues[5].cwmax = 6;
-- edcf->queues[5].txop = 0;
-- edcf->queues[6].aifs = 4;
-- edcf->queues[6].pad0 = 0;
-- edcf->queues[6].cwmin = 0;
-- edcf->queues[6].cwmax = 58705;
-- edcf->queues[6].txop = 25716;
-- edcf->queues[7].aifs = 0;
-- edcf->queues[7].pad0 = 0;
-- edcf->queues[7].cwmin = 0;
-- edcf->queues[7].cwmax = 0;
-- edcf->queues[7].txop = 0;
--
-- stlc45xx_tx_frame(stlc, FIRMWARE_CONFIG_START, control, len);
--
-- kfree(control);
--}
--
--static void stlc45xx_tx_setup(struct stlc45xx *stlc)
--{
-- struct s_lm_control *control;
-- struct s_lmo_setup *setup;
-- size_t len, setup_len;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- setup_len = sizeof(*setup);
-- len = sizeof(*control) + setup_len;
-- control = kzalloc(len, GFP_KERNEL);
-- setup = (struct s_lmo_setup *) (control + 1);
--
-- control->flags = LM_FLAG_CONTROL | LM_CTRL_OPSET;
-- control->length = setup_len;
-- control->oid = LM_OID_SETUP;
--
-- setup->flags = LM_SETUP_INFRA;
-- setup->antenna = 2;
-- setup->rx_align = 0;
-- setup->rx_buffer = FIRMWARE_RXBUFFER_START;
-- setup->rx_mtu = FIRMWARE_MTU;
-- setup->frontend = 5;
-- setup->timeout = 0;
-- setup->truncate = 48896;
-- setup->bratemask = 0xffffffff;
-- setup->ref_clock = 644245094;
-- setup->lpf_bandwidth = 65535;
-- setup->osc_start_delay = 65535;
--
-- memcpy(setup->macaddr, stlc->mac_addr, ETH_ALEN);
-- memcpy(setup->bssid, stlc->bssid, ETH_ALEN);
--
-- stlc45xx_tx_frame(stlc, FIRMWARE_CONFIG_START, control, len);
--
-- kfree(control);
--}
--
--static void stlc45xx_tx_scan(struct stlc45xx *stlc)
--{
-- struct s_lm_control *control;
-- struct s_lmo_scan *scan;
-- size_t len, scan_len;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- scan_len = sizeof(*scan);
-- len = sizeof(*control) + scan_len;
-- control = kzalloc(len, GFP_KERNEL);
-- scan = (struct s_lmo_scan *) (control + 1);
--
-- control->flags = LM_FLAG_CONTROL | LM_CTRL_OPSET;
-- control->length = scan_len;
-- control->oid = LM_OID_SCAN;
--
-- scan->flags = LM_SCAN_EXIT;
-- scan->bratemask = 0x15f;
-- scan->aloft[0] = 3;
-- scan->aloft[1] = 3;
-- scan->aloft[2] = 1;
-- scan->aloft[3] = 0;
-- scan->aloft[4] = 0;
-- scan->aloft[5] = 0;
-- scan->aloft[6] = 0;
-- scan->aloft[7] = 0;
--
-- memcpy(&scan->rssical, &stlc->cal_rssi[(stlc->channel - 1) *
-- RSSI_CAL_LEN],
-- RSSI_CAL_LEN);
-- memcpy(&scan->channel, &stlc->cal_channels[(stlc->channel - 1) *
-- CHANNEL_CAL_LEN],
-- CHANNEL_CAL_LEN);
--
-- stlc45xx_tx_frame(stlc, FIRMWARE_CONFIG_START, control, len);
--
-- kfree(control);
--}
--
--/*
-- * caller must hold mutex
-- */
--static int stlc45xx_tx_pspoll(struct stlc45xx *stlc, bool powersave)
--{
-- struct ieee80211_hdr *pspoll;
-- int payload_len, padding, i;
-- struct s_lm_data_out *data;
-- struct txbuffer *entry;
-- struct sk_buff *skb;
-- char *payload;
-- u16 fc;
--
-- skb = dev_alloc_skb(stlc->hw->extra_tx_headroom + 16);
-- if (!skb) {
-- stlc45xx_warning("failed to allocate pspoll frame");
-- return -ENOMEM;
-- }
-- skb_reserve(skb, stlc->hw->extra_tx_headroom);
--
-- pspoll = (struct ieee80211_hdr *) skb_put(skb, 16);
-- memset(pspoll, 0, 16);
-- fc = IEEE80211_FTYPE_CTL | IEEE80211_STYPE_PSPOLL;
-- if (powersave)
-- fc |= IEEE80211_FCTL_PM;
-- pspoll->frame_control = cpu_to_le16(fc);
-- pspoll->duration_id = cpu_to_le16(stlc->aid);
--
-- /* aid in PS-Poll has its two MSBs each set to 1 */
-- pspoll->duration_id |= cpu_to_le16(1 << 15) | cpu_to_le16(1 << 14);
--
-- memcpy(pspoll->addr1, stlc->bssid, ETH_ALEN);
-- memcpy(pspoll->addr2, stlc->mac_addr, ETH_ALEN);
--
-- stlc45xx_debug(DEBUG_PSM, "sending PS-Poll frame to %pM (powersave %d, "
-- "fc 0x%x, aid %d)", pspoll->addr1,
-- powersave, fc, stlc->aid);
--
-- spin_lock_bh(&stlc->tx_lock);
--
-- entry = stlc45xx_txbuffer_alloc(stlc, skb->len);
--
-- spin_unlock_bh(&stlc->tx_lock);
--
-- if (!entry) {
-- /*
-- * The queue should be stopped before the firmware buffer
-- * is full, so firmware buffer should always have enough
-- * space.
-- *
-- * But I'm too lazy and omit it for now.
-- */
-- if (net_ratelimit())
-- stlc45xx_warning("firmware tx buffer full is full "
-- "for null frame");
-- return -ENOSPC;
-- }
--
-- payload = skb->data;
-- payload_len = skb->len;
-- padding = (int) (skb->data - sizeof(*data)) & 3;
-- entry->header_len = sizeof(*data) + padding;
--
-- entry->skb = skb;
-- entry->status_needed = false;
-- entry->handle = (u32) skb;
-- entry->lifetime = jiffies + msecs_to_jiffies(TX_FRAME_LIFETIME);
--
-- stlc45xx_debug(DEBUG_TX, "tx data 0x%x (0x%p payload %d B "
-- "padding %d header_len %d)",
-- entry->handle, payload, payload_len, padding,
-- entry->header_len);
-- stlc45xx_dump(DEBUG_TX_CONTENT, payload, payload_len);
--
-- data = (struct s_lm_data_out *) skb_push(skb, entry->header_len);
--
-- memset(data, 0, entry->header_len);
--
-- if (padding)
-- data->flags = LM_FLAG_ALIGN;
--
-- data->flags = LM_OUT_BURST;
-- data->length = payload_len;
-- data->handle = entry->handle;
-- data->aid = 1;
-- data->rts_retries = 7;
-- data->retries = 7;
-- data->aloft_ctrl = 0;
-- data->crypt_offset = 58;
-- data->keytype = 0;
-- data->keylen = 0;
-- data->queue = LM_QUEUE_DATA3;
-- data->backlog = 32;
-- data->antenna = 2;
-- data->cts = 3;
-- data->power = 127;
--
-- for (i = 0; i < 8; i++)
-- data->aloft[i] = 0;
--
-- /*
-- * check if there's enough space in tx buffer
-- *
-- * FIXME: ignored for now
-- */
--
-- stlc45xx_tx_frame(stlc, entry->start, skb->data, skb->len);
--
-- list_add(&entry->tx_list, &stlc->tx_sent);
--
-- return 0;
--}
--
--/*
-- * caller must hold mutex
-- *
-- * shamelessly stolen from mac80211/ieee80211_send_nullfunc
-- */
--static int stlc45xx_tx_nullfunc(struct stlc45xx *stlc, bool powersave)
--{
-- struct ieee80211_hdr *nullfunc;
-- int payload_len, padding, i;
-- struct s_lm_data_out *data;
-- struct txbuffer *entry;
-- struct sk_buff *skb;
-- char *payload;
-- u16 fc;
--
-- skb = dev_alloc_skb(stlc->hw->extra_tx_headroom + 24);
-- if (!skb) {
-- stlc45xx_warning("failed to allocate buffer for null frame\n");
-- return -ENOMEM;
-- }
-- skb_reserve(skb, stlc->hw->extra_tx_headroom);
--
-- nullfunc = (struct ieee80211_hdr *) skb_put(skb, 24);
-- memset(nullfunc, 0, 24);
-- fc = IEEE80211_FTYPE_DATA | IEEE80211_STYPE_NULLFUNC |
-- IEEE80211_FCTL_TODS;
--
-- if (powersave)
-- fc |= IEEE80211_FCTL_PM;
--
-- nullfunc->frame_control = cpu_to_le16(fc);
-- memcpy(nullfunc->addr1, stlc->bssid, ETH_ALEN);
-- memcpy(nullfunc->addr2, stlc->mac_addr, ETH_ALEN);
-- memcpy(nullfunc->addr3, stlc->bssid, ETH_ALEN);
--
-- stlc45xx_debug(DEBUG_PSM, "sending Null frame to %pM (powersave %d, "
-- "fc 0x%x)", nullfunc->addr1, powersave, fc);
--
-- spin_lock_bh(&stlc->tx_lock);
--
-- entry = stlc45xx_txbuffer_alloc(stlc, skb->len);
--
-- spin_unlock_bh(&stlc->tx_lock);
--
-- if (!entry) {
-- /*
-- * The queue should be stopped before the firmware buffer
-- * is full, so firmware buffer should always have enough
-- * space.
-- *
-- * But I'm too lazy and omit it for now.
-- */
-- if (net_ratelimit())
-- stlc45xx_warning("firmware tx buffer full is full "
-- "for null frame");
-- return -ENOSPC;
-- }
--
-- payload = skb->data;
-- payload_len = skb->len;
-- padding = (int) (skb->data - sizeof(*data)) & 3;
-- entry->header_len = sizeof(*data) + padding;
--
-- entry->skb = skb;
-- entry->status_needed = false;
-- entry->handle = (u32) skb;
-- entry->lifetime = jiffies + msecs_to_jiffies(TX_FRAME_LIFETIME);
--
-- stlc45xx_debug(DEBUG_TX, "tx data 0x%x (0x%p payload %d B "
-- "padding %d header_len %d)",
-- entry->handle, payload, payload_len, padding,
-- entry->header_len);
-- stlc45xx_dump(DEBUG_TX_CONTENT, payload, payload_len);
--
-- data = (struct s_lm_data_out *) skb_push(skb, entry->header_len);
--
-- memset(data, 0, entry->header_len);
--
-- if (padding)
-- data->flags = LM_FLAG_ALIGN;
--
-- data->flags = LM_OUT_BURST;
-- data->length = payload_len;
-- data->handle = entry->handle;
-- data->aid = 1;
-- data->rts_retries = 7;
-- data->retries = 7;
-- data->aloft_ctrl = 0;
-- data->crypt_offset = 58;
-- data->keytype = 0;
-- data->keylen = 0;
-- data->queue = LM_QUEUE_DATA3;
-- data->backlog = 32;
-- data->antenna = 2;
-- data->cts = 3;
-- data->power = 127;
--
-- for (i = 0; i < 8; i++)
-- data->aloft[i] = 0;
--
-- /*
-- * check if there's enough space in tx buffer
-- *
-- * FIXME: ignored for now
-- */
--
-- stlc45xx_tx_frame(stlc, entry->start, skb->data, skb->len);
--
-- list_add(&entry->tx_list, &stlc->tx_sent);
--
-- return 0;
--}
--
--/* caller must hold mutex */
--static void stlc45xx_tx_psm(struct stlc45xx *stlc, bool enable)
--{
-- struct s_lm_control *control;
-- struct s_lmo_psm *psm;
-- size_t len, psm_len;
--
-- WARN_ON(!stlc->associated);
-- WARN_ON(stlc->aid < 1);
-- WARN_ON(stlc->aid > 2007);
--
-- psm_len = sizeof(*psm);
-- len = sizeof(*control) + psm_len;
-- control = kzalloc(len, GFP_KERNEL);
-- psm = (struct s_lmo_psm *) (control + 1);
--
-- control->flags = LM_FLAG_CONTROL | LM_CTRL_OPSET;
-- control->length = psm_len;
-- control->oid = LM_OID_PSM;
--
-- if (enable)
-- psm->flags |= LM_PSM;
--
-- psm->aid = stlc->aid;
--
-- psm->beacon_rcpi_skip_max = 60;
--
-- psm->intervals[0].interval = 1;
-- psm->intervals[0].periods = 1;
-- psm->intervals[1].interval = 1;
-- psm->intervals[1].periods = 1;
-- psm->intervals[2].interval = 1;
-- psm->intervals[2].periods = 1;
-- psm->intervals[3].interval = 1;
-- psm->intervals[3].periods = 1;
--
-- psm->nr = 0;
-- psm->exclude[0] = 0;
--
-- stlc45xx_debug(DEBUG_PSM, "sending LM_OID_PSM (aid %d, interval %d)",
-- psm->aid, psm->intervals[0].interval);
--
-- stlc45xx_tx_frame(stlc, FIRMWARE_CONFIG_START, control, len);
--
-- kfree(control);
--}
--
--static int stlc45xx_op_tx(struct ieee80211_hw *hw, struct sk_buff *skb)
--{
-- struct stlc45xx *stlc = hw->priv;
-- struct ieee80211_tx_info *info;
-- struct ieee80211_rate *rate;
-- int payload_len, padding, i;
-- struct s_lm_data_out *data;
-- struct txbuffer *entry;
-- char *payload;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- spin_lock_bh(&stlc->tx_lock);
--
-- entry = stlc45xx_txbuffer_alloc(stlc, skb->len);
-- if (!entry) {
-- /* the queue should be stopped before the firmware buffer
-- * is full, so firmware buffer should always have enough
-- * space */
-- if (net_ratelimit())
-- stlc45xx_warning("firmware buffer full");
-- spin_unlock_bh(&stlc->tx_lock);
-- return NETDEV_TX_BUSY;
-- }
--
-- info = IEEE80211_SKB_CB(skb);
--
-- payload = skb->data;
-- payload_len = skb->len;
-- padding = (int) (skb->data - sizeof(*data)) & 3;
-- entry->header_len = sizeof(*data) + padding;
--
-- entry->skb = skb;
-- entry->status_needed = true;
-- entry->handle = (u32) skb;
-- entry->lifetime = jiffies + msecs_to_jiffies(TX_FRAME_LIFETIME);
--
-- stlc45xx_debug(DEBUG_TX, "tx data 0x%x (0x%p payload %d B "
-- "padding %d header_len %d)",
-- entry->handle, payload, payload_len, padding,
-- entry->header_len);
-- stlc45xx_dump(DEBUG_TX_CONTENT, payload, payload_len);
--
-- data = (struct s_lm_data_out *) skb_push(skb, entry->header_len);
--
-- memset(data, 0, entry->header_len);
--
-- if (padding)
-- data->flags = LM_FLAG_ALIGN;
--
-- data->flags = LM_OUT_BURST;
-- data->length = payload_len;
-- data->handle = entry->handle;
-- data->aid = 1;
-- data->rts_retries = 7;
-- data->retries = 7;
-- data->aloft_ctrl = 0;
-- data->crypt_offset = 58;
-- data->keytype = 0;
-- data->keylen = 0;
-- data->queue = 2;
-- data->backlog = 32;
-- data->antenna = 2;
-- data->cts = 3;
-- data->power = 127;
--
-- for (i = 0; i < 8; i++) {
-- rate = ieee80211_get_tx_rate(stlc->hw, info);
-- data->aloft[i] = rate->hw_value;
-- }
--
-- list_add_tail(&entry->tx_list, &stlc->tx_pending);
--
-- /* check if there's enough space in tx buffer */
-- if (stlc45xx_txbuffer_find(stlc, MAX_FRAME_LEN) == -1) {
-- stlc45xx_debug(DEBUG_QUEUE, "tx buffer full, stopping queues");
-- stlc->tx_queue_stopped = 1;
-- ieee80211_stop_queues(stlc->hw);
-- }
--
-- queue_work(stlc->hw->workqueue, &stlc->work);
--
-- spin_unlock_bh(&stlc->tx_lock);
--
-- return NETDEV_TX_OK;
--}
--
--static int stlc45xx_op_start(struct ieee80211_hw *hw)
--{
-- struct stlc45xx *stlc = hw->priv;
-- unsigned long timeout;
-- int ret = 0;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- mutex_lock(&stlc->mutex);
--
-- stlc->fw_state = FW_STATE_BOOTING;
-- stlc->channel = 1;
--
-- stlc45xx_power_on(stlc);
--
-- ret = stlc45xx_upload_firmware(stlc);
-- if (ret < 0) {
-- stlc45xx_power_off(stlc);
-- goto out_unlock;
-- }
--
-- stlc->tx_queue_stopped = 0;
--
-- mutex_unlock(&stlc->mutex);
--
-- timeout = msecs_to_jiffies(2000);
-- timeout = wait_for_completion_interruptible_timeout(&stlc->fw_comp,
-- timeout);
-- if (!timeout) {
-- stlc45xx_error("firmware boot failed");
-- stlc45xx_power_off(stlc);
-- ret = -1;
-- goto out;
-- }
--
-- stlc45xx_debug(DEBUG_BOOT, "firmware booted");
--
-- /* FIXME: should we take mutex just after wait_for_completion()? */
-- mutex_lock(&stlc->mutex);
--
-- WARN_ON(stlc->fw_state != FW_STATE_READY);
--
--out_unlock:
-- mutex_unlock(&stlc->mutex);
--
--out:
-- return ret;
--}
--
--static void stlc45xx_op_stop(struct ieee80211_hw *hw)
--{
-- struct stlc45xx *stlc = hw->priv;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- mutex_lock(&stlc->mutex);
--
-- WARN_ON(stlc->fw_state != FW_STATE_READY);
--
-- stlc45xx_power_off(stlc);
--
-- /* FIXME: make sure that all work_structs have completed */
--
-- spin_lock_bh(&stlc->tx_lock);
-- stlc45xx_flush_queues(stlc);
-- spin_unlock_bh(&stlc->tx_lock);
--
-- stlc->fw_state = FW_STATE_OFF;
--
-- mutex_unlock(&stlc->mutex);
--}
--
--static int stlc45xx_op_add_interface(struct ieee80211_hw *hw,
-- struct ieee80211_if_init_conf *conf)
--{
-- struct stlc45xx *stlc = hw->priv;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- switch (conf->type) {
-- case NL80211_IFTYPE_STATION:
-- break;
-- default:
-- return -EOPNOTSUPP;
-- }
--
-- memcpy(stlc->mac_addr, conf->mac_addr, ETH_ALEN);
--
-- return 0;
--}
--
--static void stlc45xx_op_remove_interface(struct ieee80211_hw *hw,
-- struct ieee80211_if_init_conf *conf)
--{
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--}
--
--static int stlc45xx_op_config(struct ieee80211_hw *hw, u32 changed)
--{
-- struct stlc45xx *stlc = hw->priv;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- mutex_lock(&stlc->mutex);
--
-- stlc->channel = hw->conf.channel->hw_value;
-- stlc45xx_tx_scan(stlc);
-- stlc45xx_tx_setup(stlc);
-- stlc45xx_tx_edcf(stlc);
--
-- if ((hw->conf.flags & IEEE80211_CONF_PS) != stlc->psm) {
-- stlc->psm = hw->conf.flags & IEEE80211_CONF_PS;
-- if (stlc->associated) {
-- stlc45xx_tx_psm(stlc, stlc->psm);
-- stlc45xx_tx_nullfunc(stlc, stlc->psm);
-- }
-- }
--
-- mutex_unlock(&stlc->mutex);
--
-- return 0;
--}
--
--static void stlc45xx_op_configure_filter(struct ieee80211_hw *hw,
-- unsigned int changed_flags,
-- unsigned int *total_flags,
-- int mc_count,
-- struct dev_addr_list *mc_list)
--{
-- *total_flags = 0;
--}
--
--static void stlc45xx_op_bss_info_changed(struct ieee80211_hw *hw,
-- struct ieee80211_vif *vif,
-- struct ieee80211_bss_conf *info,
-- u32 changed)
--{
-- struct stlc45xx *stlc = hw->priv;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
-- mutex_lock(&stlc->mutex);
--
-- memcpy(stlc->bssid, info->bssid, ETH_ALEN);
-- stlc45xx_tx_setup(stlc);
--
-- mutex_unlock(&stlc->mutex);
--
-- if (changed & BSS_CHANGED_ASSOC) {
-- stlc->associated = info->assoc;
-- if (info->assoc)
-- stlc->aid = info->aid;
-- else
-- stlc->aid = -1;
--
-- if (stlc->psm) {
-- stlc45xx_tx_psm(stlc, stlc->psm);
-- stlc45xx_tx_nullfunc(stlc, stlc->psm);
-- }
-- }
--}
--
--
--/* can't be const, mac80211 writes to this */
--static struct ieee80211_rate stlc45xx_rates[] = {
-- { .bitrate = 10, .hw_value = 0, .hw_value_short = 0, },
-- { .bitrate = 20, .hw_value = 1, .hw_value_short = 1, },
-- { .bitrate = 55, .hw_value = 2, .hw_value_short = 2, },
-- { .bitrate = 110, .hw_value = 3, .hw_value_short = 3, },
-- { .bitrate = 60, .hw_value = 4, .hw_value_short = 4, },
-- { .bitrate = 90, .hw_value = 5, .hw_value_short = 5, },
-- { .bitrate = 120, .hw_value = 6, .hw_value_short = 6, },
-- { .bitrate = 180, .hw_value = 7, .hw_value_short = 7, },
-- { .bitrate = 240, .hw_value = 8, .hw_value_short = 8, },
-- { .bitrate = 360, .hw_value = 9, .hw_value_short = 9, },
-- { .bitrate = 480, .hw_value = 10, .hw_value_short = 10, },
-- { .bitrate = 540, .hw_value = 11, .hw_value_short = 11, },
--};
--
--/* can't be const, mac80211 writes to this */
--static struct ieee80211_channel stlc45xx_channels[] = {
-- { .hw_value = 1, .center_freq = 2412},
-- { .hw_value = 2, .center_freq = 2417},
-- { .hw_value = 3, .center_freq = 2422},
-- { .hw_value = 4, .center_freq = 2427},
-- { .hw_value = 5, .center_freq = 2432},
-- { .hw_value = 6, .center_freq = 2437},
-- { .hw_value = 7, .center_freq = 2442},
-- { .hw_value = 8, .center_freq = 2447},
-- { .hw_value = 9, .center_freq = 2452},
-- { .hw_value = 10, .center_freq = 2457},
-- { .hw_value = 11, .center_freq = 2462},
-- { .hw_value = 12, .center_freq = 2467},
-- { .hw_value = 13, .center_freq = 2472},
--};
--
--/* can't be const, mac80211 writes to this */
--static struct ieee80211_supported_band stlc45xx_band_2ghz = {
-- .channels = stlc45xx_channels,
-- .n_channels = ARRAY_SIZE(stlc45xx_channels),
-- .bitrates = stlc45xx_rates,
-- .n_bitrates = ARRAY_SIZE(stlc45xx_rates),
--};
--
--static const struct ieee80211_ops stlc45xx_ops = {
-- .start = stlc45xx_op_start,
-- .stop = stlc45xx_op_stop,
-- .add_interface = stlc45xx_op_add_interface,
-- .remove_interface = stlc45xx_op_remove_interface,
-- .config = stlc45xx_op_config,
-- .configure_filter = stlc45xx_op_configure_filter,
-- .tx = stlc45xx_op_tx,
-- .bss_info_changed = stlc45xx_op_bss_info_changed,
--};
--
--static int stlc45xx_register_mac80211(struct stlc45xx *stlc)
--{
-- /* FIXME: SET_IEEE80211_PERM_ADDR() requires default_mac_addr
-- to be non-const for some strange reason */
-- static u8 default_mac_addr[ETH_ALEN] = {
-- 0x00, 0x02, 0xee, 0xc0, 0xff, 0xee
-- };
-- int ret;
--
-- SET_IEEE80211_PERM_ADDR(stlc->hw, default_mac_addr);
--
-- ret = ieee80211_register_hw(stlc->hw);
-- if (ret) {
-- stlc45xx_error("unable to register mac80211 hw: %d", ret);
-- return ret;
-- }
--
-- return 0;
--}
--
--static void stlc45xx_device_release(struct device *dev)
--{
--
--}
--
--static struct platform_device stlc45xx_device = {
-- .name = "stlc45xx",
-- .id = -1,
--
-- /* device model insists to have a release function */
-- .dev = {
-- .release = stlc45xx_device_release,
-- },
--};
--
--static int __devinit stlc45xx_probe(struct spi_device *spi)
--{
-- struct stlc45xx *stlc;
-- struct ieee80211_hw *hw;
-- int ret;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- /* mac80211 alloc */
-- hw = ieee80211_alloc_hw(sizeof(*stlc), &stlc45xx_ops);
-- if (!hw) {
-- stlc45xx_error("could not alloc ieee80211_hw");
-- ret = -ENOMEM;
-- goto out;
-- }
--
-- /* mac80211 clears hw->priv */
-- stlc = hw->priv;
--
-- stlc->hw = hw;
-- dev_set_drvdata(&spi->dev, stlc);
-- stlc->spi = spi;
--
-- spi->bits_per_word = 16;
-- spi->max_speed_hz = 24000000;
--
-- ret = spi_setup(spi);
-- if (ret < 0)
-- stlc45xx_error("spi_setup failed");
--
-- ret = gpio_request(stlc45xx_gpio_power, "stlc45xx power");
-- if (ret < 0) {
-- stlc45xx_error("power GPIO request failed: %d", ret);
-- return ret;
-- }
--
-- ret = gpio_request(stlc45xx_gpio_irq, "stlc45xx irq");
-- if (ret < 0) {
-- stlc45xx_error("irq GPIO request failed: %d", ret);
-- goto out;
-- }
--
-- gpio_direction_output(stlc45xx_gpio_power, 0);
-- gpio_direction_input(stlc45xx_gpio_irq);
--
-- ret = request_irq(gpio_to_irq(stlc45xx_gpio_irq),
-- stlc45xx_interrupt, IRQF_DISABLED, "stlc45xx",
-- stlc->spi);
-- if (ret < 0)
-- /* FIXME: handle the error */
-- stlc45xx_error("request_irq() failed");
--
-- set_irq_type(gpio_to_irq(stlc45xx_gpio_irq),
-- IRQ_TYPE_EDGE_RISING);
--
-- disable_irq(gpio_to_irq(stlc45xx_gpio_irq));
--
-- ret = platform_device_register(&stlc45xx_device);
-- if (ret) {
-- stlc45xx_error("Couldn't register wlan_omap device.");
-- return ret;
-- }
-- dev_set_drvdata(&stlc45xx_device.dev, stlc);
--
-- INIT_WORK(&stlc->work, stlc45xx_work);
-- INIT_WORK(&stlc->work_reset, stlc45xx_work_reset);
-- INIT_DELAYED_WORK(&stlc->work_tx_timeout, stlc45xx_work_tx_timeout);
-- mutex_init(&stlc->mutex);
-- init_completion(&stlc->fw_comp);
-- spin_lock_init(&stlc->tx_lock);
-- INIT_LIST_HEAD(&stlc->txbuffer);
-- INIT_LIST_HEAD(&stlc->tx_pending);
-- INIT_LIST_HEAD(&stlc->tx_sent);
--
-- hw->flags = IEEE80211_HW_RX_INCLUDES_FCS |
-- IEEE80211_HW_SIGNAL_DBM |
-- IEEE80211_HW_NOISE_DBM;
-- /* four bytes for padding */
-- hw->extra_tx_headroom = sizeof(struct s_lm_data_out) + 4;
--
-- /* unit us */
-- hw->channel_change_time = 1000;
--
-- hw->wiphy->interface_modes = BIT(NL80211_IFTYPE_STATION);
-- hw->wiphy->bands[IEEE80211_BAND_2GHZ] = &stlc45xx_band_2ghz;
--
-- SET_IEEE80211_DEV(hw, &spi->dev);
--
-- BUILD_BUG_ON(sizeof(default_cal_rssi) != RSSI_CAL_ARRAY_LEN);
-- BUILD_BUG_ON(sizeof(default_cal_channels) != CHANNEL_CAL_ARRAY_LEN);
--
-- stlc->cal_rssi = kmemdup(default_cal_rssi, RSSI_CAL_ARRAY_LEN,
-- GFP_KERNEL);
-- stlc->cal_channels = kmemdup(default_cal_channels,
-- CHANNEL_CAL_ARRAY_LEN,
-- GFP_KERNEL);
--
-- ret = device_create_file(&stlc45xx_device.dev, &dev_attr_cal_rssi);
-- if (ret < 0) {
-- stlc45xx_error("failed to create sysfs file cal_rssi");
-- goto out;
-- }
--
-- ret = device_create_file(&stlc45xx_device.dev, &dev_attr_cal_channels);
-- if (ret < 0) {
-- stlc45xx_error("failed to create sysfs file cal_channels");
-- goto out;
-- }
--
-- ret = device_create_file(&stlc45xx_device.dev, &dev_attr_tx_buf);
-- if (ret < 0) {
-- stlc45xx_error("failed to create sysfs file tx_buf");
-- goto out;
-- }
--
-- ret = stlc45xx_register_mac80211(stlc);
-- if (ret < 0)
-- goto out;
--
-- stlc45xx_info("v" DRIVER_VERSION " loaded");
--
-- stlc45xx_info("config buffer 0x%x-0x%x",
-- FIRMWARE_CONFIG_START, FIRMWARE_CONFIG_END);
-- stlc45xx_info("tx 0x%x-0x%x, rx 0x%x-0x%x",
-- FIRMWARE_TXBUFFER_START, FIRMWARE_TXBUFFER_END,
-- FIRMWARE_RXBUFFER_START, FIRMWARE_RXBUFFER_END);
--
--out:
-- return ret;
--}
--
--static int __devexit stlc45xx_remove(struct spi_device *spi)
--{
-- struct stlc45xx *stlc = dev_get_drvdata(&spi->dev);
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- platform_device_unregister(&stlc45xx_device);
--
-- ieee80211_unregister_hw(stlc->hw);
--
-- free_irq(gpio_to_irq(stlc45xx_gpio_irq), spi);
--
-- gpio_free(stlc45xx_gpio_power);
-- gpio_free(stlc45xx_gpio_irq);
--
-- /* FIXME: free cal_channels and cal_rssi? */
--
-- kfree(stlc->fw);
--
-- mutex_destroy(&stlc->mutex);
--
-- /* frees also stlc */
-- ieee80211_free_hw(stlc->hw);
-- stlc = NULL;
--
-- return 0;
--}
--
--
--static struct spi_driver stlc45xx_spi_driver = {
-- .driver = {
-- /* use cx3110x name because board-n800.c uses that for the
-- * SPI port */
-- .name = "cx3110x",
-- .bus = &spi_bus_type,
-- .owner = THIS_MODULE,
-- },
--
-- .probe = stlc45xx_probe,
-- .remove = __devexit_p(stlc45xx_remove),
--};
--
--static int __init stlc45xx_init(void)
--{
-- int ret;
--
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- ret = spi_register_driver(&stlc45xx_spi_driver);
-- if (ret < 0) {
-- stlc45xx_error("failed to register SPI driver: %d", ret);
-- goto out;
-- }
--
--out:
-- return ret;
--}
--
--static void __exit stlc45xx_exit(void)
--{
-- stlc45xx_debug(DEBUG_FUNC, "%s", __func__);
--
-- spi_unregister_driver(&stlc45xx_spi_driver);
--
-- stlc45xx_info("unloaded");
--}
--
--module_init(stlc45xx_init);
--module_exit(stlc45xx_exit);
--
--MODULE_LICENSE("GPL");
--MODULE_AUTHOR("Kalle Valo <kalle.valo@nokia.com>");
--MODULE_ALIAS("spi:cx3110x");
---- a/drivers/staging/stlc45xx/stlc45xx.h
-+++ /dev/null
-@@ -1,283 +0,0 @@
--/*
-- * This file is part of stlc45xx
-- *
-- * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies).
-- *
-- * Contact: Kalle Valo <kalle.valo@nokia.com>
-- *
-- * This program is free software; you can redistribute it and/or
-- * modify it under the terms of the GNU General Public License
-- * version 2 as published by the Free Software Foundation.
-- *
-- * This program is distributed in the hope that it will be useful, but
-- * WITHOUT ANY WARRANTY; without even the implied warranty of
-- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-- * General Public License for more details.
-- *
-- * You should have received a copy of the GNU General Public License
-- * along with this program; if not, write to the Free Software
-- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-- * 02110-1301 USA
-- *
-- */
--
--#include <linux/mutex.h>
--#include <linux/list.h>
--#include <net/mac80211.h>
--
--#include "stlc45xx_lmac.h"
--
--#define DRIVER_NAME "stlc45xx"
--#define DRIVER_VERSION "0.1.3"
--
--#define DRIVER_PREFIX DRIVER_NAME ": "
--
--enum {
-- DEBUG_NONE = 0,
-- DEBUG_FUNC = 1 << 0,
-- DEBUG_IRQ = 1 << 1,
-- DEBUG_BH = 1 << 2,
-- DEBUG_RX = 1 << 3,
-- DEBUG_RX_CONTENT = 1 << 5,
-- DEBUG_TX = 1 << 6,
-- DEBUG_TX_CONTENT = 1 << 8,
-- DEBUG_TXBUFFER = 1 << 9,
-- DEBUG_QUEUE = 1 << 10,
-- DEBUG_BOOT = 1 << 11,
-- DEBUG_PSM = 1 << 12,
-- DEBUG_ALL = ~0,
--};
--
--#define DEBUG_LEVEL DEBUG_NONE
--/* #define DEBUG_LEVEL DEBUG_ALL */
--/* #define DEBUG_LEVEL (DEBUG_TX | DEBUG_RX | DEBUG_IRQ) */
--/* #define DEBUG_LEVEL (DEBUG_TX | DEBUG_MEMREGION | DEBUG_QUEUE) */
--/* #define DEBUG_LEVEL (DEBUG_MEMREGION | DEBUG_QUEUE) */
--
--#define stlc45xx_error(fmt, arg...) \
-- printk(KERN_ERR DRIVER_PREFIX "ERROR " fmt "\n", ##arg)
--
--#define stlc45xx_warning(fmt, arg...) \
-- printk(KERN_WARNING DRIVER_PREFIX "WARNING " fmt "\n", ##arg)
--
--#define stlc45xx_info(fmt, arg...) \
-- printk(KERN_INFO DRIVER_PREFIX fmt "\n", ##arg)
--
--#define stlc45xx_debug(level, fmt, arg...) \
-- do { \
-- if (level & DEBUG_LEVEL) \
-- printk(KERN_DEBUG DRIVER_PREFIX fmt "\n", ##arg); \
-- } while (0)
--
--#define stlc45xx_dump(level, buf, len) \
-- do { \
-- if (level & DEBUG_LEVEL) \
-- print_hex_dump(KERN_DEBUG, "", DUMP_PREFIX_OFFSET, \
-- 16, 1, buf, len, 1); \
-- } while (0)
--
--#define MAC2STR(a) ((a)[0], (a)[1], (a)[2], (a)[3], (a)[4], (a)[5])
--#define MACSTR "%02x:%02x:%02x:%02x:%02x:%02x"
--
--/* Bit 15 is read/write bit; ON = READ, OFF = WRITE */
--#define ADDR_READ_BIT_15 0x8000
--
--#define SPI_ADRS_ARM_INTERRUPTS 0x00
--#define SPI_ADRS_ARM_INT_EN 0x04
--
--#define SPI_ADRS_HOST_INTERRUPTS 0x08
--#define SPI_ADRS_HOST_INT_EN 0x0c
--#define SPI_ADRS_HOST_INT_ACK 0x10
--
--#define SPI_ADRS_GEN_PURP_1 0x14
--#define SPI_ADRS_GEN_PURP_2 0x18
--
--/* high word */
--#define SPI_ADRS_DEV_CTRL_STAT 0x26
--
--#define SPI_ADRS_DMA_DATA 0x28
--
--#define SPI_ADRS_DMA_WRITE_CTRL 0x2c
--#define SPI_ADRS_DMA_WRITE_LEN 0x2e
--#define SPI_ADRS_DMA_WRITE_BASE 0x30
--
--#define SPI_ADRS_DMA_READ_CTRL 0x34
--#define SPI_ADRS_DMA_READ_LEN 0x36
--#define SPI_ADRS_DMA_READ_BASE 0x38
--
--#define SPI_CTRL_STAT_HOST_OVERRIDE 0x8000
--#define SPI_CTRL_STAT_START_HALTED 0x4000
--#define SPI_CTRL_STAT_RAM_BOOT 0x2000
--#define SPI_CTRL_STAT_HOST_RESET 0x1000
--#define SPI_CTRL_STAT_HOST_CPU_EN 0x0800
--
--#define SPI_DMA_WRITE_CTRL_ENABLE 0x0001
--#define SPI_DMA_READ_CTRL_ENABLE 0x0001
--#define HOST_ALLOWED (1 << 7)
--
--#define FIRMWARE_ADDRESS 0x20000
--
--#define SPI_TIMEOUT 100 /* msec */
--
--#define SPI_MAX_TX_PACKETS 32
--
--#define SPI_MAX_PACKET_SIZE 32767
--
--#define SPI_TARGET_INT_WAKEUP 0x00000001
--#define SPI_TARGET_INT_SLEEP 0x00000002
--#define SPI_TARGET_INT_RDDONE 0x00000004
--
--#define SPI_TARGET_INT_CTS 0x00004000
--#define SPI_TARGET_INT_DR 0x00008000
--
--#define SPI_HOST_INT_READY 0x00000001
--#define SPI_HOST_INT_WR_READY 0x00000002
--#define SPI_HOST_INT_SW_UPDATE 0x00000004
--#define SPI_HOST_INT_UPDATE 0x10000000
--
--/* clear to send */
--#define SPI_HOST_INT_CTS 0x00004000
--
--/* data ready */
--#define SPI_HOST_INT_DR 0x00008000
--
--#define SPI_HOST_INTS_DEFAULT \
-- (SPI_HOST_INT_READY | SPI_HOST_INT_UPDATE | SPI_HOST_INT_SW_UPDATE)
--
--#define TARGET_BOOT_SLEEP 50
--
--/* The firmware buffer is divided into three areas:
-- *
-- * o config area (for control commands)
-- * o tx buffer
-- * o rx buffer
-- */
--#define FIRMWARE_BUFFER_START 0x20200
--#define FIRMWARE_BUFFER_END 0x27c60
--#define FIRMWARE_BUFFER_LEN (FIRMWARE_BUFFER_END - FIRMWARE_BUFFER_START)
--#define FIRMWARE_MTU 3240
--#define FIRMWARE_CONFIG_PAYLOAD_LEN 1024
--#define FIRMWARE_CONFIG_START FIRMWARE_BUFFER_START
--#define FIRMWARE_CONFIG_LEN (sizeof(struct s_lm_control) + \
-- FIRMWARE_CONFIG_PAYLOAD_LEN)
--#define FIRMWARE_CONFIG_END (FIRMWARE_CONFIG_START + FIRMWARE_CONFIG_LEN - 1)
--#define FIRMWARE_RXBUFFER_LEN (5 * FIRMWARE_MTU + 1024)
--#define FIRMWARE_RXBUFFER_START (FIRMWARE_BUFFER_END - FIRMWARE_RXBUFFER_LEN)
--#define FIRMWARE_RXBUFFER_END (FIRMWARE_RXBUFFER_START + \
-- FIRMWARE_RXBUFFER_LEN - 1)
--#define FIRMWARE_TXBUFFER_START (FIRMWARE_BUFFER_START + FIRMWARE_CONFIG_LEN)
--#define FIRMWARE_TXBUFFER_LEN (FIRMWARE_BUFFER_LEN - FIRMWARE_CONFIG_LEN - \
-- FIRMWARE_RXBUFFER_LEN)
--#define FIRMWARE_TXBUFFER_END (FIRMWARE_TXBUFFER_START + \
-- FIRMWARE_TXBUFFER_LEN - 1)
--
--#define FIRMWARE_TXBUFFER_HEADER 100
--#define FIRMWARE_TXBUFFER_TRAILER 4
--
--/* FIXME: come up with a proper value */
--#define MAX_FRAME_LEN 2500
--
--/* unit is ms */
--#define TX_FRAME_LIFETIME 2000
--#define TX_TIMEOUT 4000
--
--#define SUPPORTED_CHANNELS 13
--
--/* FIXME */
--/* #define CHANNEL_CAL_LEN offsetof(struct s_lmo_scan, bratemask) - \ */
--/* offsetof(struct s_lmo_scan, channel) */
--#define CHANNEL_CAL_LEN 292
--#define CHANNEL_CAL_ARRAY_LEN (SUPPORTED_CHANNELS * CHANNEL_CAL_LEN)
--/* FIXME */
--/* #define RSSI_CAL_LEN sizeof(struct s_lmo_scan) - \ */
--/* offsetof(struct s_lmo_scan, rssical) */
--#define RSSI_CAL_LEN 8
--#define RSSI_CAL_ARRAY_LEN (SUPPORTED_CHANNELS * RSSI_CAL_LEN)
--
--struct s_dma_regs {
-- unsigned short cmd;
-- unsigned short len;
-- unsigned long addr;
--};
--
--struct stlc45xx_ie_tim {
-- u8 dtim_count;
-- u8 dtim_period;
-- u8 bmap_control;
-- u8 pvbmap[251];
--};
--
--struct txbuffer {
-- /* can be removed when switched to skb queue */
-- struct list_head tx_list;
--
-- struct list_head buffer_list;
--
-- int start;
-- int frame_start;
-- int end;
--
-- struct sk_buff *skb;
-- u32 handle;
--
-- bool status_needed;
--
-- int header_len;
--
-- /* unit jiffies */
-- unsigned long lifetime;
--};
--
--enum fw_state {
-- FW_STATE_OFF,
-- FW_STATE_BOOTING,
-- FW_STATE_READY,
-- FW_STATE_RESET,
-- FW_STATE_RESETTING,
--};
--
--struct stlc45xx {
-- struct ieee80211_hw *hw;
-- struct spi_device *spi;
-- struct work_struct work;
-- struct work_struct work_reset;
-- struct delayed_work work_tx_timeout;
-- struct mutex mutex;
-- struct completion fw_comp;
--
--
-- u8 bssid[ETH_ALEN];
-- u8 mac_addr[ETH_ALEN];
-- int channel;
--
-- u8 *cal_rssi;
-- u8 *cal_channels;
--
-- enum fw_state fw_state;
--
-- spinlock_t tx_lock;
--
-- /* protected by tx_lock */
-- struct list_head txbuffer;
--
-- /* protected by tx_lock */
-- struct list_head tx_pending;
--
-- /* protected by tx_lock */
-- int tx_queue_stopped;
--
-- /* protected by mutex */
-- struct list_head tx_sent;
--
-- int tx_frames;
--
-- u8 *fw;
-- int fw_len;
--
-- bool psm;
-- bool associated;
-- int aid;
-- bool pspolling;
--};
--
--
---- a/drivers/staging/stlc45xx/stlc45xx_lmac.h
-+++ /dev/null
-@@ -1,434 +0,0 @@
--/************************************************************************
--* This is the LMAC API interface header file for STLC4560. *
--* Copyright (C) 2007 Conexant Systems, Inc. *
--* This program is free software; you can redistribute it and/or *
--* modify it under the terms of the GNU General Public License *
--* as published by the Free Software Foundation; either version 2 *
--* of the License, or (at your option) any later version. *
--* *
--* This program is distributed in the hope that it will be useful, *
--* but WITHOUT ANY WARRANTY; without even the implied warranty of *
--* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
--* GNU General Public License for more details. *
--* *
--* You should have received a copy of the GNU General Public License *
--* along with this program. If not, see <http://www.gnu.org/licenses/>.*
--*************************************************************************/
--
--#ifndef __lmac_h__
--#define __lmac_h__
--
--#define LM_TOP_VARIANT 0x0506
--#define LM_BOTTOM_VARIANT 0x0506
--
--/*
-- * LMAC - UMAC interface definition:
-- */
--
--#define LM_FLAG_CONTROL 0x8000
--#define LM_FLAG_ALIGN 0x4000
--
--#define LM_CTRL_OPSET 0x0001
--
--#define LM_OUT_PROMISC 0x0001
--#define LM_OUT_TIMESTAMP 0x0002
--#define LM_OUT_SEQNR 0x0004
--#define LM_OUT_BURST 0x0010
--#define LM_OUT_NOCANCEL 0x0020
--#define LM_OUT_CLEARTIM 0x0040
--#define LM_OUT_HITCHHIKE 0x0080
--#define LM_OUT_COMPRESS 0x0100
--#define LM_OUT_CONCAT 0x0200
--#define LM_OUT_PCS_ACCEPT 0x0400
--#define LM_OUT_WAITEOSP 0x0800
--
--
--#define LM_ALOFT_SP 0x10
--#define LM_ALOFT_CTS 0x20
--#define LM_ALOFT_RTS 0x40
--#define LM_ALOFT_MASK 0x1f
--#define LM_ALOFT_RATE 0x0f
--
--#define LM_IN_FCS_GOOD 0x0001
--#define LM_IN_MATCH_MAC 0x0002
--#define LM_IN_MCBC 0x0004
--#define LM_IN_BEACON 0x0008
--#define LM_IN_MATCH_BSS 0x0010
--#define LM_IN_BCAST_BSS 0x0020
--#define LM_IN_DATA 0x0040
--#define LM_IN_TRUNCATED 0x0080
--
--#define LM_IN_TRANSPARENT 0x0200
--
--#define LM_QUEUE_BEACON 0
--#define LM_QUEUE_SCAN 1
--#define LM_QUEUE_MGT 2
--#define LM_QUEUE_MCBC 3
--#define LM_QUEUE_DATA 4
--#define LM_QUEUE_DATA0 4
--#define LM_QUEUE_DATA1 5
--#define LM_QUEUE_DATA2 6
--#define LM_QUEUE_DATA3 7
--
--#define LM_SETUP_INFRA 0x0001
--#define LM_SETUP_IBSS 0x0002
--#define LM_SETUP_TRANSPARENT 0x0008
--#define LM_SETUP_PROMISCUOUS 0x0010
--#define LM_SETUP_HIBERNATE 0x0020
--#define LM_SETUP_NOACK 0x0040
--#define LM_SETUP_RX_DISABLED 0x0080
--
--#define LM_ANTENNA_0 0
--#define LM_ANTENNA_1 1
--#define LM_ANTENNA_DIVERSITY 2
--
--#define LM_TX_FAILED 0x0001
--#define LM_TX_PSM 0x0002
--#define LM_TX_PSM_CANCELLED 0x0004
--
--#define LM_SCAN_EXIT 0x0001
--#define LM_SCAN_TRAP 0x0002
--#define LM_SCAN_ACTIVE 0x0004
--#define LM_SCAN_FILTER 0x0008
--
--#define LM_PSM 0x0001
--#define LM_PSM_DTIM 0x0002
--#define LM_PSM_MCBC 0x0004
--#define LM_PSM_CHECKSUM 0x0008
--#define LM_PSM_SKIP_MORE_DATA 0x0010
--#define LM_PSM_BEACON_TIMEOUT 0x0020
--#define LM_PSM_HFOSLEEP 0x0040
--#define LM_PSM_AUTOSWITCH_SLEEP 0x0080
--#define LM_PSM_LPIT 0x0100
--#define LM_PSM_BF_UCAST_SKIP 0x0200
--#define LM_PSM_BF_MCAST_SKIP 0x0400
--
--/* hfosleep */
--#define LM_PSM_SLEEP_OPTION_MASK (LM_PSM_AUTOSWITCH_SLEEP | LM_PSM_HFOSLEEP)
--#define LM_PSM_SLEEP_OPTION_SHIFT 6
--/* hfosleepend */
--#define LM_PSM_BF_OPTION_MASK (LM_PSM_BF_MCAST_SKIP | LM_PSM_BF_UCAST_SKIP)
--#define LM_PSM_BF_OPTION_SHIFT 9
--
--
--#define LM_PRIVACC_WEP 0x01
--#define LM_PRIVACC_TKIP 0x02
--#define LM_PRIVACC_MICHAEL 0x04
--#define LM_PRIVACC_CCX_KP 0x08
--#define LM_PRIVACC_CCX_MIC 0x10
--#define LM_PRIVACC_AES_CCMP 0x20
--
--/* size of s_lm_descr in words */
--#define LM_DESCR_SIZE_WORDS 11
--
--#ifndef __ASSEMBLER__
--
--enum {
-- LM_MODE_CLIENT = 0,
-- LM_MODE_AP
--};
--
--struct s_lm_descr {
-- uint16_t modes;
-- uint16_t flags;
-- uint32_t buffer_start;
-- uint32_t buffer_end;
-- uint8_t header;
-- uint8_t trailer;
-- uint8_t tx_queues;
-- uint8_t tx_depth;
-- uint8_t privacy;
-- uint8_t rx_keycache;
-- uint8_t tim_size;
-- uint8_t pad1;
-- uint8_t rates[16];
-- uint32_t link;
-- uint16_t mtu;
--};
--
--
--struct s_lm_control {
-- uint16_t flags;
-- uint16_t length;
-- uint32_t handle;
-- uint16_t oid;
-- uint16_t pad;
-- /* uint8_t data[]; */
--};
--
--enum {
-- LM_PRIV_NONE = 0,
-- LM_PRIV_WEP,
-- LM_PRIV_TKIP,
-- LM_PRIV_TKIPMICHAEL,
-- LM_PRIV_CCX_WEPMIC,
-- LM_PRIV_CCX_KPMIC,
-- LM_PRIV_CCX_KP,
-- LM_PRIV_AES_CCMP
--};
--
--enum {
-- LM_DECRYPT_NONE,
-- LM_DECRYPT_OK,
-- LM_DECRYPT_NOKEY,
-- LM_DECRYPT_NOMICHAEL,
-- LM_DECRYPT_NOCKIPMIC,
-- LM_DECRYPT_FAIL_WEP,
-- LM_DECRYPT_FAIL_TKIP,
-- LM_DECRYPT_FAIL_MICHAEL,
-- LM_DECRYPT_FAIL_CKIPKP,
-- LM_DECRYPT_FAIL_CKIPMIC,
-- LM_DECRYPT_FAIL_AESCCMP
--};
--
--struct s_lm_data_out {
-- uint16_t flags;
-- uint16_t length;
-- uint32_t handle;
-- uint16_t aid;
-- uint8_t rts_retries;
-- uint8_t retries;
-- uint8_t aloft[8];
-- uint8_t aloft_ctrl;
-- uint8_t crypt_offset;
-- uint8_t keytype;
-- uint8_t keylen;
-- uint8_t key[16];
-- uint8_t queue;
-- uint8_t backlog;
-- uint16_t durations[4];
-- uint8_t antenna;
-- uint8_t cts;
-- int16_t power;
-- uint8_t pad[2];
-- /*uint8_t data[];*/
--};
--
--#define LM_RCPI_INVALID (0xff)
--
--struct s_lm_data_in {
-- uint16_t flags;
-- uint16_t length;
-- uint16_t frequency;
-- uint8_t antenna;
-- uint8_t rate;
-- uint8_t rcpi;
-- uint8_t sq;
-- uint8_t decrypt;
-- uint8_t rssi_raw;
-- uint32_t clock[2];
-- /*uint8_t data[];*/
--};
--
--union u_lm_data {
-- struct s_lm_data_out out;
-- struct s_lm_data_in in;
--};
--
--enum {
-- LM_OID_SETUP = 0,
-- LM_OID_SCAN = 1,
-- LM_OID_TRAP = 2,
-- LM_OID_EDCF = 3,
-- LM_OID_KEYCACHE = 4,
-- LM_OID_PSM = 6,
-- LM_OID_TXCANCEL = 7,
-- LM_OID_TX = 8,
-- LM_OID_BURST = 9,
-- LM_OID_STATS = 10,
-- LM_OID_LED = 13,
-- LM_OID_TIMER = 15,
-- LM_OID_NAV = 20,
-- LM_OID_PCS = 22,
-- LM_OID_BT_BALANCER = 28,
-- LM_OID_GROUP_ADDRESS_TABLE = 30,
-- LM_OID_ARPTABLE = 31,
-- LM_OID_BT_OPTIONS = 35
--};
--
--enum {
-- LM_FRONTEND_UNKNOWN = 0,
-- LM_FRONTEND_DUETTE3,
-- LM_FRONTEND_DUETTE2,
-- LM_FRONTEND_FRISBEE,
-- LM_FRONTEND_CROSSBOW,
-- LM_FRONTEND_LONGBOW
--};
--
--
--#define INVALID_LPF_BANDWIDTH 0xffff
--#define INVALID_OSC_START_DELAY 0xffff
--
--struct s_lmo_setup {
-- uint16_t flags;
-- uint8_t macaddr[6];
-- uint8_t bssid[6];
-- uint8_t antenna;
-- uint8_t rx_align;
-- uint32_t rx_buffer;
-- uint16_t rx_mtu;
-- uint16_t frontend;
-- uint16_t timeout;
-- uint16_t truncate;
-- uint32_t bratemask;
-- uint8_t sbss_offset;
-- uint8_t mcast_window;
-- uint8_t rx_rssi_threshold;
-- uint8_t rx_ed_threshold;
-- uint32_t ref_clock;
-- uint16_t lpf_bandwidth;
-- uint16_t osc_start_delay;
--};
--
--
--struct s_lmo_scan {
-- uint16_t flags;
-- uint16_t dwell;
-- uint8_t channel[292];
-- uint32_t bratemask;
-- uint8_t aloft[8];
-- uint8_t rssical[8];
--};
--
--
--enum {
-- LM_TRAP_SCAN = 0,
-- LM_TRAP_TIMER,
-- LM_TRAP_BEACON_TX,
-- LM_TRAP_FAA_RADIO_ON,
-- LM_TRAP_FAA_RADIO_OFF,
-- LM_TRAP_RADAR,
-- LM_TRAP_NO_BEACON,
-- LM_TRAP_TBTT,
-- LM_TRAP_SCO_ENTER,
-- LM_TRAP_SCO_EXIT
--};
--
--struct s_lmo_trap {
-- uint16_t event;
-- uint16_t frequency;
--};
--
--struct s_lmo_timer {
-- uint32_t interval;
--};
--
--struct s_lmo_nav {
-- uint32_t period;
--};
--
--
--struct s_lmo_edcf_queue;
--
--struct s_lmo_edcf {
-- uint8_t flags;
-- uint8_t slottime;
-- uint8_t sifs;
-- uint8_t eofpad;
-- struct s_lmo_edcf_queue {
-- uint8_t aifs;
-- uint8_t pad0;
-- uint16_t cwmin;
-- uint16_t cwmax;
-- uint16_t txop;
-- } queues[8];
-- uint8_t mapping[4];
-- uint16_t maxburst;
-- uint16_t round_trip_delay;
--};
--
--struct s_lmo_keycache {
-- uint8_t entry;
-- uint8_t keyid;
-- uint8_t address[6];
-- uint8_t pad[2];
-- uint8_t keytype;
-- uint8_t keylen;
-- uint8_t key[24];
--};
--
--
--struct s_lm_interval;
--
--struct s_lmo_psm {
-- uint16_t flags;
-- uint16_t aid;
-- struct s_lm_interval {
-- uint16_t interval;
-- uint16_t periods;
-- } intervals[4];
-- /* uint16_t pad; */
-- uint8_t beacon_rcpi_skip_max;
-- uint8_t rcpi_delta_threshold;
-- uint8_t nr;
-- uint8_t exclude[1];
--};
--
--#define MC_FILTER_ADDRESS_NUM 4
--
--struct s_lmo_group_address_table {
-- uint16_t filter_enable;
-- uint16_t num_address;
-- uint8_t macaddr_list[MC_FILTER_ADDRESS_NUM][6];
--};
--
--struct s_lmo_txcancel {
-- uint32_t address[1];
--};
--
--
--struct s_lmo_tx {
-- uint8_t flags;
-- uint8_t retries;
-- uint8_t rcpi;
-- uint8_t sq;
-- uint16_t seqctrl;
-- uint8_t antenna;
-- uint8_t pad;
--};
--
--struct s_lmo_burst {
-- uint8_t flags;
-- uint8_t queue;
-- uint8_t backlog;
-- uint8_t pad;
-- uint16_t durations[32];
--};
--
--struct s_lmo_stats {
-- uint32_t valid;
-- uint32_t fcs;
-- uint32_t abort;
-- uint32_t phyabort;
-- uint32_t rts_success;
-- uint32_t rts_fail;
-- uint32_t timestamp;
-- uint32_t time_tx;
-- uint32_t noisefloor;
-- uint32_t sample_noise[8];
-- uint32_t sample_cca;
-- uint32_t sample_tx;
--};
--
--
--struct s_lmo_led {
-- uint16_t flags;
-- uint16_t mask[2];
-- uint16_t delay/*[2]*/;
--};
--
--
--struct s_lmo_bt_balancer {
-- uint16_t prio_thresh;
-- uint16_t acl_thresh;
--};
--
--
--struct s_lmo_arp_table {
-- uint16_t filter_enable;
-- uint32_t ipaddr;
--};
--
--#endif /* __ASSEMBLER__ */
--
--#endif /* __lmac_h__ */
diff --git a/staging.current/staging-rtl8187se-rtl8192e-rtl8192su-allow-module-unload.patch b/staging.current/staging-rtl8187se-rtl8192e-rtl8192su-allow-module-unload.patch
deleted file mode 100644
index bc0e8ee5cc44a9..00000000000000
--- a/staging.current/staging-rtl8187se-rtl8192e-rtl8192su-allow-module-unload.patch
+++ /dev/null
@@ -1,420 +0,0 @@
-From herton@mandriva.com.br Mon Oct 26 14:34:06 2009
-From: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
-Date: Fri, 2 Oct 2009 11:03:38 -0300
-Subject: Staging: rtl8187se/rtl8192e/rtl8192su: allow module unload
-To: "Greg Kroah-Hartman" <greg@kroah.com>
-Cc: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>, devel@driverdev.osuosl.org
-Message-ID: <200910021103.38386.herton@mandriva.com.br>
-
-
-On rtl81* additions, they had its wireless stack made builtin instead of
-separated modules. But try_module_get/module_put in stack were kept,
-they are uneeded with the stack builtin and makes rtl81* modules
-impossible to remove on a system with an rtl81* card. request_module
-calls are also uneeded with stack builtin, so remove them too.
-
-Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
-Cc: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/staging/rtl8187se/ieee80211/ieee80211_crypt.c | 4 ---
- drivers/staging/rtl8187se/ieee80211/ieee80211_module.c | 4 ---
- drivers/staging/rtl8187se/ieee80211/ieee80211_softmac.c | 12 +++------
- drivers/staging/rtl8187se/ieee80211/ieee80211_wx.c | 17 +++---------
- drivers/staging/rtl8192e/ieee80211/ieee80211_crypt.c | 8 ------
- drivers/staging/rtl8192e/ieee80211/ieee80211_module.c | 8 ------
- drivers/staging/rtl8192e/ieee80211/ieee80211_softmac.c | 19 ++++----------
- drivers/staging/rtl8192e/ieee80211/ieee80211_wx.c | 21 +++-------------
- drivers/staging/rtl8192su/ieee80211/ieee80211_crypt.c | 4 ---
- drivers/staging/rtl8192su/ieee80211/ieee80211_module.c | 4 ---
- drivers/staging/rtl8192su/ieee80211/ieee80211_softmac.c | 15 ++++-------
- drivers/staging/rtl8192su/ieee80211/ieee80211_wx.c | 17 +++---------
- 12 files changed, 37 insertions(+), 96 deletions(-)
-
---- a/drivers/staging/rtl8187se/ieee80211/ieee80211_crypt.c
-+++ b/drivers/staging/rtl8187se/ieee80211/ieee80211_crypt.c
-@@ -53,10 +53,8 @@ void ieee80211_crypt_deinit_entries(stru
-
- list_del(ptr);
-
-- if (entry->ops) {
-+ if (entry->ops)
- entry->ops->deinit(entry->priv);
-- module_put(entry->ops->owner);
-- }
- kfree(entry);
- }
- }
---- a/drivers/staging/rtl8187se/ieee80211/ieee80211_module.c
-+++ b/drivers/staging/rtl8187se/ieee80211/ieee80211_module.c
-@@ -189,10 +189,8 @@ void free_ieee80211(struct net_device *d
- for (i = 0; i < WEP_KEYS; i++) {
- struct ieee80211_crypt_data *crypt = ieee->crypt[i];
- if (crypt) {
-- if (crypt->ops) {
-+ if (crypt->ops)
- crypt->ops->deinit(crypt->priv);
-- module_put(crypt->ops->owner);
-- }
- kfree(crypt);
- ieee->crypt[i] = NULL;
- }
---- a/drivers/staging/rtl8187se/ieee80211/ieee80211_softmac.c
-+++ b/drivers/staging/rtl8187se/ieee80211/ieee80211_softmac.c
-@@ -2839,16 +2839,12 @@ static int ieee80211_wpa_set_encryption(
- goto skip_host_crypt;
-
- ops = ieee80211_get_crypto_ops(param->u.crypt.alg);
-- if (ops == NULL && strcmp(param->u.crypt.alg, "WEP") == 0) {
-- request_module("ieee80211_crypt_wep");
-+ if (ops == NULL && strcmp(param->u.crypt.alg, "WEP") == 0)
- ops = ieee80211_get_crypto_ops(param->u.crypt.alg);
-- } else if (ops == NULL && strcmp(param->u.crypt.alg, "TKIP") == 0) {
-- request_module("ieee80211_crypt_tkip");
-+ else if (ops == NULL && strcmp(param->u.crypt.alg, "TKIP") == 0)
- ops = ieee80211_get_crypto_ops(param->u.crypt.alg);
-- } else if (ops == NULL && strcmp(param->u.crypt.alg, "CCMP") == 0) {
-- request_module("ieee80211_crypt_ccmp");
-+ else if (ops == NULL && strcmp(param->u.crypt.alg, "CCMP") == 0)
- ops = ieee80211_get_crypto_ops(param->u.crypt.alg);
-- }
- if (ops == NULL) {
- printk("unknown crypto alg '%s'\n", param->u.crypt.alg);
- param->u.crypt.err = IEEE_CRYPT_ERR_UNKNOWN_ALG;
-@@ -2869,7 +2865,7 @@ static int ieee80211_wpa_set_encryption(
- }
- memset(new_crypt, 0, sizeof(struct ieee80211_crypt_data));
- new_crypt->ops = ops;
-- if (new_crypt->ops && try_module_get(new_crypt->ops->owner))
-+ if (new_crypt->ops)
- new_crypt->priv =
- new_crypt->ops->init(param->u.crypt.idx);
-
---- a/drivers/staging/rtl8187se/ieee80211/ieee80211_wx.c
-+++ b/drivers/staging/rtl8187se/ieee80211/ieee80211_wx.c
-@@ -331,12 +331,10 @@ int ieee80211_wx_set_encode(struct ieee8
- return -ENOMEM;
- memset(new_crypt, 0, sizeof(struct ieee80211_crypt_data));
- new_crypt->ops = ieee80211_get_crypto_ops("WEP");
-- if (!new_crypt->ops) {
-- request_module("ieee80211_crypt_wep");
-+ if (!new_crypt->ops)
- new_crypt->ops = ieee80211_get_crypto_ops("WEP");
-- }
-
-- if (new_crypt->ops && try_module_get(new_crypt->ops->owner))
-+ if (new_crypt->ops)
- new_crypt->priv = new_crypt->ops->init(key);
-
- if (!new_crypt->ops || !new_crypt->priv) {
-@@ -483,7 +481,7 @@ int ieee80211_wx_set_encode_ext(struct i
- struct iw_encode_ext *ext = (struct iw_encode_ext *)extra;
- int i, idx, ret = 0;
- int group_key = 0;
-- const char *alg, *module;
-+ const char *alg;
- struct ieee80211_crypto_ops *ops;
- struct ieee80211_crypt_data **crypt;
-
-@@ -539,15 +537,12 @@ int ieee80211_wx_set_encode_ext(struct i
- switch (ext->alg) {
- case IW_ENCODE_ALG_WEP:
- alg = "WEP";
-- module = "ieee80211_crypt_wep";
- break;
- case IW_ENCODE_ALG_TKIP:
- alg = "TKIP";
-- module = "ieee80211_crypt_tkip";
- break;
- case IW_ENCODE_ALG_CCMP:
- alg = "CCMP";
-- module = "ieee80211_crypt_ccmp";
- break;
- default:
- IEEE80211_DEBUG_WX("%s: unknown crypto alg %d\n",
-@@ -558,10 +553,8 @@ int ieee80211_wx_set_encode_ext(struct i
- // printk("8-09-08-9=====>%s, alg name:%s\n",__func__, alg);
-
- ops = ieee80211_get_crypto_ops(alg);
-- if (ops == NULL) {
-- request_module(module);
-+ if (ops == NULL)
- ops = ieee80211_get_crypto_ops(alg);
-- }
- if (ops == NULL) {
- IEEE80211_DEBUG_WX("%s: unknown crypto alg %d\n",
- dev->name, ext->alg);
-@@ -581,7 +574,7 @@ int ieee80211_wx_set_encode_ext(struct i
- goto done;
- }
- new_crypt->ops = ops;
-- if (new_crypt->ops && try_module_get(new_crypt->ops->owner))
-+ if (new_crypt->ops)
- new_crypt->priv = new_crypt->ops->init(idx);
- if (new_crypt->priv == NULL) {
- kfree(new_crypt);
---- a/drivers/staging/rtl8192e/ieee80211/ieee80211_crypt.c
-+++ b/drivers/staging/rtl8192e/ieee80211/ieee80211_crypt.c
-@@ -53,14 +53,8 @@ void ieee80211_crypt_deinit_entries(stru
-
- list_del(ptr);
-
-- if (entry->ops) {
-+ if (entry->ops)
- entry->ops->deinit(entry->priv);
--#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0)
-- module_put(entry->ops->owner);
--#else
-- __MOD_DEC_USE_COUNT(entry->ops->owner);
--#endif
-- }
- kfree(entry);
- }
- }
---- a/drivers/staging/rtl8192e/ieee80211/ieee80211_module.c
-+++ b/drivers/staging/rtl8192e/ieee80211/ieee80211_module.c
-@@ -242,14 +242,8 @@ void free_ieee80211(struct net_device *d
- for (i = 0; i < WEP_KEYS; i++) {
- struct ieee80211_crypt_data *crypt = ieee->crypt[i];
- if (crypt) {
-- if (crypt->ops) {
-+ if (crypt->ops)
- crypt->ops->deinit(crypt->priv);
--#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0)
-- module_put(crypt->ops->owner);
--#else
-- __MOD_DEC_USE_COUNT(crypt->ops->owner);
--#endif
-- }
- kfree(crypt);
- ieee->crypt[i] = NULL;
- }
---- a/drivers/staging/rtl8192e/ieee80211/ieee80211_softmac.c
-+++ b/drivers/staging/rtl8192e/ieee80211/ieee80211_softmac.c
-@@ -3284,17 +3284,14 @@ static int ieee80211_wpa_set_encryption(
- goto skip_host_crypt;
-
- ops = ieee80211_get_crypto_ops(param->u.crypt.alg);
-- if (ops == NULL && strcmp(param->u.crypt.alg, "WEP") == 0) {
-- request_module("ieee80211_crypt_wep");
-+ if (ops == NULL && strcmp(param->u.crypt.alg, "WEP") == 0)
- ops = ieee80211_get_crypto_ops(param->u.crypt.alg);
-- //set WEP40 first, it will be modified according to WEP104 or WEP40 at other place
-- } else if (ops == NULL && strcmp(param->u.crypt.alg, "TKIP") == 0) {
-- request_module("ieee80211_crypt_tkip");
-+ /* set WEP40 first, it will be modified according to WEP104 or
-+ * WEP40 at other place */
-+ else if (ops == NULL && strcmp(param->u.crypt.alg, "TKIP") == 0)
- ops = ieee80211_get_crypto_ops(param->u.crypt.alg);
-- } else if (ops == NULL && strcmp(param->u.crypt.alg, "CCMP") == 0) {
-- request_module("ieee80211_crypt_ccmp");
-+ else if (ops == NULL && strcmp(param->u.crypt.alg, "CCMP") == 0)
- ops = ieee80211_get_crypto_ops(param->u.crypt.alg);
-- }
- if (ops == NULL) {
- printk("unknown crypto alg '%s'\n", param->u.crypt.alg);
- param->u.crypt.err = IEEE_CRYPT_ERR_UNKNOWN_ALG;
-@@ -3315,11 +3312,7 @@ static int ieee80211_wpa_set_encryption(
- }
- memset(new_crypt, 0, sizeof(struct ieee80211_crypt_data));
- new_crypt->ops = ops;
--#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0)
-- if (new_crypt->ops && try_module_get(new_crypt->ops->owner))
--#else
-- if (new_crypt->ops && try_inc_mod_count(new_crypt->ops->owner))
--#endif
-+ if (new_crypt->ops)
- new_crypt->priv =
- new_crypt->ops->init(param->u.crypt.idx);
-
---- a/drivers/staging/rtl8192e/ieee80211/ieee80211_wx.c
-+++ b/drivers/staging/rtl8192e/ieee80211/ieee80211_wx.c
-@@ -482,15 +482,9 @@ int ieee80211_wx_set_encode(struct ieee8
- return -ENOMEM;
- memset(new_crypt, 0, sizeof(struct ieee80211_crypt_data));
- new_crypt->ops = ieee80211_get_crypto_ops("WEP");
-- if (!new_crypt->ops) {
-- request_module("ieee80211_crypt_wep");
-+ if (!new_crypt->ops)
- new_crypt->ops = ieee80211_get_crypto_ops("WEP");
-- }
--#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0)
-- if (new_crypt->ops && try_module_get(new_crypt->ops->owner))
--#else
-- if (new_crypt->ops && try_inc_mod_count(new_crypt->ops->owner))
--#endif
-+ if (new_crypt->ops)
- new_crypt->priv = new_crypt->ops->init(key);
-
- if (!new_crypt->ops || !new_crypt->priv) {
-@@ -644,7 +638,7 @@ int ieee80211_wx_set_encode_ext(struct i
- struct iw_encode_ext *ext = (struct iw_encode_ext *)extra;
- int i, idx;
- int group_key = 0;
-- const char *alg, *module;
-+ const char *alg;
- struct ieee80211_crypto_ops *ops;
- struct ieee80211_crypt_data **crypt;
-
-@@ -711,15 +705,12 @@ int ieee80211_wx_set_encode_ext(struct i
- switch (ext->alg) {
- case IW_ENCODE_ALG_WEP:
- alg = "WEP";
-- module = "ieee80211_crypt_wep";
- break;
- case IW_ENCODE_ALG_TKIP:
- alg = "TKIP";
-- module = "ieee80211_crypt_tkip";
- break;
- case IW_ENCODE_ALG_CCMP:
- alg = "CCMP";
-- module = "ieee80211_crypt_ccmp";
- break;
- default:
- IEEE80211_DEBUG_WX("%s: unknown crypto alg %d\n",
-@@ -730,10 +721,8 @@ int ieee80211_wx_set_encode_ext(struct i
- printk("alg name:%s\n",alg);
-
- ops = ieee80211_get_crypto_ops(alg);
-- if (ops == NULL) {
-- request_module(module);
-+ if (ops == NULL)
- ops = ieee80211_get_crypto_ops(alg);
-- }
- if (ops == NULL) {
- IEEE80211_DEBUG_WX("%s: unknown crypto alg %d\n",
- dev->name, ext->alg);
-@@ -758,7 +747,7 @@ int ieee80211_wx_set_encode_ext(struct i
- goto done;
- }
- new_crypt->ops = ops;
-- if (new_crypt->ops && try_module_get(new_crypt->ops->owner))
-+ if (new_crypt->ops)
- new_crypt->priv = new_crypt->ops->init(idx);
- if (new_crypt->priv == NULL) {
- kfree(new_crypt);
---- a/drivers/staging/rtl8192su/ieee80211/ieee80211_crypt.c
-+++ b/drivers/staging/rtl8192su/ieee80211/ieee80211_crypt.c
-@@ -53,10 +53,8 @@ void ieee80211_crypt_deinit_entries(stru
-
- list_del(ptr);
-
-- if (entry->ops) {
-+ if (entry->ops)
- entry->ops->deinit(entry->priv);
-- module_put(entry->ops->owner);
-- }
- kfree(entry);
- }
- }
---- a/drivers/staging/rtl8192su/ieee80211/ieee80211_module.c
-+++ b/drivers/staging/rtl8192su/ieee80211/ieee80211_module.c
-@@ -216,10 +216,8 @@ void free_ieee80211(struct net_device *d
- for (i = 0; i < WEP_KEYS; i++) {
- struct ieee80211_crypt_data *crypt = ieee->crypt[i];
- if (crypt) {
-- if (crypt->ops) {
-+ if (crypt->ops)
- crypt->ops->deinit(crypt->priv);
-- module_put(crypt->ops->owner);
-- }
- kfree(crypt);
- ieee->crypt[i] = NULL;
- }
---- a/drivers/staging/rtl8192su/ieee80211/ieee80211_softmac.c
-+++ b/drivers/staging/rtl8192su/ieee80211/ieee80211_softmac.c
-@@ -3026,17 +3026,14 @@ static int ieee80211_wpa_set_encryption(
- goto skip_host_crypt;
-
- ops = ieee80211_get_crypto_ops(param->u.crypt.alg);
-- if (ops == NULL && strcmp(param->u.crypt.alg, "WEP") == 0) {
-- request_module("ieee80211_crypt_wep");
-+ if (ops == NULL && strcmp(param->u.crypt.alg, "WEP") == 0)
- ops = ieee80211_get_crypto_ops(param->u.crypt.alg);
-- //set WEP40 first, it will be modified according to WEP104 or WEP40 at other place
-- } else if (ops == NULL && strcmp(param->u.crypt.alg, "TKIP") == 0) {
-- request_module("ieee80211_crypt_tkip");
-+ /* set WEP40 first, it will be modified according to WEP104 or
-+ * WEP40 at other place */
-+ else if (ops == NULL && strcmp(param->u.crypt.alg, "TKIP") == 0)
- ops = ieee80211_get_crypto_ops(param->u.crypt.alg);
-- } else if (ops == NULL && strcmp(param->u.crypt.alg, "CCMP") == 0) {
-- request_module("ieee80211_crypt_ccmp");
-+ else if (ops == NULL && strcmp(param->u.crypt.alg, "CCMP") == 0)
- ops = ieee80211_get_crypto_ops(param->u.crypt.alg);
-- }
- if (ops == NULL) {
- printk("unknown crypto alg '%s'\n", param->u.crypt.alg);
- param->u.crypt.err = IEEE_CRYPT_ERR_UNKNOWN_ALG;
-@@ -3058,7 +3055,7 @@ static int ieee80211_wpa_set_encryption(
- memset(new_crypt, 0, sizeof(struct ieee80211_crypt_data));
- new_crypt->ops = ops;
-
-- if (new_crypt->ops && try_module_get(new_crypt->ops->owner))
-+ if (new_crypt->ops)
- new_crypt->priv =
- new_crypt->ops->init(param->u.crypt.idx);
-
---- a/drivers/staging/rtl8192su/ieee80211/ieee80211_wx.c
-+++ b/drivers/staging/rtl8192su/ieee80211/ieee80211_wx.c
-@@ -358,11 +358,9 @@ int ieee80211_wx_set_encode(struct ieee8
- return -ENOMEM;
- memset(new_crypt, 0, sizeof(struct ieee80211_crypt_data));
- new_crypt->ops = ieee80211_get_crypto_ops("WEP");
-- if (!new_crypt->ops) {
-- request_module("ieee80211_crypt_wep");
-+ if (!new_crypt->ops)
- new_crypt->ops = ieee80211_get_crypto_ops("WEP");
-- }
-- if (new_crypt->ops && try_module_get(new_crypt->ops->owner))
-+ if (new_crypt->ops)
- new_crypt->priv = new_crypt->ops->init(key);
-
- if (!new_crypt->ops || !new_crypt->priv) {
-@@ -507,7 +505,7 @@ int ieee80211_wx_set_encode_ext(struct i
- struct iw_encode_ext *ext = (struct iw_encode_ext *)extra;
- int i, idx;
- int group_key = 0;
-- const char *alg, *module;
-+ const char *alg;
- struct ieee80211_crypto_ops *ops;
- struct ieee80211_crypt_data **crypt;
-
-@@ -570,15 +568,12 @@ int ieee80211_wx_set_encode_ext(struct i
- switch (ext->alg) {
- case IW_ENCODE_ALG_WEP:
- alg = "WEP";
-- module = "ieee80211_crypt_wep";
- break;
- case IW_ENCODE_ALG_TKIP:
- alg = "TKIP";
-- module = "ieee80211_crypt_tkip";
- break;
- case IW_ENCODE_ALG_CCMP:
- alg = "CCMP";
-- module = "ieee80211_crypt_ccmp";
- break;
- default:
- IEEE80211_DEBUG_WX("%s: unknown crypto alg %d\n",
-@@ -589,10 +584,8 @@ int ieee80211_wx_set_encode_ext(struct i
- printk("alg name:%s\n",alg);
-
- ops = ieee80211_get_crypto_ops(alg);
-- if (ops == NULL) {
-- request_module("%s", module);
-+ if (ops == NULL)
- ops = ieee80211_get_crypto_ops(alg);
-- }
- if (ops == NULL) {
- IEEE80211_DEBUG_WX("%s: unknown crypto alg %d\n",
- dev->name, ext->alg);
-@@ -612,7 +605,7 @@ int ieee80211_wx_set_encode_ext(struct i
- goto done;
- }
- new_crypt->ops = ops;
-- if (new_crypt->ops && try_module_get(new_crypt->ops->owner))
-+ if (new_crypt->ops)
- new_crypt->priv = new_crypt->ops->init(idx);
- if (new_crypt->priv == NULL) {
- kfree(new_crypt);
diff --git a/staging.current/staging-vt6656-fix-the-memory-free-bug-in-vntwusb_disconnect.patch b/staging.current/staging-vt6656-fix-the-memory-free-bug-in-vntwusb_disconnect.patch
deleted file mode 100644
index 28f82859125ad0..00000000000000
--- a/staging.current/staging-vt6656-fix-the-memory-free-bug-in-vntwusb_disconnect.patch
+++ /dev/null
@@ -1,119 +0,0 @@
-From miaofng@gmail.com Mon Oct 26 14:33:02 2009
-From: "miaofng" <miaofng@gmail.com>
-Date: Tue, 29 Sep 2009 15:02:53 +0800
-Subject: Staging: vt6656: fix the memory free bug in vntwusb_disconnect()
-To: "gregkh" <gregkh@suse.de>
-Cc: "forest" <forest@alittletooquiet.net>
-Message-ID: <200909291502378129041@gmail.com>
-
-
-This patch is used to solve the memory bug when people plug out the wusb card then plug in.
-Error logs are following:
-
-root@smdk2440:~# ifdown eth1
-AP deauthed me, reason=2.
-Config_FileOperation file Not exist
-Zone=[1][J][P]!!
-WPA: Terminating
-root@smdk2440:~# ----> !!!!!!!!!!!!!!here plug out the wusbcard
-usb 1-1: USB disconnect, address 4
-----> !!!!!!!!!!!!!!!!!!!here plug in the wusb card
-usb 1-1: new full speed USB device using s3c2410-ohci and address 5
-usb 1-1: New USB device found, idVendor=160a, idProduct=3184
-usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
-usb 1-1: Product: VNT USB-802.11 Wireless LAN Adapter
-usb 1-1: Manufacturer: VIA Networking Technologies, Inc.
-usb 1-1: configuration #1 chosen from 1 choice
-VIA Networking Wireless LAN USB Driver Ver. 1.19_12
-Copyright (c) 2004 VIA Networking Technologies, Inc.
-kernel BUG at mm/slab.c:2974!
-Unable to handle kernel NULL pointer dereference at virtual address 00000000
-pgd = c0004000
-[00000000] *pgd=00000000
-Internal error: Oops: 817 [#1] PREEMPT
-Modules linked in: vt6656_stage
-CPU: 0 Not tainted (2.6.32-rc2 #14)
-PC is at __bug+0x1c/0x28
-LR is at __bug+0x18/0x28
-pc : [<c002fb10>] lr : [<c002fb0c>] psr: 40000093
-sp : c3867c68 ip : c3867bd0 fp : c3866000
-r10: c3800600 r9 : c3802430 r8 : 00000004
-r7 : c3802428 r6 : c3802660 r5 : c3802420 r4 : a0000013
-r3 : 00000000 r2 : c3866000 r1 : 00000003 r0 : 00000024
-Flags: nZcv IRQs off FIQs on Mode SVC_32 ISA ARM Segment kernel
-Control: 0000717f Table: 330a8000 DAC: 00000017
-Process khubd (pid: 152, stack limit = 0xc3866270)
-Stack: (0xc3867c68 to 0xc3868000)
-7c60: c0093fdc c0094088 000000d0 000000d0 00000000 000080d0
-7c80: 00000000 a0000013 c39ebec0 c3800600 000080d0 00000001 c03f13cc 00000006
-7ca0: c02b36f0 c0094574 c0043428 0001c9de c39ebec0 c39ebea0 c3000c00 c02a6a84
-7cc0: 89705f41 c3000c00 c39ebec0 c39ebea0 c3000c00 bf036f24 c39ebec8 00000006
-7ce0: 00000000 c3000c00 c39ebec0 c39ebea0 c3000c00 bf036f24 c39ebec8 00000006
-7d00: 00000000 bf003398 c00aa514 c3867d20 0000a1ff c00e1448 c39d9f84 c39aabe8
-7d20: c3867d50 c00e1888 c39aabe8 c39ebea0 c39ebec0 bf036ebc c3000c00 bf036f24
-7d40: 0000bec8 01000000 00000000 c39ebea0 c39ebec0 bf036ebc c3000c00 bf036f24
-7d60: c39ebec8 00000000 00000000 c0223798 c39ebec0 c01daa14 bf036eec c3867da0
-7d80: c045a4f8 c01da6e4 c39ebec0 00000000 c01daa14 c39ebec0 c3867da0 c01d9870
-7da0: c38331a8 c39fcb94 c005b3b4 c39ebec0 c39ebec0 c39ebef4 00000000 c01da890
-7dc0: c39ebec0 c39ebec0 c3000c00 c01d97f4 00000000 c01d8470 c39ebea0 c3000c68
-7de0: 00000000 c3000c68 c3218a00 c3abcd20 00000001 c39ebec0 c39ebea0 c3000c00
-7e00: 00000000 c3000c68 c3218a00 c3abcd20 00000001 c0221ee8 00000001 00000000
-7e20: 00000000 00000000 00001388 00000000 c3000c04 c3000c68 c3bc29c0 00000001
-7e40: c3bc29c4 00000001 c03f4af8 00000000 c39fe780 c3000c00 00000001 c045ab04
-7e60: c3867eb8 c045a3bc c3000c70 00000000 00000000 c0229238 c3000c68 c0223210
-7e80: c3000c00 c045aaf0 c045ab04 c0223230 c3000c68 c01daa14 c045ab04 c01da6e4
-7ea0: c3000c68 00000000 c01daa14 c3000c68 c3867eb8 c01d9870 c38331a8 c3862f54
-7ec0: c005b3b4 c3000c68 c3000c68 c3000c9c 00000002 c01da890 c3867ef9 c3000c68
-7ee0: c3829f60 c01d97f4 00000000 c01d8470 c38918e0 c3aaf468 39383102 c300343a
-7f00: 00000001 c0219660 c03f1768 c3000c00 00000000 c3000c68 00000002 c3aaf814
-7f20: 00000001 00000101 c38918e0 c021b6e0 00000002 00000000 00000000 c3000c00
-7f40: c38917c0 c021c418 00000064 00000064 00000101 c3867f60 c005b920 c3867f94
-7f60: c3891830 c3aaf400 c3866000 c3aaf400 c3aaf800 00000000 c38918e0 c3aaf400
-7f80: 00000012 00000000 00000000 c3837920 c00574a0 c3867f94 c3867f94 00000101
-7fa0: 01010001 c3867fd4 c381bf48 c3867fd4 c381bf48 00000000 c021ba3c 00000000
-7fc0: 00000000 00000000 00000000 c00573dc 00000000 00000000 c3867fd8 c3867fd8
-7fe0: 00000000 00000000 00000000 00000000 00000000 c002ce88 00000000 ffff0000
-[<c002fb10>] (__bug+0x1c/0x28) from [<c0094088>] (cache_alloc_refill+0x13c/0x594)
-[<c0094088>] (cache_alloc_refill+0x13c/0x594) from [<c0094574>] (__kmalloc+0x94/0xd0)
-[<c0094574>] (__kmalloc+0x94/0xd0) from [<c02a6a84>] (alloc_netdev_mq+0x48/0x1b0)
-[<c02a6a84>] (alloc_netdev_mq+0x48/0x1b0) from [<bf003398>] (vntwusb_found1+0x58/0x53c [vt6656_stage])
-[<bf003398>] (vntwusb_found1+0x58/0x53c [vt6656_stage]) from [<c0223798>] (usb_probe_interface+0x130/0x180)
-[<c0223798>] (usb_probe_interface+0x130/0x180) from [<c01da6e4>] (driver_probe_device+0xac/0x164)
-[<c01da6e4>] (driver_probe_device+0xac/0x164) from [<c01d9870>] (bus_for_each_drv+0x50/0x90)
-[<c01d9870>] (bus_for_each_drv+0x50/0x90) from [<c01da890>] (device_attach+0x50/0x68)
-[<c01da890>] (device_attach+0x50/0x68) from [<c01d97f4>] (bus_probe_device+0x28/0x54)
-[<c01d97f4>] (bus_probe_device+0x28/0x54) from [<c01d8470>] (device_add+0x3b4/0x4f0)
-[<c01d8470>] (device_add+0x3b4/0x4f0) from [<c0221ee8>] (usb_set_configuration+0x524/0x5b8)
-[<c0221ee8>] (usb_set_configuration+0x524/0x5b8) from [<c0229238>] (generic_probe+0x5c/0xa0)
-[<c0229238>] (generic_probe+0x5c/0xa0) from [<c0223230>] (usb_probe_device+0x48/0x54)
-[<c0223230>] (usb_probe_device+0x48/0x54) from [<c01da6e4>] (driver_probe_device+0xac/0x164)
-[<c01da6e4>] (driver_probe_device+0xac/0x164) from [<c01d9870>] (bus_for_each_drv+0x50/0x90)
-[<c01d9870>] (bus_for_each_drv+0x50/0x90) from [<c01da890>] (device_attach+0x50/0x68)
-[<c01da890>] (device_attach+0x50/0x68) from [<c01d97f4>] (bus_probe_device+0x28/0x54)
-[<c01d97f4>] (bus_probe_device+0x28/0x54) from [<c01d8470>] (device_add+0x3b4/0x4f0)
-[<c01d8470>] (device_add+0x3b4/0x4f0) from [<c021b6e0>] (usb_new_device+0x100/0x174)
-[<c021b6e0>] (usb_new_device+0x100/0x174) from [<c021c418>] (hub_thread+0x9dc/0xeec)
-[<c021c418>] (hub_thread+0x9dc/0xeec) from [<c00573dc>] (kthread+0x78/0x80)
-[<c00573dc>] (kthread+0x78/0x80) from [<c002ce88>] (kernel_thread_exit+0x0/0x8)
-Code: e1a01000 e59f000c eb005014 e3a03000 (e5833000)
----[ end trace 2a51e0dbab9e4fbe ]---
-note: khubd[152] exited with preempt_count 1
-
-
-Signed-off-by: miaofng <miaofng@gmail.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/staging/vt6656/main_usb.c | 1 -
- 1 file changed, 1 deletion(-)
-
---- a/drivers/staging/vt6656/main_usb.c
-+++ b/drivers/staging/vt6656/main_usb.c
-@@ -1332,7 +1332,6 @@ device_release_WPADEV(pDevice);
- free_netdev(pDevice->dev);
- }
-
-- kfree(pDevice);
- DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "device_disconnect3.. \n");
- }
-
diff --git a/staging.current/staging-wireless-drivers-kconfig-change.patch b/staging.current/staging-wireless-drivers-kconfig-change.patch
deleted file mode 100644
index 77eea83d995fa2..00000000000000
--- a/staging.current/staging-wireless-drivers-kconfig-change.patch
+++ /dev/null
@@ -1,79 +0,0 @@
-From foo@baz Tue Oct 27 15:46:18 PDT 2009
-Date: Tue, 27 Oct 2009 15:46:18 -0700
-To: Greg KH <greg@kroah.com>
-From: Greg Kroah-Hartman <gregkh@suse.de>
-Subject: Staging: wireless drivers Kconfig change
-
-Change the wireless drivers to depend on CONFIG_WLAN instead of
-CONFIG_WLAN_80211 which is going away soon.
-
-
-Cc: John W. Linville <linville@tuxdriver.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/staging/otus/Kconfig | 2 +-
- drivers/staging/rt2860/Kconfig | 2 +-
- drivers/staging/rt2870/Kconfig | 2 +-
- drivers/staging/rt3090/Kconfig | 2 +-
- drivers/staging/winbond/Kconfig | 2 +-
- drivers/staging/wlan-ng/Kconfig | 2 +-
- 6 files changed, 6 insertions(+), 6 deletions(-)
-
---- a/drivers/staging/otus/Kconfig
-+++ b/drivers/staging/otus/Kconfig
-@@ -1,6 +1,6 @@
- config OTUS
- tristate "Atheros OTUS 802.11n USB wireless support"
-- depends on USB && WLAN_80211 && MAC80211
-+ depends on USB && WLAN && MAC80211
- default N
- ---help---
- Enable support for Atheros 802.11n USB hardware:
---- a/drivers/staging/rt2860/Kconfig
-+++ b/drivers/staging/rt2860/Kconfig
-@@ -1,5 +1,5 @@
- config RT2860
- tristate "Ralink 2860 wireless support"
-- depends on PCI && X86 && WLAN_80211
-+ depends on PCI && X86 && WLAN
- ---help---
- This is an experimental driver for the Ralink 2860 wireless chip.
---- a/drivers/staging/rt2870/Kconfig
-+++ b/drivers/staging/rt2870/Kconfig
-@@ -1,5 +1,5 @@
- config RT2870
- tristate "Ralink 2870/3070 wireless support"
-- depends on USB && X86 && WLAN_80211
-+ depends on USB && X86 && WLAN
- ---help---
- This is an experimental driver for the Ralink xx70 wireless chips.
---- a/drivers/staging/rt3090/Kconfig
-+++ b/drivers/staging/rt3090/Kconfig
-@@ -1,5 +1,5 @@
- config RT3090
- tristate "Ralink 3090 wireless support"
-- depends on PCI && X86 && WLAN_80211
-+ depends on PCI && X86 && WLAN
- ---help---
- This is an experimental driver for the Ralink 3090 wireless chip.
---- a/drivers/staging/winbond/Kconfig
-+++ b/drivers/staging/winbond/Kconfig
-@@ -1,6 +1,6 @@
- config W35UND
- tristate "IS89C35 WLAN USB driver"
-- depends on MAC80211 && WLAN_80211 && USB && EXPERIMENTAL
-+ depends on MAC80211 && WLAN && USB && EXPERIMENTAL
- default n
- ---help---
- This is highly experimental driver for Winbond WIFI card.
---- a/drivers/staging/wlan-ng/Kconfig
-+++ b/drivers/staging/wlan-ng/Kconfig
-@@ -1,6 +1,6 @@
- config PRISM2_USB
- tristate "Prism2.5/3 USB driver"
-- depends on WLAN_80211 && USB && WIRELESS_EXT
-+ depends on WLAN && USB && WIRELESS_EXT
- default n
- ---help---
- This is the wlan-ng prism 2.5/3 USB driver for a wide range of
diff --git a/tty.current/tty-mark-generic_serial-users-as-broken.patch b/tty.current/tty-mark-generic_serial-users-as-broken.patch
deleted file mode 100644
index bcd42063d68200..00000000000000
--- a/tty.current/tty-mark-generic_serial-users-as-broken.patch
+++ /dev/null
@@ -1,78 +0,0 @@
-From alan@linux.intel.com Fri Oct 30 12:21:42 2009
-From: Alan Cox <alan@linux.intel.com>
-Date: Thu, 29 Oct 2009 12:16:22 +0000
-Subject: tty: Mark generic_serial users as BROKEN
-To: greg@kroah.com
-Message-ID: <20091029121554.11076.708.stgit@localhost.localdomain>
-
-
-There isn't much else I can do with these. I can find no hardware for any
-of them and no users. The code is broken.
-
-Signed-off-by: Alan Cox <alan@linux.intel.com>
-Cc: stable <stable@kernel.org>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
-
----
- arch/m68k/Kconfig | 6 +++---
- drivers/char/Kconfig | 6 +++---
- 2 files changed, 6 insertions(+), 6 deletions(-)
-
---- a/arch/m68k/Kconfig
-+++ b/arch/m68k/Kconfig
-@@ -561,7 +561,7 @@ config HPAPCI
-
- config MVME147_SCC
- bool "SCC support for MVME147 serial ports"
-- depends on MVME147
-+ depends on MVME147 && BROKEN
- help
- This is the driver for the serial ports on the Motorola MVME147
- boards. Everyone using one of these boards should say Y here.
-@@ -576,14 +576,14 @@ config SERIAL167
-
- config MVME162_SCC
- bool "SCC support for MVME162 serial ports"
-- depends on MVME16x
-+ depends on MVME16x && BROKEN
- help
- This is the driver for the serial ports on the Motorola MVME162 and
- 172 boards. Everyone using one of these boards should say Y here.
-
- config BVME6000_SCC
- bool "SCC support for BVME6000 serial ports"
-- depends on BVME6000
-+ depends on BVME6000 && BROKEN
- help
- This is the driver for the serial ports on the BVME4000 and BVME6000
- boards from BVM Ltd. Everyone using one of these boards should say
---- a/drivers/char/Kconfig
-+++ b/drivers/char/Kconfig
-@@ -323,7 +323,7 @@ config SPECIALIX
-
- config SX
- tristate "Specialix SX (and SI) card support"
-- depends on SERIAL_NONSTANDARD && (PCI || EISA || ISA)
-+ depends on SERIAL_NONSTANDARD && (PCI || EISA || ISA) && BROKEN
- help
- This is a driver for the SX and SI multiport serial cards.
- Please read the file <file:Documentation/serial/sx.txt> for details.
-@@ -334,7 +334,7 @@ config SX
-
- config RIO
- tristate "Specialix RIO system support"
-- depends on SERIAL_NONSTANDARD
-+ depends on SERIAL_NONSTANDARD && BROKEN
- help
- This is a driver for the Specialix RIO, a smart serial card which
- drives an outboard box that can support up to 128 ports. Product
-@@ -395,7 +395,7 @@ config NOZOMI
-
- config A2232
- tristate "Commodore A2232 serial support (EXPERIMENTAL)"
-- depends on EXPERIMENTAL && ZORRO && BROKEN_ON_SMP
-+ depends on EXPERIMENTAL && ZORRO && BROKEN
- ---help---
- This option supports the 2232 7-port serial card shipped with the
- Amiga 2000 and other Zorro-bus machines, dating from 1989. At
diff --git a/usb.current/usb-fsl_udc_core-fix-kernel-oops-on-module-removal.patch b/usb.current/usb-fsl_udc_core-fix-kernel-oops-on-module-removal.patch
deleted file mode 100644
index 30b06653c4c7eb..00000000000000
--- a/usb.current/usb-fsl_udc_core-fix-kernel-oops-on-module-removal.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-From avorontsov@ru.mvista.com Thu Oct 29 16:20:40 2009
-From: Anton Vorontsov <avorontsov@ru.mvista.com>
-Date: Thu, 29 Oct 2009 19:50:43 +0300
-Subject: [PATCH] USB: fsl_udc_core: Fix kernel oops on module removal
-To: Greg Kroah-Hartman <gregkh@suse.de>
-Cc: Li Yang <leoli@freescale.com>, Guennadi Liakhovetski <lg@denx.de>, linux-usb@vger.kernel.org, linuxppc-dev@ozlabs.org
-Message-ID: <20091029165043.GA20612@oksana.dev.rtsoft.ru>
-Content-Disposition: inline
-
-
-fsl_udc_release() calls dma_free_coherent() with an inappropriate
-device passed to it, and since the device has no dma_ops, the following
-oops pops up:
-
- Kernel BUG at d103ce9c [verbose debug info unavailable]
- Oops: Exception in kernel mode, sig: 5 [#1]
- ...
- NIP [d103ce9c] fsl_udc_release+0x50/0x80 [fsl_usb2_udc]
- LR [d103ce74] fsl_udc_release+0x28/0x80 [fsl_usb2_udc]
- Call Trace:
- [cfbc7dc0] [d103ce74] fsl_udc_release+0x28/0x80 [fsl_usb2_udc]
- [cfbc7dd0] [c01a35c4] device_release+0x2c/0x90
- [cfbc7de0] [c016b480] kobject_cleanup+0x58/0x98
- [cfbc7e00] [c016c52c] kref_put+0x54/0x6c
- [cfbc7e10] [c016b360] kobject_put+0x34/0x64
- [cfbc7e20] [c01a1d0c] put_device+0x1c/0x2c
- [cfbc7e30] [d103dbfc] fsl_udc_remove+0xc0/0x1e4 [fsl_usb2_udc]
- ...
-
-This patch fixes the issue by passing dev->parent, which points to
-a correct device.
-
-Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
-Cc: Li Yang <leoli@freescale.com>
-Cc: David Brownell <dbrownell@users.sourceforge.net>
-Cc: Guennadi Liakhovetski <lg@denx.de>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/usb/gadget/fsl_udc_core.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
---- a/drivers/usb/gadget/fsl_udc_core.c
-+++ b/drivers/usb/gadget/fsl_udc_core.c
-@@ -2139,7 +2139,7 @@ static int fsl_proc_read(char *page, cha
- static void fsl_udc_release(struct device *dev)
- {
- complete(udc_controller->done);
-- dma_free_coherent(dev, udc_controller->ep_qh_size,
-+ dma_free_coherent(dev->parent, udc_controller->ep_qh_size,
- udc_controller->ep_qh, udc_controller->ep_qh_dma);
- kfree(udc_controller);
- }
diff --git a/usb.current/usb-option-tlaytech-tue800-support.patch b/usb.current/usb-option-tlaytech-tue800-support.patch
deleted file mode 100644
index b3d50d9b214f83..00000000000000
--- a/usb.current/usb-option-tlaytech-tue800-support.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From bryan.wu@canonical.com Tue Oct 27 10:35:48 2009
-From: Bryan Wu <bryan.wu@canonical.com>
-Date: Thu, 22 Oct 2009 15:00:36 +0800
-Subject: USB: option: TLAYTECH TUE800 support
-To: smurf@smurf.noris.de
-Cc: linux-usb@vger.kernel.org, gregkh@suse.de, linux-kernel@vger.kernel.org
-Message-ID: <1256194836-15733-1-git-send-email-bryan.wu@canonical.com>
-
-
-Add ID for Tlaytech TUE800 CDMA modem to the option driver.
-
-Signed-off-by: Bryan Wu <bryan.wu@canonical.com>
-Acked-By: Matthias Urlichs <matthias@urlichs.de>
-Cc: stable <stable@kernel.org>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/usb/serial/option.c | 4 ++++
- 1 file changed, 4 insertions(+)
-
---- a/drivers/usb/serial/option.c
-+++ b/drivers/usb/serial/option.c
-@@ -315,6 +315,9 @@ static int option_resume(struct usb_ser
- #define QISDA_PRODUCT_H20_4515 0x4515
- #define QISDA_PRODUCT_H20_4519 0x4519
-
-+/* TLAYTECH PRODUCTS */
-+#define TLAYTECH_VENDOR_ID 0x20B9
-+#define TLAYTECH_PRODUCT_TEU800 0x1682
-
- /* TOSHIBA PRODUCTS */
- #define TOSHIBA_VENDOR_ID 0x0930
-@@ -593,6 +596,7 @@ static struct usb_device_id option_ids[]
- { USB_DEVICE_AND_INTERFACE_INFO(ALINK_VENDOR_ID, ALINK_PRODUCT_3GU, 0xff, 0xff, 0xff) },
- { USB_DEVICE(ALCATEL_VENDOR_ID, ALCATEL_PRODUCT_X060S) },
- { USB_DEVICE(AIRPLUS_VENDOR_ID, AIRPLUS_PRODUCT_MCD650) },
-+ { USB_DEVICE(TLAYTECH_VENDOR_ID, TLAYTECH_PRODUCT_TEU800) },
- { } /* Terminating entry */
- };
- MODULE_DEVICE_TABLE(usb, option_ids);
diff --git a/usb.current/usb-r8a66597-hcd-fix-cannot-detect-a-device-when-uses_new_polling-is-set.patch b/usb.current/usb-r8a66597-hcd-fix-cannot-detect-a-device-when-uses_new_polling-is-set.patch
deleted file mode 100644
index 2ff23a249f8137..00000000000000
--- a/usb.current/usb-r8a66597-hcd-fix-cannot-detect-a-device-when-uses_new_polling-is-set.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-From shimoda.yoshihiro@renesas.com Tue Oct 27 10:23:57 2009
-From: Yoshihiro Shimoda <shimoda.yoshihiro@renesas.com>
-Date: Wed, 21 Oct 2009 20:33:39 +0900
-Subject: USB: r8a66597-hcd: fix cannot detect a device when uses_new_polling is set
-To: Greg Kroah-Hartman <gregkh@suse.de>
-Message-ID: <4ADEF193.30204@renesas.com>
-
-
-Signed-off-by: Yoshihiro Shimoda <shimoda.yoshihiro@renesas.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/usb/host/r8a66597-hcd.c | 23 +++++++++++++----------
- 1 file changed, 13 insertions(+), 10 deletions(-)
-
---- a/drivers/usb/host/r8a66597-hcd.c
-+++ b/drivers/usb/host/r8a66597-hcd.c
-@@ -1003,19 +1003,20 @@ static void r8a66597_check_syssts(struct
- if (syssts == SE0) {
- r8a66597_write(r8a66597, ~ATTCH, get_intsts_reg(port));
- r8a66597_bset(r8a66597, ATTCHE, get_intenb_reg(port));
-- return;
-- }
-+ } else {
-+ if (syssts == FS_JSTS)
-+ r8a66597_bset(r8a66597, HSE, get_syscfg_reg(port));
-+ else if (syssts == LS_JSTS)
-+ r8a66597_bclr(r8a66597, HSE, get_syscfg_reg(port));
-
-- if (syssts == FS_JSTS)
-- r8a66597_bset(r8a66597, HSE, get_syscfg_reg(port));
-- else if (syssts == LS_JSTS)
-- r8a66597_bclr(r8a66597, HSE, get_syscfg_reg(port));
-+ r8a66597_write(r8a66597, ~DTCH, get_intsts_reg(port));
-+ r8a66597_bset(r8a66597, DTCHE, get_intenb_reg(port));
-
-- r8a66597_write(r8a66597, ~DTCH, get_intsts_reg(port));
-- r8a66597_bset(r8a66597, DTCHE, get_intenb_reg(port));
-+ if (r8a66597->bus_suspended)
-+ usb_hcd_resume_root_hub(r8a66597_to_hcd(r8a66597));
-+ }
-
-- if (r8a66597->bus_suspended)
-- usb_hcd_resume_root_hub(r8a66597_to_hcd(r8a66597));
-+ usb_hcd_poll_rh_status(r8a66597_to_hcd(r8a66597));
- }
-
- /* this function must be called with interrupt disabled */
-@@ -1024,6 +1025,8 @@ static void r8a66597_usb_connect(struct
- u16 speed = get_rh_usb_speed(r8a66597, port);
- struct r8a66597_root_hub *rh = &r8a66597->root_hub[port];
-
-+ rh->port &= ~((1 << USB_PORT_FEAT_HIGHSPEED) |
-+ (1 << USB_PORT_FEAT_LOWSPEED));
- if (speed == HSMODE)
- rh->port |= (1 << USB_PORT_FEAT_HIGHSPEED);
- else if (speed == LSMODE)
diff --git a/usb.current/usb-rndis_host-debug-info-clobbered-before-it-is-logged.patch b/usb.current/usb-rndis_host-debug-info-clobbered-before-it-is-logged.patch
deleted file mode 100644
index 18177e4643704c..00000000000000
--- a/usb.current/usb-rndis_host-debug-info-clobbered-before-it-is-logged.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From george.nassar@gmail.com Mon Oct 26 16:33:31 2009
-From: George Nassar <george.nassar@gmail.com>
-Date: Wed, 14 Oct 2009 18:27:41 -0500
-Subject: USB: rndis_host: debug info clobbered before it is logged
-To: linux-usb@vger.kernel.org, gregkh@suse.de
-Cc: george.nassar@gmail.com
-Message-ID: <4AD65E6D.3070900@gmail.com>
-
-
-The MTU throttle-down if a RNDIS device doesn't support a particular
-packet size is being incorrectly logged. The attempted packet size is
-being clobbered before it gets logged.
-
-First patch; please inform if I'm doing this incorrectly. Diff'd
-against latest official source as per the FAQ; forward port to current
-git version is straightforward.
-
-Signed-off-by: George Nassar <george.nassar@gmail.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/net/usb/rndis_host.c | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
---- a/drivers/net/usb/rndis_host.c
-+++ b/drivers/net/usb/rndis_host.c
-@@ -362,12 +362,12 @@ generic_rndis_bind(struct usbnet *dev, s
- retval = -EINVAL;
- goto halt_fail_and_release;
- }
-- dev->hard_mtu = tmp;
-- net->mtu = dev->hard_mtu - net->hard_header_len;
- dev_warn(&intf->dev,
- "dev can't take %u byte packets (max %u), "
- "adjusting MTU to %u\n",
-- dev->hard_mtu, tmp, net->mtu);
-+ dev->hard_mtu, tmp, tmp - net->hard_header_len);
-+ dev->hard_mtu = tmp;
-+ net->mtu = dev->hard_mtu - net->hard_header_len;
- }
-
- /* REVISIT: peripheral "alignment" request is ignored ... */
diff --git a/usb.current/usb-serial-sierra-driver-autopm-fixes.patch b/usb.current/usb-serial-sierra-driver-autopm-fixes.patch
deleted file mode 100644
index 7165369afc578b..00000000000000
--- a/usb.current/usb-serial-sierra-driver-autopm-fixes.patch
+++ /dev/null
@@ -1,85 +0,0 @@
-From epasheva@sierrawireless.com Wed Oct 28 09:42:05 2009
-From: Elina Pasheva <epasheva@sierrawireless.com>
-Date: Tue, 27 Oct 2009 13:49:59 -0700
-Subject: USB: serial: sierra driver autopm fixes
-To: <gregkh@suse.de>
-Cc: <rfiler@sierrawireless.com>, <epasheva@sierrawireless.com>
-Message-ID: <1256676599.4530.2.camel@Linuxdev4-laptop>
-
-
-From: Elina Pasheva <epasheva@sierrawireless.com>
-
-This patch presents fixes for the autosuspend feature implementation in
-sierra usb serial driver in functions sierra_open(), sierra_close() and
-stop_read_write_urbs().
-
-The patch "sierra_close() must resume the device before it notifies it
-of a closure" submitted by Oliver Neukum on Wed, October 14 has been
-merged as fix in sierra_close() function.
-
-The bug fix in sierra_open() function restores the autopm interface
-state on error condition.
-
-The bug fix in in stop_read_write_urbs() function assures that both
-receive and interrupt urbs are recycled.
-
-Signed-off-by: Elina Pasheva <epasheva@sierrawireless.com>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
-
----
- drivers/usb/serial/sierra.c | 14 ++++++++------
- 1 file changed, 8 insertions(+), 6 deletions(-)
-
---- a/drivers/usb/serial/sierra.c
-+++ b/drivers/usb/serial/sierra.c
-@@ -777,8 +777,11 @@ static void sierra_close(struct usb_seri
-
- if (serial->dev) {
- mutex_lock(&serial->disc_mutex);
-- if (!serial->disconnected)
-+ if (!serial->disconnected) {
-+ serial->interface->needs_remote_wakeup = 0;
-+ usb_autopm_get_interface(serial->interface);
- sierra_send_setup(port);
-+ }
- mutex_unlock(&serial->disc_mutex);
- spin_lock_irq(&intfdata->susp_lock);
- portdata->opened = 0;
-@@ -792,8 +795,6 @@ static void sierra_close(struct usb_seri
- sierra_release_urb(portdata->in_urbs[i]);
- portdata->in_urbs[i] = NULL;
- }
-- usb_autopm_get_interface(serial->interface);
-- serial->interface->needs_remote_wakeup = 0;
- }
- }
-
-@@ -831,6 +832,8 @@ static int sierra_open(struct tty_struct
- if (err) {
- /* get rid of everything as in close */
- sierra_close(port);
-+ /* restore balance for autopm */
-+ usb_autopm_put_interface(serial->interface);
- return err;
- }
- sierra_send_setup(port);
-@@ -919,7 +922,7 @@ static void sierra_release(struct usb_se
- #ifdef CONFIG_PM
- static void stop_read_write_urbs(struct usb_serial *serial)
- {
-- int i, j;
-+ int i;
- struct usb_serial_port *port;
- struct sierra_port_private *portdata;
-
-@@ -927,8 +930,7 @@ static void stop_read_write_urbs(struct
- for (i = 0; i < serial->num_ports; ++i) {
- port = serial->port[i];
- portdata = usb_get_serial_port_data(port);
-- for (j = 0; j < N_IN_URB; j++)
-- usb_kill_urb(portdata->in_urbs[j]);
-+ sierra_stop_rx_urbs(port);
- usb_kill_anchored_urbs(&portdata->active);
- }
- }
diff --git a/usb.current/usb-serial-sierra-driver-send_setup-autopm-fix.patch b/usb.current/usb-serial-sierra-driver-send_setup-autopm-fix.patch
deleted file mode 100644
index 6aa61e5a1d0af9..00000000000000
--- a/usb.current/usb-serial-sierra-driver-send_setup-autopm-fix.patch
+++ /dev/null
@@ -1,82 +0,0 @@
-From epasheva@sierrawireless.com Tue Oct 27 10:12:48 2009
-From: Elina Pasheva <epasheva@sierrawireless.com>
-Date: Fri, 16 Oct 2009 12:04:54 -0700
-Subject: USB: serial: sierra driver send_setup() autopm fix
-To: <gregkh@suse.de>
-Cc: <epasheva@sierrawireless.com>, <rfiler@sierrawireless.com>
-Message-ID: <1255719894.23492.5.camel@Linuxdev4-laptop>
-
-
-From: Elina Pasheva <epasheva@sierrawireless.com>
-
-This patch presents a fix for the autosuspend feature implementation in
-sierra usb serial driver for function sierra_send_setup(). Because it
-is possible to call sierra_send_setup() before sierra_open() or after
-sierra_close() we added a get/put interface activity to assure that the
-usb control can happen even when the device is autosuspended.
-
-Signed-off-by: Elina Pasheva <epasheva@sierrawireless.com>
-Tested-by: Matthew Safar <msafar@sierrawireless.com>
-Cc: stable <stable@kernel.org>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
-
----
- drivers/usb/serial/sierra.c | 24 ++++++++++++++----------
- 1 file changed, 14 insertions(+), 10 deletions(-)
-
---- a/drivers/usb/serial/sierra.c
-+++ b/drivers/usb/serial/sierra.c
-@@ -296,7 +296,6 @@ struct sierra_port_private {
- int dsr_state;
- int dcd_state;
- int ri_state;
--
- unsigned int opened:1;
- };
-
-@@ -306,6 +305,8 @@ static int sierra_send_setup(struct usb_
- struct sierra_port_private *portdata;
- __u16 interface = 0;
- int val = 0;
-+ int do_send = 0;
-+ int retval;
-
- dev_dbg(&port->dev, "%s\n", __func__);
-
-@@ -324,10 +325,7 @@ static int sierra_send_setup(struct usb_
- */
- if (port->interrupt_in_urb) {
- /* send control message */
-- return usb_control_msg(serial->dev,
-- usb_rcvctrlpipe(serial->dev, 0),
-- 0x22, 0x21, val, interface,
-- NULL, 0, USB_CTRL_SET_TIMEOUT);
-+ do_send = 1;
- }
- }
-
-@@ -339,12 +337,18 @@ static int sierra_send_setup(struct usb_
- interface = 1;
- else if (port->bulk_out_endpointAddress == 5)
- interface = 2;
-- return usb_control_msg(serial->dev,
-- usb_rcvctrlpipe(serial->dev, 0),
-- 0x22, 0x21, val, interface,
-- NULL, 0, USB_CTRL_SET_TIMEOUT);
-+
-+ do_send = 1;
- }
-- return 0;
-+ if (!do_send)
-+ return 0;
-+
-+ usb_autopm_get_interface(serial->interface);
-+ retval = usb_control_msg(serial->dev, usb_rcvctrlpipe(serial->dev, 0),
-+ 0x22, 0x21, val, interface, NULL, 0, USB_CTRL_SET_TIMEOUT);
-+ usb_autopm_put_interface(serial->interface);
-+
-+ return retval;
- }
-
- static void sierra_set_termios(struct tty_struct *tty,
diff --git a/version b/version
index d56e8db301cc51..82962e669f3ff3 100644
--- a/version
+++ b/version
@@ -1 +1 @@
-2.6.32-rc5
+2.6.32-rc6