18 Jul, 2007
40 commits
-
currently the export_operation structure and helpers related to it are in
fs.h. fs.h is already far too large and there are very few places needing the
export bits, so split them off into a separate header.[akpm@linux-foundation.org: fix cifs build]
Signed-off-by: Christoph Hellwig
Signed-off-by: Neil Brown
Cc: Steven French
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Fix output of i2o debug messages, extra KERN_ are removed.
Signed-off-by: Vasily Averin
Acked-by: Alan Cox
Cc: Markus Lidel
Acked-by: Kirill Korotaev
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Fix oops on reading from some i2o proc files (i2o_seq_show_driver_store() and
other) because their handlers uses "exec" field in struct i2o_controllerSigned-off-by: Vasily Averin
Acked-by: Alan Cox
Cc: Markus Lidel
Acked-by: Kirill Korotaev
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
We need to free i2o msg in case of error.
Signed-off-by: Vasily Averin
Acked-by: Alan Cox
Cc: Markus Lidel
Acked-by: Kirill Korotaev
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
This patch fixes access to memory that has not been allocated:
i2o_msg_get_wait() can returns errors different from I2O_QUEUE_EMPTY. But the
result is checked only against this code. If it is not I2O_QUEUE_EMPTY then
we dereference the error code as the pointer later.Signed-off-by: Vasily Averin
Acked-by: Alan Cox
Cc: Markus Lidel
Acked-by: Kirill Korotaev
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
This patch fixes a number of issues in i2o_cfg_passthru{,32}:
- i2o_msg_get_wait() return vaile is not checked;
- i2o_message memory leaks on error paths;
- infinite loop to sg_list_cleanup in passthru32It's important issue because of i2o_cfg_passthru is used by raidutils for
monitorig controllers state, and in case of memory shortage it leads to the
node crash or disk IO stall.[akpm@linux-foundation.org: fix null-ptr deref]
Signed-off-by: Vasily Averin
Acked-by: Alan Cox
Cc: Markus Lidel
Acked-by: Kirill Korotaev
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
coverity spotted a possible leak in the idifunc.c file (bug id #1252), in
um_new_card(), if the diva_user_mode_idi_create_adapter() fails, we dont
free the memory allocated for cardSigned-off-by: Eric Sesterhenn
Acked-by: Armin Schindler
Cc: Karsten Keil
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
drivers/isdn/capi/capi.c: In function 'handle_minor_send':
drivers/isdn/capi/capi.c:552: warning: cast from pointer to integer of different sizeOf course, the code here might actually be buggy, in which case this patch
should not be applied?Answer:
No this field is ignored inside linux kernel.Yes this is ugly, but it's
the CAPI spec for all OS.CAPI DATA_B3 Request/Indication CAPI Message has a mandatory field which
represent the 32 bit buffer address of the payload data. In linux the
payload data do not use a sperate buffer, data follows directely after the
CAPI Message in the same skb and we use this assumption inside the drivers,
so we can ignore this field.Inside the linux CAPI implemetation we never use this field, so it could
also have no value, but since random data in a message is bad as well (e.g.
displayed in CAPI traces) we set is to the most adequate value.Outside the kernel the capi20 library sets the correct addresses (there is
an optional second field for 64 bit adresses for 64 bit systems, we do not
use here).Acked-by: Karsten Keil
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Transform Kconfig objects from "menu, config" into "menuconfig" so
that the user can disable the whole feature without having to enter
the menu first.Signed-off-by: Jan Engelhardt
Cc: Karsten Keil
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Transform Kconfig objects from "menu, config" into "menuconfig" so
that the user can disable the whole feature without having to enter
the menu first.Signed-off-by: Jan Engelhardt
Cc: Karsten Keil
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Transform "depends on" into a simpler if-endif block style dependency.
Signed-off-by: Jan Engelhardt
Cc: Karsten Keil
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Transform Kconfig objects from "menu, config" into "menuconfig" so that the
user can disable the whole feature without having to enter the menu first.Signed-off-by: Jan Engelhardt
Cc: Karsten Keil
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The interrupts schould be disabled until the driver
is ready and the IRQ function was registered.Thanks to Bastian Friedrich and Thomas Voegtle for spotting this.
Signed-off-by: Karsten Keil
Signed-off-by: Bastian Friedrich
Signed-off-by: Thomas Voegtle
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The similar code exists here and is called capi_driver_get_idx(). Use generic
helpers now and remember to convert list_head to struct capi_driver in .show
callback.Signed-off-by: Pavel Emelianov
Acked-by: Karsten Keil
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The {l1,l2,l3,lli,tei}_revision strings in the HiSax driver are 'const',
but have a mismatching declaration as 'extern char *' in config.c.Signed-off-by: David Woodhouse
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The CAPI 2.0 driver uses a semaphore as mutex. Use the mutex API instead of
the (binary) semaphore.Signed-off-by: Matthias Kaehlcke
Acked-by: Karsten Keil
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The SPI core/init code uses a semaphore as mutex. Use the mutex API instead
of the (binary) semaphore.Signed-off-by: Matthias Kaehlcke
Acked-by: David Brownell
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
This is a driver for SPI controller built into TXx9 MIPS SoCs.
This driver is derived from arch/mips/tx4938/toshiba_rbtx4938/spi_txx9.c.Signed-off-by: Atsushi Nemoto
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Add OMAP24XX McSPI (Multichannel SPI) controller driver. This driver is
tested very well under OMAP GIT tree with N800 - Nokia Internet Tablet, and
some other OMAP2 boards.Recent updates included bugfixes, cleanups, speedups, and better
conformance to the current SPI programming interface. This doesn't yet
understand the third controller instance on the OMAP 2430.[david-b@pacbell.net: more minor cleanups to the omap2_mcspi driver]
Signed-off-by: Juha Yrjölä
Signed-off-by: Trilok Soni
Signed-off-by: David Brownell
Cc: Tony Lindgren
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Quicc Engine enabled mpc83xx CPU's has a somewhat different HW interface to
the SPI controller. This patch adds a qe_mode knob that sees to that
needed adaptions are performed.Signed-off-by: Joakim Tjernlund
Signed-off-by: David Brownell
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Simple SPI master driver for Xilinx SPI controller.
No support for multiple masters.
Not using level 1 drivers from EDK.[akpm@linux-foundation.org: uninlining]
Signed-off-by: Yuri Frolov
Signed-off-by: Andrei Konovalov
Cc: Kumar Gala
Cc: David Brownell
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Add support for the Infineon TLE62x0 series of low-side driver chips, such
as the TLE6220 or TLE6230. These can be viewed as output GPIOs specialized
for power switching applications. The driver provides a userspace
interface to those GPIOs, and to the switch status they provide.Signed-off-by: Ben Dooks
Signed-off-by: David Brownell
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Tweak Kconfig for the S3C24XX SPI controller drivers. Both use the bitbang
framework; only one previously said that. Plus in this case "select" is
the right way to manage that dependency, since folk will not know up front
to enable bitbang in order to even see those S3C drivers in order to enable
them.Signed-off-by: David Brownell
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Update chipselect handling for atmel_spi:
* Teach it how to leave chipselect active between messages; this
helps various drivers work better.* Cope with at91rm0200 errata: nCS0 can't be managed with GPIOs.
The MR.PCS value is now updated whenever a chipselect changes.
(This requires SPI pinmux init for that controller to change,
and also testing on rm9200; doesn't break at91sam9 or avr32.)* Fix minor glitches: spi_setup() must leave chipselects inactive,
as must removal of the spi_device.Also tweak diagnostic messaging to be a bit more useful.
Signed-off-by: David Brownell
Acked-by: Haavard Skinnemoen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Minor updates to atmel_spi:
- DMA:
* Comments to explain the DMA policies
* Report any mapping errors from spi_transfer()
* Remove extra loop for DMA mapping- Diagnostics: report minimum clock rate, if we need to reject a
spi_setup() request because that rate is too low.Signed-off-by: David Brownell
Acked-by: Haavard Skinnemoen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The MPC83xx SPI controller clock divider can divide the system clock by not
more then 1024. The spi_mpc83xx driver does not check this and silently
writes garbage to the SPI controller registers when asked to run at lower
frequencies. I've tried to run the SPI on a 266MHz MPC8349E with 100kHz
for debugging a bus problem and suddenly was confronted with a 2nd problem
to debug.. ;-)The patch adds an additional check which avoids writing garbage to the SPI
controller registers and warn the user about it. This might help others to
avoid simmilar problems.Cc: Kumar Gala
Cc: David Brownell
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
This adds a driver for the LM70-LLP parport adapter, which is an eval board
for the LM70 temperature sensor. For those without that board, it may be a
simpler example of a parport-to-SPI adapter then spi_butterfly.Signed-off-by: Kaiwan N Billimoria
Doc, coding style, and interface updates; build fixes. Minor rename.
Signed-off-by: David Brownell
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Get rid of annoying GCC warning on 32-bit platforms.
drivers/spi/spidev.c: In function 'spidev_message':
drivers/spi/spidev.c:184: warning: cast to pointer from integer of different size
drivers/spi/spidev.c:216: warning: cast to pointer from integer of different sizeThe trick is to add an extra cast using "ptrdiff_t" to convert the u64 to
the correct size integer, and only then casting it into a "void *" pointer.Signed-off-by: David Brownell
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Add CRC7 routines, used for example in MMC over SPI communication.
Kerneldoc updates[akpm@linux-foundation.org: fix funny mix of const and non-const]
Signed-off-by: Jan Nikitenko
Signed-off-by: David Brownell
Cc: "Randy.Dunlap"
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Add a new spi->mode bit: SPI_3WIRE, for chips where the SI and SO signals
are shared (and which are thus only half duplex). Update the LM70 driver
to require support for that hardware mode from the controller.Signed-off-by: David Brownell
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Minor SPI controller driver updates: make the setup() methods reject
spi->mode bits they don't support, by masking aginst the inverse of bits
they *do* support. This insures against misbehavior later when new mode
bits get added.Most controllers can't support SPI_LSB_FIRST; more handle SPI_CS_HIGH.
Support for all four SPI clock/transfer modes is routine.Signed-off-by: David Brownell
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
IBMASM: must depend on CONFIG_INPUT
The driver registers couple of input devices and therefore must depend
on CONFIG_INPUT.Signed-off-by: Dmitry Torokhov
Cc: Vernon Mauery
Cc: Max Asbock
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
IBMASM: miscellaneous fixes
Fix some minor issues, such as:
- properly set up ID of keyboard device (was mixed up with mouse)
- constify translation tables
- change some variables to #defines
- set up input device's parent to form proper sysfs hierarchy
- minor formatting changesSigned-off-by: Dmitry Torokhov
Cc: Vernon Mauery
Cc: Max Asbock
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
IBMASM: don't use extern in function declarations
We normally don't use extern in function declarations located in header files.
Signed-off-by: Dmitry Torokhov
Cc: Vernon Mauery
Cc: Max Asbock
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
IBMASM: whitespace cleanup
Signed-off-by: Dmitry Torokhov
Cc: Vernon Mauery
Cc: Max Asbock
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Avoid dirtying remote cpu's memory if it already has the correct value.
Cc: Andi Kleen
Cc: Konrad Rzeszutek
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Avoid dirtying remote cpu's memory if it already has the correct value.
Cc: Andi Kleen
Cc: Konrad Rzeszutek
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
On large memory configuration with not so fast CPUs the NMI watchdog is
triggered when memory addresses are being gathered and printed. The code
paths for Alt-SysRq-t are sprinkled with touch_nmi_watchdog in various
places but not in this routine (or in the loop that utilizes this
function). The patch has been tested for regression on large CPU+memory
configuration (128 logical CPUs + 224 GB) and 1,2,4,16-CPU sockets with
various memory sizes (1,2,4,6,20).Cc: Andi Kleen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
sparse now warns if one compares pointers with integers. However, there are
false positives, like:fs/filesystems.c:72:2: warning: Using plain integer as NULL pointer
Every time BUG_ON(ptr) is used, ptr is checked against integer zero. Avoid
that and save ~70 false positives from allyesconfig run.mentioned by Al.
Signed-off-by: Alexey Dobriyan
Acked-by: Al Viro
Acked-by: Josh Triplett
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Pointed out by Michal Schmidt .
The bug was introduced in 2.6.22 by me.
cleanup_workqueue_thread() does flush_cpu_workqueue(cwq) in a loop until
->worklist becomes empty. This is live-lockable, a re-niced caller can get
CPU after wake_up() and insert a new barrier before the lower-priority
cwq->thread has a chance to clear ->current_work.Change cleanup_workqueue_thread() to do flush_cpu_workqueue(cwq) only once.
We can rely on the fact that run_workqueue() won't return until it flushes
all works. So it is safe to call kthread_stop() after that, the "should
stop" request won't be noticed until run_workqueue() returns.Signed-off-by: Oleg Nesterov
Cc: Michal Schmidt
Cc: Srivatsa Vaddagiri
Cc:
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds