02 Aug, 2007
1 commit
-
drivers/ide/ide-tape.c: In function '__idetape_kmalloc_stage':
drivers/ide/ide-tape.c:2588: warning: large integer implicitly truncated to unsigned type
drivers/ide/ide-tape.c:2616: warning: large integer implicitly truncated to unsigned typeb_size in struct idetape_bh is an unsigned short. We sometimes assigne
PAGE_SIZE to it and PAGE_SIZE can be 64K or larger, so make it a u32.Signed-off-by: Stephen Rothwell
Signed-off-by: Bartlomiej Zolnierkiewicz
10 May, 2007
3 commits
-
* move
__ide_add_setting()
ide_add_setting()
__ide_remove_setting()
auto_remove_settings()
ide_find_setting_by_name()
ide_read_setting()
ide_write_setting()
set_xfer_rate()
ide_add_generic_settings()
ide_register_subdriver()
ide_unregister_subdriver()from ide.c to ide-proc.c
* set_{io_32bit,pio_mode,using_dma}() cannot be marked static now, fix it
* rename ide_[un]register_subdriver() to ide_proc_[un]register_driver(),
update device drivers to use new names* add CONFIG_IDE_PROC_FS=n versions of ide_proc_[un]register_driver()
and ide_add_generic_settings()* make ide_find_setting_by_name(), ide_{read,write}_setting()
and ide_{add,remove}_proc_entries() static* cover IDE settings code in device drivers with CONFIG_IDE_PROC_FS #ifdef,
also while at it cover with CONFIG_IDE_PROC_FS #ifdef ide_driver_t.proc* remove bogus comment from ide.h
* cover with CONFIG_IDE_PROC_FS #ifdef .proc and .settings in ide_drive_t
Besides saner code this patch results in the IDE core smaller by ~2 kB
(on x86-32) and IDE disk driver by ~1 kB (ditto) when CONFIG_IDE_PROC_FS=n.Signed-off-by: Bartlomiej Zolnierkiewicz
-
* do write permission and min/max checks in ide_procset_t functions
* ide-disk.c: drive->id is always available so cleanup "multcount" setting
accordingly* ide-disk.c: "address" setting was incorrectly defined as type TYPE_INTA,
fix it by using type TYPE_BYTE and updating ide_drive_t->adressing field,
the bug didn't trigger because this IDE setting uses custom ->set function* ide.c: add set_ksettings() for handling HDIO_SET_KEEPSETTINGS ioctl
* ide.c: add set_unmaskirq() for handling HDIO_SET_UNMASKINTR ioctl
* handle ioctls directly in generic_ide_ioclt() and idedisk_ioctl()
instead of using IDE settings to deal with them* remove no longer needed ide_find_setting_by_ioctl() and {read,write}_ioctl
fields from ide_settings_t, also remove now unused TYPE_INTA handlingv2:
* add missing EXPORT_SYMBOL_GPL(ide_setting_sem) needed now for ide-diskSigned-off-by: Bartlomiej Zolnierkiewicz
-
All important information/features should be already available through
sysfs and ioctl interfaces.Add CONFIG_IDE_PROC_FS (CONFIG_SCSI_PROC_FS rip-off) config option,
disabling it makes IDE driver ~5 kB smaller (on x86-32).While at it add CONFIG_PROC_FS=n versions of proc_ide_{create,destroy}()
and remove no longer needed #ifdefs.Signed-off-by: Bartlomiej Zolnierkiewicz
17 Feb, 2007
2 commits
-
* since ide_hwif_t.ide_dma_{host_off,off_quietly} always return '0'
make these functions void and while at it drop "ide_" prefix
* fix comment for __ide_dma_off_quietly()
* make __ide_dma_{host_off,off_quietly,off}() void and drop "__" prefixv2:
* while at it rename atiixp_ide_dma_host_off() to atiixp_dma_host_off(),
sgiioc4_ide_dma_{host_off,off_quietly}() to sgiioc4_dma_{host_off,off_quietly}()
and sl82c105_ide_dma_off_quietly() to sl82c105_dma_off_quietly()
[ Noticed by Sergei Shtylyov . ]Signed-off-by: Bartlomiej Zolnierkiewicz
-
This field is no longer used by the core IDE code so fix ide-{disk,floppy}
drivers to keep openers count in the driver specific objects and remove
it from ide-{cd,scsi,tape} drivers (it was write-only).Signed-off-by: Bartlomiej Zolnierkiewicz
13 Feb, 2007
1 commit
-
Many struct file_operations in the kernel can be "const". Marking them const
moves these to the .rodata section, which avoids false sharing with potential
dirty data. In addition it'll catch accidental writes at compile time to
these shared resources.Signed-off-by: Arjan van de Ven
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
14 Dec, 2006
1 commit
-
Run this:
#!/bin/sh
for f in $(grep -Erl "\([^\)]*\) *k[cmz]alloc" *) ; do
echo "De-casting $f..."
perl -pi -e "s/ ?= ?\([^\)]*\) *(k[cmz]alloc) *\(/ = \1\(/" $f
doneAnd then go through and reinstate those cases where code is casting pointers
to non-pointers.And then drop a few hunks which conflicted with outstanding work.
Cc: Russell King , Ian Molton
Cc: Mikael Starvik
Cc: Yoshinori Sato
Cc: Roman Zippel
Cc: Geert Uytterhoeven
Cc: Ralf Baechle
Cc: Paul Mackerras
Cc: Kyle McMartin
Cc: Benjamin Herrenschmidt
Cc: Martin Schwidefsky
Cc: "David S. Miller"
Cc: Jeff Dike
Cc: Greg KH
Cc: Jens Axboe
Cc: Paul Fulghum
Cc: Alan Cox
Cc: Karsten Keil
Cc: Mauro Carvalho Chehab
Cc: Jeff Garzik
Cc: James Bottomley
Cc: Ian Kent
Cc: Steven French
Cc: David Woodhouse
Cc: Neil Brown
Cc: Jaroslav Kysela
Cc: Takashi Iwai
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
01 Oct, 2006
4 commits
-
All on stack DECLARE_COMPLETIONs should be replaced by:
DECLARE_COMPLETION_ONSTACKSigned-off-by: Peter Zijlstra
Acked-by: Ingo Molnar
Acked-by: Benjamin Herrenschmidt
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
After Christophs SCSI change, the only usage left is RQ_ACTIVE
and RQ_INACTIVE. The block layer sets RQ_INACTIVE right before freeing
the request, so any check for RQ_INACTIVE in a driver is a bug and
indicates use-after-free.So kill/clean the remaining users, straight forward.
Signed-off-by: Jens Axboe
-
As the comments indicates in blkdev.h, we can fold it into ->end_io_data
usage as that is really what ->waiting is. Fixup the users of
blk_end_sync_rq().Signed-off-by: Jens Axboe
-
Right now ->flags is a bit of a mess: some are request types, and
others are just modifiers. Clean this up by splitting it into
->cmd_type and ->cmd_flags. This allows introduction of generic
Linux block message types, useful for sending generic Linux commands
to block devices.Signed-off-by: Jens Axboe
01 Jul, 2006
1 commit
-
Signed-off-by: Jörn Engel
Signed-off-by: Adrian Bunk
27 Jun, 2006
1 commit
-
Also removes the ide drive devfs_name field as it's no longer needed
Signed-off-by: Greg Kroah-Hartman
26 Jun, 2006
1 commit
-
In both the read and write cases it will return an error if
copy_{from/to}_user faults. However, I let the driver try to read/write as
much as it can just as it normally would , then finally it returns an error
if there was one. This was the most straight forward way to handle the
error , since there isn't a clear way to clean up the buffers on error .I moved retval in idetape_chrdev_write() down into the actual code blocks
since it's really once used there, and it conflicted with my ret variable.Fixes the following warning,
drivers/ide/ide-tape.c: In function âidetape_copy_stage_from_userâ:
drivers/ide/ide-tape.c:2662: warning: ignoring return value of âcopy_from_userâ, declared with attribute warn_unused_result
drivers/ide/ide-tape.c: In function âidetape_copy_stage_to_userâ:
drivers/ide/ide-tape.c:2689: warning: ignoring return value of âcopy_to_userâ, declared with attribute warn_unused_resultSigned-off-by: Daniel Walker
Cc: Alan Cox
Cc: Bartlomiej Zolnierkiewicz
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
29 Mar, 2006
1 commit
-
They deal with wrapping correctly and are nicer to read.
Signed-off-by: Marcelo Feitoza Parisi
Signed-off-by: Alexey Dobriyan
Cc: Bartlomiej Zolnierkiewicz
Cc: Jens Axboe
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
23 Mar, 2006
1 commit
-
Semaphore to mutex conversion.
The conversion was generated via scripts, and the result was validated
automatically via a script as well.Signed-off-by: Arjan van de Ven
Signed-off-by: Ingo Molnar
Acked-by: Bartlomiej Zolnierkiewicz
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
14 Jan, 2006
1 commit
-
Signed-off-by: Russell King
Signed-off-by: Greg Kroah-Hartman
05 Jan, 2006
1 commit
-
IDE: MODALIAS support for autoloading of ide-cd, ide-disk, ...
Add MODULE_ALIAS to IDE midlayer modules: ide-disk, ide-cd, ide-floppy and
ide-tape, to autoload these modules depending on the probed media type of
the IDE device.It is used by udev and replaces the former agent shell script of the hotplug
package, which was required to lookup the media type in the proc filesystem.
Using proc was racy, cause the media file is created after the hotplug event
is sent out.The module autoloading does not take any effect, until something like the
following udev rule is configured:
SUBSYSTEM=="ide", ACTION=="add", ENV{MODALIAS}=="?*", RUN+="/sbin/modprobe $env{MODALIAS}"The module ide-scsi will not be autoloaded, cause it requires manual
configuration. It can't be, and never was supported for automatic setup in
the hotplug package. Adding a MODULE_ALIAS to ide-scsi for all supported
media types, would just lead to a default blacklist entry anyway.$ modinfo ide-disk
filename: /lib/modules/2.6.15-rc4-g1b0997f5/kernel/drivers/ide/ide-disk.ko
description: ATA DISK Driver
alias: ide:*m-disk*
license: GPL
...$ modprobe -vn ide:m-disk
insmod /lib/modules/2.6.15-rc4-g1b0997f5/kernel/drivers/ide/ide-disk.ko$ cat /sys/bus/ide/devices/0.0/modalias
ide:m-diskIt also adds attributes to the IDE device:
$ tree /sys/bus/ide/devices/0.0/
/sys/bus/ide/devices/0.0/
|-- bus -> ../../../../../../../bus/ide
|-- drivename
|-- media
|-- modalias
|-- power
| |-- state
| `-- wakeup
`-- uevent$ cat /sys/bus/ide/devices/0.0/{modalias,drivename,media}
ide:m-disk
hda
diskSigned-off-by: Kay Sievers
Signed-off-by: Greg Kroah-Hartman
20 Nov, 2005
1 commit
-
Also remove bogus comments for idefloppy_init() and idetape_init().
Signed-off-by: Bartlomiej Zolnierkiewicz
19 Nov, 2005
1 commit
-
The structure ide_driver_t have a .owner field which is a duplicate
of .gendriver.owner field (.gen_driver is a struct device_driver).This patch removes ide_driver_t's owner field.
Signed-off-by: Laurent Riffard
Signed-off-by: Bartlomiej Zolnierkiewicz
07 Nov, 2005
1 commit
-
Signed-off-by: Deepak Saxena
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
29 Oct, 2005
2 commits
-
The previous patch adding the ability to nest struct class_device
changed the paramaters to the call class_device_create(). This patch
fixes up all in-kernel users of the function.Signed-off-by: Greg Kroah-Hartman
-
I was recently given an old Travan tape drive and asked to do something
useful with it. The ide-scsi + st (+serverworks ide controller) combo
results in a hard lockup of the machine which I have not had the energy to
debug, so I turned to ide-tape (which seems to work). The system in
question debian stable, using udev to manage /dev.The following patch to ide-tape.c allows udev to create the cdev nodes for
my drive.Cc: Gadi Oxman
Cc: Greg KH
Signed-off-by: Andrew Morton
Signed-off-by: Greg Kroah-Hartman
11 Sep, 2005
1 commit
-
Uses msleep() instead of schedule_timeout() to guarantee
the task delays at least the desired time amount.Signed-off-by: Nishanth Aravamudan
Signed-off-by: Maximilian Attems
Signed-off-by: Domen Puncer
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
26 May, 2005
1 commit
-
* add ide_bus_match() and export ide_bus_type
* split ide_remove_driver_from_hwgroup() out of ide_unregister()
* move device cleanup from ide_unregister() to drive_release_dev()
* convert ide_driver_t->name to driver->name
* convert ide_driver_t->{attach,cleanup} to driver->{probe,remove}
* remove ide_driver_t->busy as ide_bus_type->subsys.rwsem
protects against concurrent ->{probe,remove} calls
* make ide_{un}register_driver() void as it cannot fail now
* use driver_{un}register() directly, remove ide_{un}register_driver()
* use device_register() instead of ata_attach(), remove ata_attach()
* add proc_print_driver() and ide_drivers_show(), remove ide_drivers_op
* fix ide_replace_subdriver() and move it to ide-proc.c
* remove ide_driver_t->drives, ide_drives and drives_lock
* remove ide_driver_t->drivers, drivers and drivers_lock
* remove ide_drive_t->driver and DRIVER() macroSigned-off-by: Bartlomiej Zolnierkiewicz
17 Apr, 2005
1 commit
-
Initial git repository build. I'm not bothering with the full history,
even though we have it. We can create a separate "historical" git
archive of that later if we want to, and in the meantime it's about
3.2GB when imported into git - space that would just make the early
git days unnecessarily complicated, when we don't have a lot of good
infrastructure for it.Let it rip!