<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/ata/ata_generic.c, branch v2.6.28</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v2.6.28</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v2.6.28'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2008-10-28T03:54:50+00:00</updated>
<entry>
<title>ata: Switch all my stuff to a common address</title>
<updated>2008-10-28T03:54:50+00:00</updated>
<author>
<name>Alan Cox</name>
<email>alan@lxorguk.ukuu.org.uk</email>
</author>
<published>2008-10-27T15:09:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=ab77163008c596aad9624ceab190d840c0143fa8'/>
<id>urn:sha1:ab77163008c596aad9624ceab190d840c0143fa8</id>
<content type='text'>
Signed-off-by: Jeff Garzik &lt;jgarzik@redhat.com&gt;
</content>
</entry>
<entry>
<title>pata_atiixp: Don't disable</title>
<updated>2008-05-06T15:43:44+00:00</updated>
<author>
<name>Alan Cox</name>
<email>alan@lxorguk.ukuu.org.uk</email>
</author>
<published>2008-05-02T22:13:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=05177f178efe1459d2d0ac05430027ba201889a4'/>
<id>urn:sha1:05177f178efe1459d2d0ac05430027ba201889a4</id>
<content type='text'>
A couple of distributions (Fedora, Ubuntu) were having weird problems with the
ATI IXP series PATA controllers being reported as simplex.  At the heart of
the problem is that both distros ignored the recommendations to load pata_acpi
and ata_generic *AFTER* specific host drivers.

The underlying cause however is that if you D3 and then D0 an ATI IXP it
helpfully throws away some configuration and won't let you rewrite it.

Add checks to ata_generic and pata_acpi to pin ATIIXP devices.  Possibly the
real answer here is to quirk them and pin them, but right now we can't do that
before they've been pcim_enable()'d by a driver.

I'm indebted to David Gero for this.  His bug report not only reported the
problem but identified the cause correctly and he had tested the right values
to prove what was going on

[If you backport this for 2.6.24 you will need to pull in the 2.6.25
removal of the bogus WARN_ON() in pcim_enagle]

Signed-off-by: Alan Cox &lt;alan@redhat.com&gt;
Tested-by: David Gero &lt;davidg@havidave.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Jeff Garzik &lt;jgarzik@redhat.com&gt;
</content>
</entry>
<entry>
<title>libata: rename SFF functions</title>
<updated>2008-04-17T19:44:21+00:00</updated>
<author>
<name>Tejun Heo</name>
<email>htejun@gmail.com</email>
</author>
<published>2008-04-07T13:47:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=9363c3825ea9ad76561eb48a395349dd29211ed6'/>
<id>urn:sha1:9363c3825ea9ad76561eb48a395349dd29211ed6</id>
<content type='text'>
SFF functions have confusing names.  Some have sff prefix, some have
bmdma, some std, some pci and some none.  Unify the naming by...

* SFF functions which are common to both BMDMA and non-BMDMA are
  prefixed with ata_sff_.

* SFF functions which are specific to BMDMA are prefixed with
  ata_bmdma_.

* SFF functions which are specific to PCI but apply to both BMDMA and
  non-BMDMA are prefixed with ata_pci_sff_.

* SFF functions which are specific to PCI and BMDMA are prefixed with
  ata_pci_bmdma_.

* Drop generic prefixes from LLD specific routines.  For example,
  bfin_std_dev_select -&gt; bfin_dev_select.

The following renames are noteworthy.

  ata_qc_issue_prot() -&gt; ata_sff_qc_issue()
  ata_pci_default_filter() -&gt; ata_bmdma_mode_filter()
  ata_dev_try_classify() -&gt; ata_sff_dev_classify()

This rename is in preparation of separating SFF support out of libata
core layer.  This patch strictly renames functions and doesn't
introduce any behavior difference.

Signed-off-by: Tejun Heo &lt;htejun@gmail.com&gt;
</content>
</entry>
<entry>
<title>libata: stop overloading port_info-&gt;private_data</title>
<updated>2008-04-17T19:44:17+00:00</updated>
<author>
<name>Tejun Heo</name>
<email>htejun@gmail.com</email>
</author>
<published>2008-03-25T03:22:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=887125e3740283be25564bfc6fb5d24974b651ab'/>
<id>urn:sha1:887125e3740283be25564bfc6fb5d24974b651ab</id>
<content type='text'>
port_info-&gt;private_data is currently used for two purposes - to record
private data about the port_info or to specify host-&gt;private_data to
use when allocating ata_host.

This overloading is confusing and counter-intuitive in that
port_info-&gt;private_data becomes host-&gt;private_data instead of
port-&gt;private_data.  In addition, port_info and host don't correspond
to each other 1-to-1.  Currently, the first non-NULL
port_info-&gt;private_data is used.

This patch makes port_info-&gt;private_data just be what it is -
private_data for the port_info where LLD can jot down extra info.
libata no longer sets host-&gt;private_data to the first non-NULL
port_info-&gt;private_data, @host_priv argument is added to
ata_pci_init_one() instead.  LLDs which use ata_pci_init_one() can use
this argument to pass in pointer to host private data.  LLDs which
don't should use init-register model anyway and can initialize
host-&gt;private_data directly.

Adding @host_priv instead of using init-register model for LLDs which
use ata_pci_init_one() is suggested by Alan Cox.

Signed-off-by: Tejun Heo &lt;htejun@gmail.com&gt;
Cc: Alan Cox &lt;alan@lxorguk.ukuu.org.uk&gt;
</content>
</entry>
<entry>
<title>libata: make ata_pci_init_one() not use ops-&gt;irq_handler and pi-&gt;sht</title>
<updated>2008-04-17T19:44:17+00:00</updated>
<author>
<name>Tejun Heo</name>
<email>htejun@gmail.com</email>
</author>
<published>2008-03-25T03:22:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=1bd5b715a305f6f13455e89becbd839010dd14b5'/>
<id>urn:sha1:1bd5b715a305f6f13455e89becbd839010dd14b5</id>
<content type='text'>
ata_pci_init_one() is the only function which uses ops-&gt;irq_handler
and pi-&gt;sht.  Other initialization functions take the same information
as arguments.  This causes confusion and duplicate unused entries in
structures.

Make ata_pci_init_one() take sht as an argument and use ata_interrupt
implicitly.  All current users use ata_interrupt and if different irq
handler is necessary open coding ata_pci_init_one() using
ata_prepare_sff_host() and ata_activate_sff_host can be done under ten
lines including error handling and driver which requires custom
interrupt handler is likely to require custom initialization anyway.

As ata_pci_init_one() was the last user of ops-&gt;irq_handler, this
patch also kills the field.

Signed-off-by: Tejun Heo &lt;htejun@gmail.com&gt;
</content>
</entry>
<entry>
<title>libata: implement and use ops inheritance</title>
<updated>2008-04-17T19:44:17+00:00</updated>
<author>
<name>Tejun Heo</name>
<email>htejun@gmail.com</email>
</author>
<published>2008-03-25T03:22:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=029cfd6b74fc5c517865fad78cf4a3ea8d9b664a'/>
<id>urn:sha1:029cfd6b74fc5c517865fad78cf4a3ea8d9b664a</id>
<content type='text'>
libata lets low level drivers build ata_port_operations table and
register it with libata core layer.  This allows low level drivers
high level of flexibility but also burdens them with lots of
boilerplate entries.

This becomes worse for drivers which support related similar
controllers which differ slightly.  They share most of the operations
except for a few.  However, the driver still needs to list all
operations for each variant.  This results in large number of
duplicate entries, which is not only inefficient but also error-prone
as it becomes very difficult to tell what the actual differences are.

This duplicate boilerplates all over the low level drivers also make
updating the core layer exteremely difficult and error-prone.  When
compounded with multi-branched development model, it ends up
accumulating inconsistencies over time.  Some of those inconsistencies
cause immediate problems and fixed.  Others just remain there dormant
making maintenance increasingly difficult.

To rectify the problem, this patch implements ata_port_operations
inheritance.  To allow LLDs to easily re-use their own ops tables
overriding only specific methods, this patch implements poor man's
class inheritance.  An ops table has -&gt;inherits field which can be set
to any ops table as long as it doesn't create a loop.  When the host
is started, the inheritance chain is followed and any operation which
isn't specified is taken from the nearest ancestor which has it
specified.  This operation is called finalization and done only once
per an ops table and the LLD doesn't have to do anything special about
it other than making the ops table non-const such that libata can
update it.

libata provides four base ops tables lower drivers can inherit from -
base, sata, pmp, sff and bmdma.  To avoid overriding these ops
accidentaly, these ops are declared const and LLDs should always
inherit these instead of using them directly.

After finalization, all the ops table are identical before and after
the patch except for setting .irq_handler to ata_interrupt in drivers
which didn't use to.  The .irq_handler doesn't have any actual effect
and the field will soon be removed by later patch.

* sata_sx4 is still using old style EH and currently doesn't take
  advantage of ops inheritance.

Signed-off-by: Tejun Heo &lt;htejun@gmail.com&gt;
</content>
</entry>
<entry>
<title>libata: implement and use SHT initializers</title>
<updated>2008-04-17T19:44:17+00:00</updated>
<author>
<name>Tejun Heo</name>
<email>htejun@gmail.com</email>
</author>
<published>2008-03-25T03:22:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=68d1d07b510bb57a504588adc2bd2758adea0965'/>
<id>urn:sha1:68d1d07b510bb57a504588adc2bd2758adea0965</id>
<content type='text'>
libata lets low level drivers build scsi_host_template and register it
to the SCSI layer.  This allows low level drivers high level of
flexibility but also burdens them with lots of boilerplate entries.

This patch implements SHT initializers which can be used to initialize
all the boilerplate entries in a sht.  Three variants of them are
implemented - BASE, BMDMA and NCQ - for different types of drivers.
Note that entries can be overriden by putting individual initializers
after the helper macro.

All sht tables are identical before and after this patch.

Signed-off-by: Tejun Heo &lt;htejun@gmail.com&gt;
</content>
</entry>
<entry>
<title>libata: normalize port_info, port_operations and sht tables</title>
<updated>2008-04-17T19:44:17+00:00</updated>
<author>
<name>Tejun Heo</name>
<email>htejun@gmail.com</email>
</author>
<published>2008-03-25T03:22:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=6bd99b4e0998571808fc1f09d5162348f21ff8c1'/>
<id>urn:sha1:6bd99b4e0998571808fc1f09d5162348f21ff8c1</id>
<content type='text'>
Over the time, port info, ops and sht structures developed quite a bit
of inconsistencies.  This patch updates drivers.

* Enable/disable_pm callbacks added to all ahci ops tables.

* Every driver for SFF controllers now uses ata_sff_port_start()
  instead of ata_port_start() unless the driver has custom
  implementation.

* Every driver for SFF controllers now uses ata_pci_default_filter()
  unless the driver has custom implementation.

* Removed an odd port_info-&gt;sht initialization from ata_piix.c.
  Likely a merge byproduct.

* A port which has ATA_FLAG_SATA set doesn't need to set cable_detect
  to ata_cable_sata().  Remove it from via and mv port ops.

* Some drivers had unnecessary .max_sectors initialization which is
  ignored and was missing .slave_destroy callback.  Fixed.

* Removed unnecessary sht initializations port_info's.

* Removed onsolete scsi device suspend/resume callbacks from
  pata_bf54x.

* No reason to set ata_pci_default_filter() and bmdma functions for
  PIO-only drivers.  Remove those callbacks and replace
  ata_bmdma_irq_clear with ata_noop_irq_clear.

* pata_platform sets port_start to ata_dummy_ret0.  port_start can
  just be set to NULL.

* sata_fsl supports NCQ but was missing qc_defer.  Fixed.

* pata_rb600_cf implements dummy port_start.  Removed.

Signed-off-by: Tejun Heo &lt;htejun@gmail.com&gt;
</content>
</entry>
<entry>
<title>ata_generic: Cenatek support</title>
<updated>2008-01-23T10:24:17+00:00</updated>
<author>
<name>Alan Cox</name>
<email>alan@lxorguk.ukuu.org.uk</email>
</author>
<published>2008-01-19T16:07:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=5e8f757cb2e0f67bf43f71d5180a8bf0ab3484eb'/>
<id>urn:sha1:5e8f757cb2e0f67bf43f71d5180a8bf0ab3484eb</id>
<content type='text'>
Not much to do here. It's an ata memory as disk.

Signed-off-by: Alan Cox &lt;alan@redhat.com&gt;
Signed-off-by: Jeff Garzik &lt;jeff@garzik.org&gt;
</content>
</entry>
<entry>
<title>libata: kill ata_id_to_dma_mode()</title>
<updated>2008-01-23T10:24:11+00:00</updated>
<author>
<name>Tejun Heo</name>
<email>htejun@gmail.com</email>
</author>
<published>2007-11-27T10:43:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=9d3501ab962b1506d93974faf8509251b4a85fbc'/>
<id>urn:sha1:9d3501ab962b1506d93974faf8509251b4a85fbc</id>
<content type='text'>
ata_id_to_dma_mode() isn't quite generic.  The function is basically
privately implemented ata_id_xfermask() combined with hardcoded mode
printing and configuration which are specific to ata_generic.

Kill the function and open code it in generic_set_mode() using generic
xfermode handling functions.

Signed-off-by: Tejun Heo &lt;htejun@gmail.com&gt;
Signed-off-by: Jeff Garzik &lt;jeff@garzik.org&gt;
</content>
</entry>
</feed>
