Martin Dalecki [Wed, 6 Mar 2002 08:49:05 +0000 (00:49 -0800)]
[PATCH] IDE 17 (not just cleanup)
This is actually an attempt to remove some stall code from
this driver. However if some *real* users complain (Not just
the usuall: "Hey - if someone!" but the "Hey I'm using this!")
I'm all open to reenable it. Since I prepared this patch
yerstoday it doesn't contain the ide_module.h fixup. This will
follow later.
- Don't use the convoluted byte type in ide-pci.c. Just use the proper
u8instead.
- Move ide_get_or_set_dma_base to the only place where it's used and
reorganize the code there by killing the unnecessary
CONFIG_BLK_DEV_IDEDMA_FORCED configuration option.
- Remove unfunctional CONFIG_PKT_TASK_IOCTL code.
- Kill unused ALTSTAT_SCREW_UP code.
- Tons of dead code removed from ide-taskfile.c (#if 0 #endif and
friends)
- Remove unused IDE_DEBUG macro as well as lots of other name space
pollution from ide.h.
- Start using the ide_lock spin-lock for protecting access to data
structures instead of the excessive interrupt disabling games.
- Shorten the proc ouput of the piix initialization module.
- Remove special /proc tape "name" output from ide-tape.c. This was
redundant data which should only show up on syslog anyway.
- Kill the REALLY_FAST_IO undef from the ide.h. This was a mistake
present since far too many years in this driver. The proper way to
deal with broken systems is to define REALLY_SLOW_IO in system
dependent headers or particular driver files. We can always
reintroduce it easy if real users will complain, since OUT_BYTE() and
similar can be used as hooks. But I don't expect anybody reporting
about this. Even on the most broken IDE chip in the world (cmd640
at VLB) undefining this *always* worked for me. Nearly all the code
pieces in the ide driver code *reverted* it's effects explicitly
anyway.
- Remove the obsolete CONFIG_BLK_DEV_4DRIVES support. This was supposed
to support 4 drivers attached at one channel on some older chipsets,
in esp. Tekram 690CD, in the last century. They where all supposed to
work at a register set starting at the base address 0x1f0. Before
complaining that this is removing functionality, please note that this
must have been broken for already quite a long time, since the ide
driver didn't contain the special device selection methods implicated
by this any longer. It didn't scan this port too if PCI host chip
support was enabled (as it is in all those distributions around
there). On the other hand this is the most prominent case of
incoherent use of the mate member in the struct hwif_s. And please
think about how big the probability is, that there are systems out
there, where there are actually 4 drivers on such a channel?
- Streamline module initialization code by removing one shoot functions.
- Make the WAIT_READY value used in case of CONFIG_APM or
CONFIG_APM_MODULE the default, since this is what really reflects the
behavior of modern drives. It won't hurt any other case and finally
removing it is reducing the necessary coverage for overall driver code
testing/analysis.
- Move the IDE_LARGE_SEEK macro to the only place where it's actually
used. Replace the IDE_MIN() and IDE_MAX() drivers with the obvious.
Remove unused SPLIT_WORD and MAKE WORD from the local header.
- Remove CMD640_DUMP_REGS from global scope, since there is no
development done on this any longer. Finally, the way the host chip
initialization routines are called changed in the time between allows
this to remain fully local to the host chip driver in question.
- Some spell checking of comments in the code. (Yeep I have extended my
Vim to do this the "Word" way with nice undercurl lines... mozilla
remains to be fixed...)
Linus Torvalds [Wed, 6 Mar 2002 08:25:30 +0000 (00:25 -0800)]
Kernel lock exclusion is actually needed in the boot sequence,
so we need to make init_idle() aware of it so that it gets the
preempt_count initialization right.
Alexander Viro [Tue, 5 Mar 2002 11:24:42 +0000 (03:24 -0800)]
[PATCH] Re: "rename" breakage?
I've found what's going on there. Basically, we should not use
__user_walk() with LOOKUP_PARENT - nd->last.name is set to the last
component of the name and freeing that name before we are done is not a
good idea.
Adam Radford [Tue, 5 Mar 2002 07:16:17 +0000 (23:16 -0800)]
[PATCH] 3ware driver update for 2.5.6-pre3
- Fix bug in tw_aen_complete() where aen's could be lost.
Fix tw_aen_drain_queue() to display useful info at init.
Set tw_host->max_id for 12 port cards.
Add ioctl support for raw command packet post from userspace
with sglist fragments (parameter and io).
- Fix read capacity to under report by 1 sector to fix get
last sector ioctl.
- Fix bug where more AEN codes weren't coming out during
driver initialization.
Improved handling of PCI aborts.
- Fix bug in tw_findcards() where AEN code could be lost.
Increase timeout in tw_aen_drain_queue() to 30 seconds.
- Re-write raw command post with data ioctl method.
Remove raid5 bounce buffers for raid5 for 6XXX for kernel 2.5
Add tw_map/unmap_scsi_sg/single_data() for kernel 2.5
Replace io_request_lock with host_lock for kernel 2.5
Set max_cmd_len to 16 for 3dm for kernel 2.5
- Set host->max_sectors back up to 256.
- Modified pci parity error handling/clearing from config space
during initialization.
- Better handling of request sense opcode and sense information
for failed commands. Add tw_decode_sense().
Replace all mdelay()'s with scsi_sleep().
- Revert mdelay's and scsi_sleep's, this caused problems on
some SMP systems.
- Add pci_set_dma_mask(), rewrite kmalloc()/virt_to_bus() to
pci_alloc/free_consistent().
There is a problem with the through-8259A mode for IRQ 0 on I/O APIC
systems. Depending on correctness of an MP table, IRQ 0 routing is either
not registered at all or registered at a wrong pin. As a result the 8254
timer IRQ only works by an accident (it's edge-triggered and never
disabled/enabled so it happens to survive this incorrect configuration).
A visible effect is you can't change the affinity for IRQ 0.
Following is a patch that fixes both cases referred to above. The code
looks obvious but it was additionally run-time tested just in case. The
issue is serious -- please apply the patch ASAP. As no changes were done
to io_apic.c since the development fork, the patch applies cleanly both to
2.4 and to 2.5.
Credit goes to Joe for discovering the affinity problem and providing a
fix proposal (incorporated in the final one).
- Disable configuration of the task file stuff. It is going to go away
and will be replaced by a truly abstract interface based on
functionality and *not* direct mess-up of hardware.
- Resync with 2.5.6-pre2.
- Add HPT entries to the fall-back list, since otherwise the driver
won'trecognize the drives. We will have to make this the default
behavior for allnot recognized host chip types.
- Fix compilation with no PCI host chip support enabled.
- Apply the overflow fixes for HPT366 by Vojtech Pavlik.
- Kill the one-shoot functions ide_wait_cmd_taks() ide_wait_cmd() by
moving them to the places where they are actually used. Fix a
potential buffer overflow on the way.
- Fix usage of ide.c as module. Thanks to Adam J. Richter for figuring
out what was wrong.
- Various cleanups all along as well as removal of TONS of
unfinished/dead code.
I think it's sometimes better to remove stuff, which isn't there,
instead of hoping for a "magical day" where it will be finished.
Corey Minyard [Tue, 5 Mar 2002 07:02:25 +0000 (23:02 -0800)]
[PATCH] Re: PPP and shared zlib code in 2.5
Ok, I found it. The problem was in the decompression code.
In inflate.c, in the routine zlib_inflate(), it reuses the passed-in "f"
parameter as a return value, but the PPP packet compression stuff needs
that return value later.
Robert Love [Tue, 5 Mar 2002 06:59:06 +0000 (22:59 -0800)]
[PATCH] 2.5: preempt on UP critical fix
During 2.5.5-pre schedule_tail was optimized away under UP. We need it
for preempt-kernel, too, since it decrements the preempt_count to 0
coming off do_fork.
Without this patch, CONFIG_PREEMPT + !CONFIG_SMP does not gain one very
much.
Alexander Viro [Tue, 5 Mar 2002 06:56:47 +0000 (22:56 -0800)]
[PATCH] death of is_mounted() and aother fixes
* new functions - bd_claim(bdev, holder) and bd_release(bdev).
bd_claim(bdev, holder) fails is device is already claimed by
somebody else; bd_release(bdev) gives device up.
* get_sb_bdev() claims device for fs_type; it means that we don't need
to look through entire least of superblocks anymore - just through
the list of superblocks belonging to that type (i.e. the same thing
we do for non-block filesystems; that will allow to merge quite a
bit of code afterwards).
* sys_swapon claims device for itself; free exclusion with mounting,
end of problems with bogus set_blocksize().
* is_mounted() and is_swap_partition() are gone - what we actually
wanted was "try to claim device for ourselves". Which we can do
now - without races inherent to is_mounted()/is_swap_partition().
* RAID lock_rdev() claims device for itself. I.e. we get rid of
is_mounted() in there (BTW, is_swap_partition() was missing) and
we get protection both ways - not only RAID won't take an already
mounted device, but mount won't stomp on a device claimed by RAID.
There are other places that would benefit from the same (e.g. ext3 with
external journal almost definitely wants to claim device for itself).
Notice that it's a cooperative thing - neither open() nor raw device stuff
claim the block device, so they don't care if device is mounted, etc. So
we don't break fsck and friends - exclusion is between those who know that
they want that exclusion.
Jean Tourrilhes [Tue, 5 Mar 2002 06:53:24 +0000 (22:53 -0800)]
[PATCH] : ir256_usb_cow_urballoc.diff
ir256_usb_cow_urballoc.diff :
---------------------------
o [FEATURE] Don't use skb_cow() unless we really need to
o [CORRECT] Reorder URB init to avoid races
o [CORRECT] USB dealy adds processing time, not removes it
<Following patch from Greg KH <greg@kroah.com> himself !!!>
o [CRITICA] Use dynamically allocated URBs (instead of statically)
Jean Tourrilhes [Tue, 5 Mar 2002 06:53:19 +0000 (22:53 -0800)]
[PATCH] : ir256_lap_icmd_fix-4.diff
ir256_lap_icmd_fix-4.diff :
-------------------------
o [CORRECT] Fix Tx queue handling (remove race, keep packets in order)
o [CORRECT] Synchronise window_size & line_capacity and make sure
we never forget to increase them (would stall Tx queue)
o [FEATURE] Group common code out of if-then-else
o [FEATURE] Don't harcode LAP header size, use proper constant
o [FEATURE] Inline irlap_next_state() to decrease bloat
Boris Itkis [Sat, 2 Mar 2002 17:55:59 +0000 (17:55 +0000)]
[PATCH] 1007/1: Allow for not having the MSDOS partion manager for the arm
This patch allow for no MSDOS partition manager for the ARM. There are many arm
system with no hard disk partitions forcing a partition manager is not required.
Russell King [Sat, 2 Mar 2002 16:23:00 +0000 (16:23 +0000)]
Update PTE functions to be in line with 2.5.5.
This is a minimal "get it working again" patch; there are plans a
foot to re-jig the page table code to work better with Ingo Molnar's
changes. These same plans also allow the ARM page tabkes to fit
into Rik van Riel's rmap significantly better.
(We're currently abusing the struct page * returned from pte_alloc_one,
treating it as if it were the same as a pte_t *)
Russell King [Sat, 2 Mar 2002 15:32:50 +0000 (15:32 +0000)]
Fix up SA1100 PCMCIA for IRQ handling changes.
Major SA1100 generic DMA cleanup.
Fix suspend/resume bugs.
Provide and use new SA1111 generic driver for SA1111-based devices.
Jan Harkes [Sat, 2 Mar 2002 05:41:54 +0000 (21:41 -0800)]
[PATCH] 2.5.6-pre2 - Coda fixes and cleanups
Here is a batch of accumulated bugfixes and cleanups for the Coda kernel
module. Patch is against 2.5.6-pre2, I could also send these as separate
patches.
bugfix: Fix coda_dentry_revalidate bug
Due to a bad test, coda_dentry_revalidate was forcing revalidation
of cacheable inodes, and allowed caching of non-cacheable inodes.
bugfix: Corrected i_mtime/i_ctime setting
i_mtime and i_ctime were not always updated when writing to a file,
or when modifying inode attributes.
cleanup/optimization: Avoid getattr upcalls
We can use coda_iget directly instead of coda_cnode_make when an
upcall returns attributes and avoid the getattr upcall altogether.
cleanup: Removed debugging messages
CDEBUG macros haven't been useful ever since the initial development
when they were introduced. They are too verbose for debugging
purposes. Removing these saves about a third of the compiled size of
the module.
Removed print_entry variable that was used by ENTRY/EXIT macros
which are already gone.
cleanup/optimization: Readdir simplification
Relying on the fact that the pagecache is already buffering far more
efficiently, simplified coda_readdir implementation. We can now fill
the complete userbuffer instead of returning after reading only 2KB.
Passing dir entry types that are present in the venus_dirent
structure to the user as well.
The permission check count is about identical to the 'permission'
field in the VFS stats, and the permission hit counter can trivially
be derived from upcall_stats.access - vfs_stats.permission. Removed
these redundant counters.
cleanup: Removed useless test for c_flags in coda_revalidate_inode.
We already know c_flags is set due to earlier tests.
Paul Mackerras [Sun, 3 Mar 2002 07:19:52 +0000 (18:19 +1100)]
PPC update for the recent changes to the pgd/pmd/pte functions.
This implements ptes-in-highmem for PPC, removes the quicklist
and zero-page stuff. PTEs in highmem on SMP turned out to need
some significant changes to avoid deadlocks on the hash_table_lock
(now renamed to mmu_hash_lock). The PMDs now contain the physical
address of the PTE page rather than the virtual address.
Anything that takes the mmu_hash_lock now operates with the DMMU
off to avoid MMU hash-table misses.
Rusty Russell [Sat, 2 Mar 2002 05:32:52 +0000 (21:32 -0800)]
[PATCH] 2.5.6-pre2 I: 2.2.19-pre2 SYNC
This set of one-liners are the ones which have already gone
into 2.2.19-pre2.
Andrey Panin <pazke@orbita1.ru>: [PATCH] arch_i386_kernel_smpboot.c missing __init:
this patch adds missing __init directive for div64() function
in arch/i386/kernel/smpboot.c. div64() is only used
synchronize_tsc_bp() function which is marked __init.
Andrey Panin <pazke@orbita1.ru>: [PATCH] remove annoying ISAPNP message:
This patch removes useless messages like:
"isapnp: Calling quirk for 02:00".
John Fremlin <john@fremlin.de>: Patch to fix off by one in ide-scsi:
Patch to fix off by one in ide-scsi
To see it is correct compare with ide-cd behaviour
Alexander Viro [Sat, 2 Mar 2002 05:30:33 +0000 (21:30 -0800)]
[PATCH] path_lookup()
New helper:
path_lookup(name, flags, nd)
{
int err = 0;
if (path_init(name, flags, nd))
err = path_walk(name, nd);
return err;
}
Places doing that by hand converted to calling it.
Actually, quite a few of them were doing equivalent of __user_walk()
(getname() and if it was successful - call path_lookup() and putname()).
Converted to calling __user_walk().
Alexander Viro [Sat, 2 Mar 2002 05:30:13 +0000 (21:30 -0800)]
[PATCH] removal of LOOKUP_POSITIVE
LOOKUP_POSITIVE is not needed anymore. All callers of path_walk()
treat -ENOENT and negative dentry the same way. If you want a proof of
correctness - I'll send it, but it's a couple of pages of induction, basically
boiling down to "let's show that for any N we can replace the
if (lookup_flags & (LOOKUP_POSITIVE|LOOKUP_DIRECTORY))
break;
in link_path_walk() with
if ((lookup_flags & (LOOKUP_POSITIVE|LOOKUP_DIRECTORY)) ||
current->link_count <= N)
break;
without changing behaviour of the system". Pretty straightforward for
N = 0, then we look for places that can lead to call link_path_walk()
with current->link_count equal to N and show that if result of the test
changes, behaviour of callers doesn't. Since the depth of recursion is
limited, we had shown that test in question can be replaced with if (1).
And that's the only place in tree the ever checks for LOOKUP_POSITIVE.
The real reason behind that is very simple - indeed, suppose
we get a negative dentry out of path_walk(). What the hell could we
do with it? Its parent isn't locked, so both the name and parent can
change at any moment (could have changed already). There used to be
places that tried to play "let's get a negative dentry, lock its parent
and start doing something". All of them racy and all of them fixed
in 2.3. Fixed by switching to LOOKUP_PARENT...
Rik van Riel [Thu, 28 Feb 2002 20:13:57 +0000 (17:13 -0300)]
- janitor: clean up i810_dma.c and agpgart_be.c to use the macros
from mm.h instead of set_bit/clear_bit
- access page->count only through the atomic macros, remove the
broken init_page_count thing (DaveM)
Steven Cole [Thu, 28 Feb 2002 07:59:46 +0000 (02:59 -0500)]
This patch adds a help text for CONFIG_PHONE_IXJ_PCMCIA to
drivers/telephony/Config.help. The text was obtained from
Eric Raymond's Configure.help v2.97.
Linus Torvalds [Thu, 28 Feb 2002 04:45:11 +0000 (20:45 -0800)]
Fix off-by-one error reported by Anton Lavrentiev: we no
longer count the idle thread in "nr_threads", so we should
not discount it when returning sysinfo() information.
Alexander Viro [Thu, 28 Feb 2002 04:23:49 +0000 (20:23 -0800)]
[PATCH] (4/7) kdev_t removals
* write_some_buffers(), write_unlocked_buffers(), wait_for_buffers(),
wait_for_locked_buffers() and wait_for_some_buffers() converted
from kdev_t to struct block_device *.
Alexander Viro [Thu, 28 Feb 2002 04:23:44 +0000 (20:23 -0800)]
[PATCH] (3/7) kdev_t removals
* sync_buffers() split in two functions (sync_buffers() and
sync_all_buffers()). Callers of sync_buffers(NODEV) are
using the latter, those who actually pass a device - the former.
* sync_buffers() switched from kdev_t to struct block_device *.
Alexander Viro [Thu, 28 Feb 2002 04:23:33 +0000 (20:23 -0800)]
[PATCH] (1/7) kdev_t removals
* new function - fsync_bdev() (analog of fsync_dev(), but takes
struct block_device * instead of kdev_t. Callers of fsync_dev()
that have struct block_device in question are using fsync_bdev()
now.
* old code for fsync_dev(NODEV) had been moved to sys_sync().
Other callers of fsync_dev(NODEV) are calling sys_sync() now.
* fsync_dev() became a wrapper fro fsync_bdev().
* sync_dev() (not used anywhere in the tree) is gone.
* i2oblock.c had fsync_dev() called in ->release(). Removed.
* s390/block/xparm.c was doing fsync_dev() on its devices in
cleanup_module(). Removed.
Tim Waugh [Thu, 28 Feb 2002 04:19:29 +0000 (20:19 -0800)]
[PATCH] 2.5.6-pre1: parport and O_NONBLOCK
This patch makes lp and ppdev do the Right Thing regarding O_NONBLOCK.
2002-01-04 Tim Waugh <twaugh@redhat.com>
* include/linux/parport.h: Define a special inactivity timeout
meaning 'caller wants to use O_NONBLOCK'.
* drivers/char/lp.c: Support O_NONBLOCK properly.
* drivers/char/ppdev.c: Likewise.
* drivers/parport/parport_pc.c: Likewise.
* drivers/parport/ChangeLog: Updated.
Tim Waugh [Thu, 28 Feb 2002 04:19:24 +0000 (20:19 -0800)]
[PATCH] 2.5.6-pre1: shut lp up
This patch makes lp quieter in the common case that a printer does
_not_ speak ECP. (People have been writing to me worried that the
message means something bad.)
Martin Dalecki [Thu, 28 Feb 2002 04:15:37 +0000 (20:15 -0800)]
[PATCH] 2.5.6-pre1 IDE clean 14
Most importantly this patch is making ide.c use the
new automagic for module initialization lists and further
preparing the rest of the code in question here for proper
module separation. Despite this the CMOS probe has been removed
as well... *Iff*, which I don't expect, this breaks anything
it can be reintroduced easely. During this effort an actual bug
in the initialization of the main module has been uncovered as well.
a quite serious BUG has been tagged in ide-scsi.c as well, but
as far as now I just didn't get along to actually fixing it.
(The patch is big enough as it is).
Details follow:
- Kill *unused* ide_media_verbose() funciton.
- Remove the unnecessary media and supports_dma fields from
ide_driver_t.
- Remove the global name field from ide_driver_t struct by pushing it
down to the places where it's actually used.
- Remove the unused hwif_data field from ide_hwif_t.
- Push the supports_dsc_overlap condition up to the level where it
belongs: disk type as well.
- Make the initialization of ide main ide.c work with the new module
initialization auto-magic instead of calling it explicitly in
ll_rw_block.c This prevents the ide_init() from being called twice. We
have BTW. renamed it to ata_module_init(), since ata is more adequate
then ide and xxx_module_init corresponds better to the naming
conventions used elsewhere throughout the kernel.
This BUG was there before any ide-clean. It was worked around by a
magic variable preventing the second call to succeed. We have removed
this variable in one of the previous patches and thus uncovered it.
- Kill proc_ide_read_driver() and proc_ide_write_driver(). The drivers
already report on syslog which drives they have taken care of. (Or
at least they should). In esp. the proc_ide_write_driver() was just
too offending for me. Beleve it or not the purpose of it was to
*request a particular* driver for a device, by echoing some magic
values to a magic file...
More importantly this "back door" was getting in the way of a properly
done modularization of the IDE stuff.
- Made some not externally used functions static or not EXPORT-ed.
- Provide the start of a proper modularization between the main module
and drivers for particular device types. Changing the name-space
polluting DRIVER() macro to ata_ops() showed how inconsistently the
busy (read: module busy!) field from ide_driver_t
is currently used across the different device type modules.
This has to be fixed soon.
- Make the ide code use the similar device type ID numbers as the SCSI
code :-). This is just tedious, but it will help in a distant
feature. It helps reading the code anyway.
- Mark repettitive code with /* ATA-PATTERN */ comments for later
consolidation at places where we did came across it.
- Various comments and notes added where some explanations was missing.
Martin Dalecki [Thu, 28 Feb 2002 04:15:30 +0000 (20:15 -0800)]
[PATCH] 2.5.6-pre1 IDE clean 13a
This is finally moving the ide-pci.c file into a shape where
the host chip detection lists can finally be moved to where they
belong - into the particular chipset specific files.
This is accomplished, by a rather obivous removal of macro magic,
which was just making entries to the global device type
list nonfunctional, instead of making them conditional on the
corresponding CONFIG_BLHA options.
The second thing was to add a flag field to the device recognition
list, which made it possible to compress many of the
multi || chip id conditionals go away.
The only other file affected is ide.h - here is the change in the size
of the name field, which apparently slipped through ide-clean-12...
Martin Dalecki [Thu, 28 Feb 2002 04:15:25 +0000 (20:15 -0800)]
[PATCH] 2.5.5 IDE cleanup 12
1. Add some notes to Documentation/driver-model.txt about how and
and where to mount the driverfs.
2. Reorganize and prepare the PCI scanning code for proper device
dependant splitup. Basically tedious cleanup of macro games.
3. Use struct pci_dev name field as the name of PCI host dapaters
instead of invention ambigious IDE special names. This makes
the kernel bootup messages look a bit shifted, since those names are bit
longer, but makes up for consistance and should allow one later
to rearage things to fit into the generic PCI device initialization
mechanisms provided by the kernel.
4. Set 3. Allowed us to make the host chip specific
pci_init_xxx class functions have the proper signature of
module initializers. This will make it possible to make true
modules out of them later.
5. Make some functions in cmd64x.c static which where not used
elsewhere.
6. rename ide_special_settings to trust_pci_irq - this is reflecting
it's functionality better. And make it match the pci device vendor
as well as the device ID. It was a BUG to match only the device id!.
7. Make the chanell setup more tollerant for BIOS-es which don't
report IO and MEM bases properly. The code found previously there
tryed but was inconsistant.
8. Start to use proper terminology in ide-pci.c: host chip, channel,
drive instead of hwif, port, drive...
9. Enlarge the name field from ide_hwif_t to 64 bytes. It was only 6
previously and there where custom names there which where exceeding
this!!! But since we use the proper pci devce name there now instead,
we had to extend the size of this field anyway.
10. Add some explanatory comments and fix misguiding comments here and
there.
11. Kill the proc_ide_write_config and proc_ide_read_config brain
damage! Those where backdoors to the pci configuration registers on PCI
devices and IO registers on directly connected ISA ATA controllers.
They didn't discrement between them!
Access to both of them *simply* doesn't belong into an operating system,
which is supposed to abstract out the access to hardware! Did I mention
that access to both can be done from user land without an IDE special
interface! Any program which was using them (I hardly beleve there is
one) just deserves to loose. The programmer responsible for it
deserves to be fired immediately.
12. Move ide_map_xx and ide_unmap_xx tinny bio level wrappers away
from the "global" ide.h to where those are actually used and kill
trivial wrappers for otherwise generic bio_ routines. Just fighting
code obfuscation. The "rq->bio is used or is not there" brain
damage in ide-taskfile.c has to be fixed later. Possibly by killing
ide-taskfile.c alltogether, becouse this should be a driver for
users and not a driver for ATA disk disaster recovery companys...
13. Kill hwif->pci_devid and hwif->pci_venid. Just use the already
present hwif->pci_dev field instead.
14. Kill unused big switch ide_reinit_drive function. This silly
functon was switching upon every possible device driver cathegory
and calling the correspondng reinit function directly. This
idiocy was fortunately not used.
That's all... Most will be clear if one starts looking at the changes
in ide.h of course...
In contrast to the previous patches this one is actually fixing two
serious bugs.
The next direct step will be to kill the sigle place global PCI device
type recognition list from ide-pci.c by pushing the entries to where
they belong -> the host chips setup modules.
Martin Dalecki [Thu, 28 Feb 2002 04:15:18 +0000 (20:15 -0800)]
[PATCH] 2.5.6-pre1 IDE cleanup 11
1. Start of driver tree usage upon suggestion from Pavel Machek.
This still will needs a lot of further work in the future, but
the current code doesn't hurt anything and allowa Pavel to work
further from the base line. In esp. natively implemented
suspend to file requires this - which I would love to see comming
in,since I'm quite frequently using a notebook myself.
2. Kill the _IDE_C macro, which was playing games on entierly
unnecessary declarations inside of header files in esp ide_modes.h
3. Replace the functionally totally equal system_bus_block() and
ide_system_bus_speed() functions with one simple global
variable: system_bus_speed. This saves quite a significatn amount of
code. Unfortunately this is the part, which is makeing this
patch to appear bigger then it really is...
4. Use ide_devalidate_drive() directly instead of idedisk_revalidate().
5. Kill conditional CONFIG_KMOD as well as some other minor tweaks.
Well this isn't that much in terms of functionality, but it took me
quite q bit of time to catch up on the patch-2.5.5.gz ;-)
Martin Dalecki [Thu, 28 Feb 2002 04:15:12 +0000 (20:15 -0800)]
[PATCH] 2.5.6-pre1 IDE cleanup 10
This is finishing the cleanup parts already started in ide-clean-9.
It kills the ide_register_module() and ide_unregister_module() as well
as associated idiosyncracies alltogether. It turns out
that this patch is actually fixing a bug which was present in the
driver before: the sub-module initialization functions where called
at least twice - which is an abundance.
Tough there is a bit of global namespace pollution caused by this
patch - but I'm aware of it and will fix it just a bit later.
(The terminology used inside the IDE code is anyway nothing common
else in the linux universum...)
The next targets will be:
1. Code obfuscation by "wrappers" around generic BIO level functions.
2. ide_hwgroup_t - which is only used to serialize multiple
discs on the same interrupt and similar. This is however a tough one.
3. There is a plenty of code waste in the chipset drivers, where there
is baroque informative code for the proc file system for static stuff,
which in fact belongs just to syslog(). In fact the default RedHat
distribution kernel is killing this gratitious abuse of the /proc
concept since a long long time...
I'm still awaiting the day of /proc/GPL, where GPL contains the
full text of it...
Linus Torvalds [Thu, 28 Feb 2002 04:11:56 +0000 (20:11 -0800)]
Shrink icache more aggressively - if we free the dentries,
go ahead and free the inodes too, don't try to age them any
more (the aging has been done on a dentry level).
Steven Cole [Wed, 27 Feb 2002 14:20:26 +0000 (09:20 -0500)]
This patch adds help texts for CONFIG_SERIAL_TX3912,
CONFIG_SERIAL_TX3912_CONSOLE, CONFIG_AU1000_SERIAL_CONSOLE,
CONFIG_AU1000_UART, CONFIG_EUROTECH_WDT to drivers/char/Config.help.