summaryrefslogtreecommitdiffstats
path: root/drivers/usb/storage
Commit message (Collapse)AuthorAgeFilesLines
* USB: remove unnecessary type casting of urb->contextMing Lei2008-04-241-1/+1
| | | | | | | | urb->context code cleanup Signed-off-by: Ming Lei <tom.leiming@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: replace remaining __FUNCTION__ occurrencesHarvey Harrison2008-04-243-22/+22
| | | | | | | | __FUNCTION__ is gcc-specific, use __func__ Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: usb-storage: use adaptive DMA maskAlan Stern2008-04-241-6/+8
| | | | | | | | | | | | This patch (as1060) makes usb-storage set the DMA alignment mask for SCSI slaves to match the maxpacket size of the bulk-IN endpoint, rather than always setting it to 511. For full-speed devices that mask is too restrictive, and wireless USB devices can have maxpacket sizes larger than 512. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: Remove EXPERIMENTAL designation from USB storage Kconfig entries.Robert P. J. Day2008-04-241-14/+14
| | | | | | | | | Since there seems to be little reason to mark the current USB storage features as "EXPERIMENTAL," remove that dependency. Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: mass storage: emulation of sat scsi_pass_thru with ATACBmatthieu castet2008-04-248-2/+258
| | | | | | | | | | | | | | | | | | | | | | | I have got a cypress usb-ide bridge and I would like to tune or monitor my disk with tools like hdparm, hddtemp or smartctl. My controller support a way to send raw ATA command to the disk with something call atacb (see http://download.cypress.com.edgesuite.net/design_resources/datasheets/contents/cy7c68300c_8.pdf). Atacb support can be added for each application, but there is some disadvantages : - all application need to be patched - A race is possible if there other accesses, because the emulation can be split in 2 atacb scsi transactions. One for sending the command, one for reading the register (if ck_cond is set). I have implemented the emulation in usb-storage with a special proto_handler, and an unsual entry. Signed-off-by: Matthieu CASTET <castet.matthieu@free.fr> Signed-off-by: Matthew Dharm <mdharm-usb@one-eyed-alien.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: make USB_STORAGE_ONETOUCH available with PMAdrian Bunk2008-04-241-1/+1
| | | | | | | | | | | | | | | As Torsten Kaiser pointed out, it seems the dependency of USB_STORAGE_ONETOUCH on !PM should have been removed in commit 7931e1c6f8007d5fef8a0bb2dc71bd97315eeae9. Signed-off-by: Adrian Bunk <bunk@kernel.org> Cc: Matthew Dharm <mdharm-usb@one-eyed-alien.net> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: Greg Kroah-Hartman <gregkh@suse.de> Cc: Torsten Kaiser <just.for.lkml@googlemail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: libusual: locking cleanupDaniel Walker2008-04-241-8/+6
| | | | | | | | | | | | | I converted the usu_init_notify semaphore to normal mutex usage, and it should still prevent the request_module before the init routine is complete. Before it acted more like a complete, now the mutex protects two distinct section from running at the same time. Signed-off-by: Daniel Walker <dwalker@mvista.com> Cc: Pete Zaitcev <zaitcev@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: support more Huawei data card product IDsfangxiaozhi2008-04-151-4/+92
| | | | | | | | | | | | - declare the unusal device for Huawei data card devices in unusual_devs.h - disable the product ID matching for Huawei data card devices in usb_match_device function of driver.c - declare the product IDs in option.c. Signed-off-by: fangxiaozhi <huananhu@huawei.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: add support for Motorola ROKR Z6 cellphone in mass storage modeConstantin Baranov2008-03-242-1/+13
| | | | | | | | | | | | | | | Motorola ROKR Z6 cellphone has bugs in its USB, so it is impossible to use it as mass storage. Patch describes new "unusual" USB device for it with FIX_INQUIRY and FIX_CAPACITY flags and new BULK_IGNORE_TAG flag. Last flag relaxes check for equality of bcs->Tag and us->tag in usb_stor_Bulk_transport routine. Signed-off-by: Constantin Baranov <const@tltsu.ru> Signed-off-by: Matthew Dharm <mdharm-usb@one-eyed-alien.net> Signed-off-by: Daniel Drake <dsd@gentoo.org> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: isd200: fix memory leak in isd200_get_inquiry_dataBoaz Harrosh2008-03-241-0/+1
| | | | | | | | | | | If the inquiry fails then the info structure on us->extra was not freed. Signed-off-by: Boaz Harrosh <bharrosh@panasas.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Cc: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6Linus Torvalds2008-03-201-1/+4
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | * git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6: [SCSI] a100u2w: fix bitmap lookup routine [SCSI] fix media change events for polled devices [SCSI] sd, sr: do not emit change event at device add [SCSI] mpt fusion: Power Management fixes for MPT SAS PCI-E controllers [SCSI] gdth: Allocate sense_buffer to prevent NULL pointer dereference [SCSI] arcmsr: fix iounmap error for Type B adapter [SCSI] isd200: Allocate sense_buffer for hacked up scsi_cmnd [SCSI] fix bsg queue oops with iscsi logout [SCSI] Fix dependency problems in SCSI drivers [SCSI] advansys: Fix bug in AdvLoadMicrocode
| * [SCSI] isd200: Allocate sense_buffer for hacked up scsi_cmndBoaz Harrosh2008-03-131-1/+4
| | | | | | | | | | | | | | | | | | Since the separation of sense_buffer from scsi_cmnd, Drivers that hack their own struct scsi_cmnd like here isd200, must also take care of their own sense_buffer. Signed-off-by: Boaz Harrosh <bharrosh@panasas.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* | USB: drivers/usb/storage/sddr55.c: fix uninitialized var warningsAndrew Morton2008-03-101-2/+2
|/ | | | | | | | | | drivers/usb/storage/sddr55.c: In function 'sddr55_transport': drivers/usb/storage/sddr55.c:526: warning: 'deviceID' may be used uninitialized in this function drivers/usb/storage/sddr55.c:525: warning: 'manufacturerID' may be used uninitialized in this function Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* usb-storage: update earlier scatter-gather bug fixAlan Stern2008-03-041-1/+1
| | | | | | | | | | | | | | | This patch (as1037) makes a small update to the earlier as1035 patch. The minimum-length computation shouldn't be done in usb_stor_access_xfer_buf(), since that routine can be called multiple times for a single transfer. It should be done in usb_stor_set_xfer_buf() instead, which gets called only once. The way it is now isn't really _wrong_, but it isn't really _right_ either. Moving the statement will be an improvement. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: usb-storage: don't access beyond the end of the sg bufferAlan Stern2008-02-211-12/+15
| | | | | | | | | | | | This patch (as1035) fixes a bug in usb_stor_access_xfer_buf() (the bug was originally found by Boaz Harrosh): The routine must not attempt to write beyond the end of a scatter-gather list or beyond the number of bytes requested. It also fixes up the formatting of a few comments and similar whitespace issues. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: quirks and unusual_devs entry for Actions flash driveAlan Stern2008-02-211-0/+9
| | | | | | | | | | | | | | This patch (as1033) adds a quirks entry and an unusual_devs entry for the Actions Semiconductor flash drive. This device has a 64-byte string descriptor, which it doesn't terminate with a 0-length packet. Oddly enough, the reporter's logs show that when the device was plugged in at boot time, it changes its behavior completely -- it uses a different product ID, product string descriptor, and bDeviceClass. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: usb-storage: unusual_devs entry for Oracom MP3 playerRobert Spitzenpfeil2008-02-211-0/+11
| | | | | | | | | | | | This patch (as1034) was written by Leonid Petrov, reported by Robert Spitzenpfeil, and updated by me. It adds an unusual_devs entry with the IGNORE_RESIDUE flag for the Oracom MP3 player. Together with the change to the Get-Max-LUN routine in as1032, it makes the player usable. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Phil Dibowitz <phil@ipom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: storage: Nikon D80 new FW still needs FixupKonstantin Kletschke2008-02-211-1/+1
| | | | | | | | | | Add new BCD numbers for Nikon D80 Firmware revision v1.10 to the unusual_devs.h file. Signed-off-by: Konstantin Kletschke <konsti@ku-gbr.de> Signed-off-by: Phil Dibowitz <phil@ipom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: usb-storage: don't clear-halt when Get-Max-LUN stallsAlan Stern2008-02-212-11/+12
| | | | | | | | | | | | | | | | | This patch (as1032) removes the Clear-Halt calls in usb_stor_Bulk_max_lun(). Evidently some devices (such as the Oracom MP3 player) really don't like to receive these requests when their bulk endpoints aren't halted. The only reason for adding them originally was to get an ancient ZIP-100 drive to work. But since this device has only a single LUN, we don't need to send it a Get-Max-LUN request at all. Adding an unusual_devs entry for the ZIP-100 with the SINGLE_LUN flag set will cause this step to be skipped. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: usb/storage/initializers.c: fix signedness differenceMarcin Slusarz2008-02-011-1/+2
| | | | | | | | | | | | | | fix warnings: drivers/usb/storage/initializers.c:83:26: warning: incorrect type in argument 5 (different signedness) drivers/usb/storage/initializers.c:83:26: expected unsigned int *act_len drivers/usb/storage/initializers.c:83:26: got int *<noident> drivers/usb/storage/initializers.c:89:26: warning: incorrect type in argument 5 (different signedness) drivers/usb/storage/initializers.c:89:26: expected unsigned int *act_len drivers/usb/storage/initializers.c:89:26: got int *<noident> Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: isd200: don't include <linux/ide.h>Bartlomiej Zolnierkiewicz2008-02-011-15/+14
| | | | | | | | | | | | | | | | | | | | Now that commit 3794ade5b286cbd4551009dd341dbe9aeead2bc3 removed incorrect dependency on CONFIG_IDE we can fix the driver to not include <linux/ide.h>: * add ATA_REG_{ERROR,LCYL,HCYL,STATUS}_OFFSET defines and use them instead of IDE_{ERROR,LCYL,HCYL,STATUS}_OFFSET from <linux/ide.h> * remove no longer needed <linux/ide.h> include * remove incorrect comment added by the last commit: - isd200.c is not the only user of struct hd_driveid besides IDE (see drivers/block/xsysace.c and arch/um/drivers/ubd_kern.c) Cc: Alan Cox <alan@redhat.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: storage: Add unusual_dev for HP r707Grant Grundler2008-02-011-0/+8
| | | | | | | | | | | | | | Add "FIX_CAPACITY" entry for HP Photosmart r707 Camera in "Disk" mode. Camera will wedge when /lib/udev/vol_id attempts to access the last sector, EIO gets reported to dmesg, and block device is marked "offline" (it is). Reproduced vol_id behavior with: "dd if=/dev/sda of=/dev/null skip=60800 count=1" Cc: stable <stable@kernel.org> Signed-off-by: Grant Grundler <grundler@parisc-linux.org> Signed-off-by: Phil Dibowitz <phil@ipom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* [SCSI] implement scsi_data_bufferBoaz Harrosh2008-01-301-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In preparation for bidi we abstract all IO members of scsi_cmnd, that will need to duplicate, into a substructure. - Group all IO members of scsi_cmnd into a scsi_data_buffer structure. - Adjust accessors to new members. - scsi_{alloc,free}_sgtable receive a scsi_data_buffer instead of scsi_cmnd. And work on it. - Adjust scsi_init_io() and scsi_release_buffers() for above change. - Fix other parts of scsi_lib/scsi.c to members migration. Use accessors where appropriate. - fix Documentation about scsi_cmnd in scsi_host.h - scsi_error.c * Changed needed members of struct scsi_eh_save. * Careful considerations in scsi_eh_prep/restore_cmnd. - sd.c and sr.c * sd and sr would adjust IO size to align on device's block size so code needs to change once we move to scsi_data_buff implementation. * Convert code to use scsi_for_each_sg * Use data accessors where appropriate. - tgt: convert libsrp to use scsi_data_buffer - isd200: This driver still bangs on scsi_cmnd IO members, so need changing [jejb: rebased on top of sg_table patches fixed up conflicts and used the synergy to eliminate use_sg and sg_count] Signed-off-by: Boaz Harrosh <bharrosh@panasas.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] usbstorage: use last_sector_bug flag universallyHans de Goede2008-01-251-0/+4
| | | | | | | | | | | | This patch sets the last_sector_bug flag to 1 for all USB disks. This is needed to makes the cardreader on various HP multifunction printers work. Since the performance impact is negible we set this flag for all USB disks to avoid an unusual_devs.h nightmare. Signed-off-by: Hans de Goede <j.w.r.degoede@hhs.nl> Acked-by: Matthew Dharm <mdharm-usb@one-eyed-alien.net> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] relax scsi dma alignmentJames Bottomley2008-01-111-10/+10
| | | | | | | | | | | | | | This patch relaxes the default SCSI DMA alignment from 512 bytes to 4 bytes. I remember from previous discussions that usb and firewire have sector size alignment requirements, so I upped their alignments in the respective slave allocs. The reason for doing this is so that we don't get such a huge amount of copy overhead in bio_copy_user() for udev. (basically all inquiries it issues can now be directly mapped). Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] isd200: use one-element sg list in issuing commandsBoaz Harrosh2008-01-111-20/+46
| | | | | | | | | | | | | | | | | | | | | - This patch should be commited before: usb: transport - convert to accessors and !use_sg code path removal - isd200_action() was still using direct liniar pointers in issuing commands to the USB transport level. This is no longer supported, use one-element scatterlist instead. - Adjustment of command's length in the case of scsi-to-ata translation is now restored before return to queuecommand, since other wise it can leak BIOs. - isd200_action() return Error on unknown requests. Used to print an error but still try to send garbage cdb. - convert few places to scsi data accessors. - Todo: This file will need to be changed when scsi_cmnd changes to scsi_data_buffer or any other solution. Signed-off-by: Boaz Harrosh <bharrosh@panasas.com> Acked-by: Matthew Dharm <mdharm-scsi@one-eyed-alien.net> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] usb: transport - convert to accessors and !use_sg code path removalBoaz Harrosh2008-01-112-17/+30
| | | | | | | | | | | | | | | | | | | | - This patch depends on: usb: transport.c use scsi_eh API in REQUEST_SENSE execution - Use scsi data accessors and remove of !use_sg code path. - New usb_stor_bulk_srb() for use by drivers [jejb: updated with corrective fix. had a bug in residual handling in the new usb_stor_bulk_srb() function. Found by Gabriel C. in -mm tree. Tested-by: Gabriel C <nix.or.die@googlemail.com> ] Signed-off-by: Boaz Harrosh <bharrosh@panasas.com> Acked-by: Matthew Dharm <mdharm-scsi@one-eyed-alien.net> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] usb: shuttle_usbat - convert to accessors and !use_sg code path removalBoaz Harrosh2008-01-111-42/+26
| | | | | | | | | | - functions that received char* but where passed scatterlist* mostly were changed to receive void* - Use scsi data accessors and remove of !use_sg code path Signed-off-by: Boaz Harrosh <bharrosh@panasas.com> Acked-by: Matthew Dharm <mdharm-scsi@one-eyed-alien.net> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] usb: freecom & sddr09 - convert to accessors and !use_sg cleanupBoaz Harrosh2008-01-112-14/+9
| | | | | | | | | - Use scsi data accessors and remove of !use_sg code path - This patch is dependent on cleanup patch to usb transport.c/h Signed-off-by: Boaz Harrosh <bharrosh@panasas.com> Acked-by: Matthew Dharm <mdharm-scsi@one-eyed-alien.net> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] usb: protocol - convert to accessors and !use_sg code path removalBoaz Harrosh2008-01-111-73/+53
| | | | | | | | - Use scsi data accessors and remove of !use_sg code path Signed-off-by: Boaz Harrosh <bharrosh@panasas.com> Acked-by: Matthew Dharm <mdharm-scsi@one-eyed-alien.net> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* USB: revert portions of "UNUSUAL_DEV: Sync up some reported devices from Ubuntu"Greg Kroah-Hartman2007-12-171-8/+0
| | | | | | | | | | | | | | | | | This reverts one change from 67fa10627ec0d8aa16f1cf38cf527e67d8097d3c that prevented userspace from seing the "driver disk" lun in a san disk device. The kernel shouldn't do this, it's up to userspace to handle this properly, if it somehow wants to filter this away. Cc: Ben Collins <bcollins@ubuntu.com> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: Phil Dibowitz <phil@ipom.com> Cc: Kyle McMartin <kyle@mcmartin.ca> Cc: Matthew Dharm <mdharm-usb@one-eyed-alien.net> Cc: Hans de Goede <j.w.r.degoede@hhs.nl> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* usb-storage: Fix devices that cannot handle 32k transfersDoug Maxey2007-12-172-3/+16
| | | | | | | | | | | | | | | | | When a device cannot handle the smallest previously limited transfer size (64 blocks) without stalling, limit the device to the amount of packets that fit in a platform native page. The lowest possible limit is PAGE_CACHE_SIZE, so if the device is ever used on a platform that has larger than 8K pages, you lose unless you can convince the device firmware folks to fix the issue. Cc: Mathew Dharm <mdharm-scsi@one-eyed-alien.net> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: Pete Zaitcev <zaitcev@redhat.com> Signed-off-by: Doug Maxey <dwm@austin.ibm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: usb-storage: unusual_devs entry for JetFlash TS1GJF2AAlan Stern2007-11-281-0/+7
| | | | | | | | | | | | | | | This patch (as1018) adds an unusual_devs entry for the JetFlash TS1GJF2A. This device doesn't like read requests for more than 188 sectors. Setting max_sectors down to 64 is overkill, but at least it will work without errors. For the torturous debugging history, see this thread: http://marc.info/?t=118745764700005&r=1&w=2 Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: add support for an older firmware revision for the Nikon D200Mike Pagano2007-11-281-5/+5
| | | | | | | | | | | | | | | | | | | | | | This is a resubmission of the patch to upgrade the unusual_devs.h file to support an older firmware revision of the Nikon D200. This patch includes the requested /proc/bus/usb/devices information. T: Bus=01 Lev=01 Prnt=01 Port=09 Cnt=02 Dev#= 6 Spd=480 MxCh= 0 D: Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1 P: Vendor=04b0 ProdID=040f Rev= 1.00 S: Manufacturer=NIKON S: Product=NIKON DSC D200 S: SerialNumber=0000000 C:* #Ifs= 1 Cfg#= 1 Atr=c0 MxPwr= 2mA I:* If#= 0 Alt= 0 #EPs= 2 Cls=08(stor.) Sub=06 Prot=50 Driver=usb-storage E: Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms E: Ad=82(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms Signed-off-by: Mike Pagano <mpagano@gentoo.org> Signed-off-by: Phil Dibowitz <phil@ipom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* usb-storage: always set the allow_restart flagMauro Carvalho Chehab2007-11-281-0/+4
| | | | | | | | | | | | This patch (as1000) sets the SCSI allow_restart flag for USB disk devices. In theory this should never hurt, and there definitely are devices out there (such as the Seagate 250-GB external drive) which need the flag to be set. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org> Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: isd200: sort out USB/IDE dependancy messAlan Cox2007-10-252-2/+104
| | | | | | | | | | | | | | | The ISD200 driver imports a single trivial routine from the IDE layer and in doing so creates a mess of dependancies that drag in the entire old IDE layer. Even more sad - it does this for a routine which is usually (little endian) a null function! - Copy the function into ISD200 - Rename it so it doesn't clash with the ide header prototype - Remove all the depend constraints Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* [SG] Update drivers to use sg helpersJens Axboe2007-10-221-1/+1
| | | | Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
* Convert files to UTF-8 and some cleanupsJan Engelhardt2007-10-192-3/+3
| | | | | | | | | | | | | | | | | | * Convert files to UTF-8. * Also correct some people's names (one example is Eißfeldt, which was found in a source file. Given that the author used an ß at all in a source file indicates that the real name has in fact a 'ß' and not an 'ss', which is commonly used as a substitute for 'ß' when limited to 7bit.) * Correct town names (Goettingen -> Göttingen) * Update Eberhard Mönkeberg's address (http://lkml.org/lkml/2007/1/8/313) Signed-off-by: Jan Engelhardt <jengelh@gmx.de> Signed-off-by: Adrian Bunk <bunk@kernel.org>
* freezer: introduce freezer-friendly waiting macrosRafael J. Wysocki2007-10-181-4/+1
| | | | | | | | | | | | | | | | Introduce freezer-friendly wrappers around wait_event_interruptible() and wait_event_interruptible_timeout(), originally defined in <linux/wait.h>, to be used in freezable kernel threads. Make some of the freezable kernel threads use them. This is necessary for the freezer to stop sending signals to kernel threads, which is implemented in the next patch. Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl> Acked-by: Pavel Machek <pavel@ucw.cz> Cc: Nigel Cunningham <nigel@nigel.suspend2.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* kill DECLARE_MUTEX_LOCKEDChristoph Hellwig2007-10-171-1/+3
| | | | | | | | | | | | | DECLARE_MUTEX_LOCKED was used for semaphores used as completions and we've got rid of them. Well, except for one in libusual that the maintainer explicitly wants to keep as semaphore. So convert that useage to an explicit sema_init and kill of DECLARE_MUTEX_LOCKED so that new code is reminded to use a completion. Signed-off-by: Christoph Hellwig <hch@lst.de> Acked-by: "Satyam Sharma" <satyam.sharma@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* USB storage: sg chaining supportJens Axboe2007-10-168-45/+62
| | | | | | | | | | | [PATCH] USB storage: sg chaining support Modify usb_stor_access_xfer_buf() to take a pointer to an sg entry pointer, so we can keep track of that instead of passing around an integer index (which we can't use when dealing with multiple scatterlist arrays). Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
* Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6Linus Torvalds2007-10-151-42/+4
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6: (207 commits) [SCSI] gdth: fix CONFIG_ISA build failure [SCSI] esp_scsi: remove __dev{init,exit} [SCSI] gdth: !use_sg cleanup and use of scsi accessors [SCSI] gdth: Move members from SCp to gdth_cmndinfo, stage 2 [SCSI] gdth: Setup proper per-command private data [SCSI] gdth: Remove gdth_ctr_tab[] [SCSI] gdth: switch to modern scsi host registration [SCSI] gdth: gdth_interrupt() gdth_get_status() & gdth_wait() fixes [SCSI] gdth: clean up host private data [SCSI] gdth: Remove virt hosts [SCSI] gdth: Reorder scsi_host_template intitializers [SCSI] gdth: kill gdth_{read,write}[bwl] wrappers [SCSI] gdth: Remove 2.4.x support, in-kernel changelog [SCSI] gdth: split out pci probing [SCSI] gdth: split out eisa probing [SCSI] gdth: split out isa probing gdth: Make one abuse of scsi_cmnd less obvious [SCSI] NCR5380: Use scsi_eh API for REQUEST_SENSE invocation [SCSI] usb storage: use scsi_eh API in REQUEST_SENSE execution [SCSI] scsi_error: Refactoring scsi_error to facilitate in synchronous REQUEST_SENSE ...
| * [SCSI] usb storage: use scsi_eh API in REQUEST_SENSE executionBoaz Harrosh2007-10-121-42/+4
| | | | | | | | | | | | | | | | | | - Use new scsi_eh_prep/restor_cmnd() for synchronous REQUEST_SENSE invocation. Signed-off-by: Boaz Harrosh <bharrosh@panasas.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
* | USB: Nikon D40X unusual_devs entryOrtwin Glück2007-10-121-0/+7
| | | | | | | | | | | | | | | | | | | | Not surprisingly the Nikon D40X DSC needs the same quirks as the D40, but it has a separate ID. See http://bugs.gentoo.org/show_bug.cgi?id=191431 From: Ortwin Glück <odi@odi.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* | USB: allow usbstorage to have LUNS greater than 2TbRichard Sharpe2007-10-121-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Attached is a very small patch (several comment lines) and a one-line coded change) that allows for USB storage devices that are larger than 2TB. At the company where I work we need such support, and one of my co-workers, Jane Liu, pointed out that SCSI low-layer drivers need to specify what size CDBs they accept. After looking through the code it became obvious that the current USB Storage code accepted the default of 12-byte CDBs, so I changed it to accept 16-byte CDBs. This allows our device to work. Signed-off-by: Richard Sharpe <rsharpe@richardsharpe.com> Signed-off-by: Matthew Dharm <mdharm-usb@one-eyed-alien.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* | USB: unusual_devs entry for Nikon DSC D2XsAlan Stern2007-10-121-0/+7
| | | | | | | | | | | | | | | | | | | | This patch (as996) adds an unusual_devs entry for the Nikon DSC D2Xs camera. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Cc: Phil Dibowitz <phil@ipom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* | USB: unusual_devs modification for Nikon D200Phil Dibowitz2007-10-121-0/+7
| | | | | | | | | | | | | | | | | | | | Upgrade the unusual_devs.h file to support the Nikon D200 Signed-off-by: Mike Pagano <mpagano-kernel@mpagano.com> Signed-off-by: Phil Dibowitz <phil@ipom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* | USB: unusual_devs update for Nokia 6131Alan Stern2007-10-121-1/+1
| | | | | | | | | | | | | | | | | | | | This patch (as991) updates the unusual_devs entry for the Nokia 6131 phone. As reported by Juan Ignacio Cherrutti, there's new firmware available but it still has the same old transfer-size limit. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* | USB: usb-storage: Initialize Huawei E220 properlyJohann Wilhelm2007-10-123-0/+28
| | | | | | | | | | | | | | | | | | | | | | This is a reworked version of this patch: http://www.mail-archive.com/linux-usb-devel%40lists.sourceforge.net/msg55094/activate_huawei_dev.patch That properly initializes the HUAWEI E220 devices into multi-port mode. Signed-off-by: Johann Wilhelm <johann.wilhelm@student.tugraz.at> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* | USB: Storage: usbat_check_status(): fix check-after-useAdrian Bunk2007-10-121-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | The Coverity checker spotted that we have already oops'ed if "us" was NULL. Since "us" can't be NULL in the only caller this patch removes the NULL check. Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Matthew Dharm <mdharm-usb@one-eyed-alien.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
OpenPOWER on IntegriCloud