<feed xmlns='http://www.w3.org/2005/Atom'>
<title>user/sven/linux.git/drivers/ata, branch v3.18.31</title>
<subtitle>Linux Kernel
</subtitle>
<id>https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v3.18.31</id>
<link rel='self' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v3.18.31'/>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/'/>
<updated>2016-03-08T02:29:57Z</updated>
<entry>
<title>Adding Intel Lewisburg device IDs for SATA</title>
<updated>2016-03-08T02:29:57Z</updated>
<author>
<name>Alexandra Yates</name>
<email>alexandra.yates@linux.intel.com</email>
</author>
<published>2016-02-18T03:36:20Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=0b17b1b036503671b2960883c629a67d60e8c488'/>
<id>urn:sha1:0b17b1b036503671b2960883c629a67d60e8c488</id>
<content type='text'>
[ Upstream commit f5bdd66c705484b4bc77eb914be15c1b7881fae7 ]

This patch complements the list of device IDs previously
added for lewisburg sata.

Signed-off-by: Alexandra Yates &lt;alexandra.yates@linux.intel.com&gt;
Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Sasha Levin &lt;sasha.levin@oracle.com&gt;
</content>
</entry>
<entry>
<title>ahci: Order SATA device IDs for codename Lewisburg</title>
<updated>2016-03-08T02:29:48Z</updated>
<author>
<name>Alexandra Yates</name>
<email>alexandra.yates@linux.intel.com</email>
</author>
<published>2015-11-16T16:22:16Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=1c522e28c418c16df3d8d31404854355961fdd7b'/>
<id>urn:sha1:1c522e28c418c16df3d8d31404854355961fdd7b</id>
<content type='text'>
[ Upstream commit 4d92f0099a06ef0e36c7673f7c090f1a448b2d1b ]

This change was to preserve the ascending order of device IDs.
There was an exception with the first two Lewisburg device IDs to
keep all device IDs of the same kind grouped by code name.

Signed-off-by: Alexandra Yates &lt;alexandra.yates@linux.intel.com&gt;
signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
Signed-off-by: Sasha Levin &lt;sasha.levin@oracle.com&gt;
</content>
</entry>
<entry>
<title>libata: fix HDIO_GET_32BIT ioctl</title>
<updated>2016-03-08T02:13:02Z</updated>
<author>
<name>Arnd Bergmann</name>
<email>arnd@arndb.de</email>
</author>
<published>2016-02-11T13:16:27Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=6e9c571aa944bf652e64b1df8446b2010ab2a8f0'/>
<id>urn:sha1:6e9c571aa944bf652e64b1df8446b2010ab2a8f0</id>
<content type='text'>
[ Upstream commit 287e6611ab1eac76c2c5ebf6e345e04c80ca9c61 ]

As reported by Soohoon Lee, the HDIO_GET_32BIT ioctl does not
work correctly in compat mode with libata.

I have investigated the issue further and found multiple problems
that all appeared with the same commit that originally introduced
HDIO_GET_32BIT handling in libata back in linux-2.6.8 and presumably
also linux-2.4, as the code uses "copy_to_user(arg, &amp;val, 1)" to copy
a 'long' variable containing either 0 or 1 to user space.

The problems with this are:

* On big-endian machines, this will always write a zero because it
  stores the wrong byte into user space.

* In compat mode, the upper three bytes of the variable are updated
  by the compat_hdio_ioctl() function, but they now contain
  uninitialized stack data.

* The hdparm tool calling this ioctl uses a 'static long' variable
  to store the result. This means at least the upper bytes are
  initialized to zero, but calling another ioctl like HDIO_GET_MULTCOUNT
  would fill them with data that remains stale when the low byte
  is overwritten. Fortunately libata doesn't implement any of the
  affected ioctl commands, so this would only happen when we query
  both an IDE and an ATA device in the same command such as
  "hdparm -N -c /dev/hda /dev/sda"

* The libata code for unknown reasons started using ATA_IOC_GET_IO32
  and ATA_IOC_SET_IO32 as aliases for HDIO_GET_32BIT and HDIO_SET_32BIT,
  while the ioctl commands that were added later use the normal
  HDIO_* names. This is harmless but rather confusing.

This addresses all four issues by changing the code to use put_user()
on an 'unsigned long' variable in HDIO_GET_32BIT, like the IDE subsystem
does, and by clarifying the names of the ioctl commands.

Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Reported-by: Soohoon Lee &lt;Soohoon.Lee@f5.com&gt;
Tested-by: Soohoon Lee &lt;Soohoon.Lee@f5.com&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
Signed-off-by: Sasha Levin &lt;sasha.levin@oracle.com&gt;
</content>
</entry>
<entry>
<title>ahci: Intel DNV device IDs SATA</title>
<updated>2016-03-04T15:18:40Z</updated>
<author>
<name>Alexandra Yates</name>
<email>alexandra.yates@linux.intel.com</email>
</author>
<published>2016-02-05T23:27:49Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=97e8007ccee791c1eddb3822c1597979cbe8a45e'/>
<id>urn:sha1:97e8007ccee791c1eddb3822c1597979cbe8a45e</id>
<content type='text'>
[ Upstream commit 342decff2b846b46fa61eb5ee40986fab79a9a32 ]

Adding Intel codename DNV platform device IDs for SATA.

Signed-off-by: Alexandra Yates &lt;alexandra.yates@linux.intel.com&gt;
Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Sasha Levin &lt;sasha.levin@oracle.com&gt;
</content>
</entry>
<entry>
<title>libata: fix sff host state machine locking while polling</title>
<updated>2016-03-02T20:18:54Z</updated>
<author>
<name>Tejun Heo</name>
<email>tj@kernel.org</email>
</author>
<published>2016-02-01T16:33:21Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=99f2717cfa1e34340b14d06a2f156fab147b5da3'/>
<id>urn:sha1:99f2717cfa1e34340b14d06a2f156fab147b5da3</id>
<content type='text'>
[ Upstream commit 8eee1d3ed5b6fc8e14389567c9a6f53f82bb7224 ]

The bulk of ATA host state machine is implemented by
ata_sff_hsm_move().  The function is called from either the interrupt
handler or, if polling, a work item.  Unlike from the interrupt path,
the polling path calls the function without holding the host lock and
ata_sff_hsm_move() selectively grabs the lock.

This is completely broken.  If an IRQ triggers while polling is in
progress, the two can easily race and end up accessing the hardware
and updating state machine state at the same time.  This can put the
state machine in an illegal state and lead to a crash like the
following.

  kernel BUG at drivers/ata/libata-sff.c:1302!
  invalid opcode: 0000 [#1] SMP DEBUG_PAGEALLOC KASAN
  Modules linked in:
  CPU: 1 PID: 10679 Comm: syz-executor Not tainted 4.5.0-rc1+ #300
  Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Bochs 01/01/2011
  task: ffff88002bd00000 ti: ffff88002e048000 task.ti: ffff88002e048000
  RIP: 0010:[&lt;ffffffff83a83409&gt;]  [&lt;ffffffff83a83409&gt;] ata_sff_hsm_move+0x619/0x1c60
  ...
  Call Trace:
   &lt;IRQ&gt;
   [&lt;ffffffff83a84c31&gt;] __ata_sff_port_intr+0x1e1/0x3a0 drivers/ata/libata-sff.c:1584
   [&lt;ffffffff83a85611&gt;] ata_bmdma_port_intr+0x71/0x400 drivers/ata/libata-sff.c:2877
   [&lt;     inline     &gt;] __ata_sff_interrupt drivers/ata/libata-sff.c:1629
   [&lt;ffffffff83a85bf3&gt;] ata_bmdma_interrupt+0x253/0x580 drivers/ata/libata-sff.c:2902
   [&lt;ffffffff81479f98&gt;] handle_irq_event_percpu+0x108/0x7e0 kernel/irq/handle.c:157
   [&lt;ffffffff8147a717&gt;] handle_irq_event+0xa7/0x140 kernel/irq/handle.c:205
   [&lt;ffffffff81484573&gt;] handle_edge_irq+0x1e3/0x8d0 kernel/irq/chip.c:623
   [&lt;     inline     &gt;] generic_handle_irq_desc include/linux/irqdesc.h:146
   [&lt;ffffffff811a92bc&gt;] handle_irq+0x10c/0x2a0 arch/x86/kernel/irq_64.c:78
   [&lt;ffffffff811a7e4d&gt;] do_IRQ+0x7d/0x1a0 arch/x86/kernel/irq.c:240
   [&lt;ffffffff86653d4c&gt;] common_interrupt+0x8c/0x8c arch/x86/entry/entry_64.S:520
   &lt;EOI&gt;
   [&lt;     inline     &gt;] rcu_lock_acquire include/linux/rcupdate.h:490
   [&lt;     inline     &gt;] rcu_read_lock include/linux/rcupdate.h:874
   [&lt;ffffffff8164b4a1&gt;] filemap_map_pages+0x131/0xba0 mm/filemap.c:2145
   [&lt;     inline     &gt;] do_fault_around mm/memory.c:2943
   [&lt;     inline     &gt;] do_read_fault mm/memory.c:2962
   [&lt;     inline     &gt;] do_fault mm/memory.c:3133
   [&lt;     inline     &gt;] handle_pte_fault mm/memory.c:3308
   [&lt;     inline     &gt;] __handle_mm_fault mm/memory.c:3418
   [&lt;ffffffff816efb16&gt;] handle_mm_fault+0x2516/0x49a0 mm/memory.c:3447
   [&lt;ffffffff8127dc16&gt;] __do_page_fault+0x376/0x960 arch/x86/mm/fault.c:1238
   [&lt;ffffffff8127e358&gt;] trace_do_page_fault+0xe8/0x420 arch/x86/mm/fault.c:1331
   [&lt;ffffffff8126f514&gt;] do_async_page_fault+0x14/0xd0 arch/x86/kernel/kvm.c:264
   [&lt;ffffffff86655578&gt;] async_page_fault+0x28/0x30 arch/x86/entry/entry_64.S:986

Fix it by ensuring that the polling path is holding the host lock
before entering ata_sff_hsm_move() so that all hardware accesses and
state updates are performed under the host lock.

Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
Reported-and-tested-by: Dmitry Vyukov &lt;dvyukov@google.com&gt;
Link: http://lkml.kernel.org/g/CACT4Y+b_JsOxJu2EZyEf+mOXORc_zid5V1-pLZSroJVxyWdSpw@mail.gmail.com
Cc: stable@vger.kernel.org
Signed-off-by: Sasha Levin &lt;sasha.levin@oracle.com&gt;
</content>
</entry>
<entry>
<title>libata: disable forced PORTS_IMPL for &gt;= AHCI 1.3</title>
<updated>2016-02-27T23:28:28Z</updated>
<author>
<name>Tejun Heo</name>
<email>tj@kernel.org</email>
</author>
<published>2016-01-15T20:13:05Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=f0d80acecb8d04f199893b8f111a7e8a06a61d56'/>
<id>urn:sha1:f0d80acecb8d04f199893b8f111a7e8a06a61d56</id>
<content type='text'>
[ Upstream commit 566d1827df2ef0cbe921d3d6946ac3007b1a6938 ]

Some early controllers incorrectly reported zero ports in PORTS_IMPL
register and the ahci driver fabricates PORTS_IMPL from the number of
ports in those cases.  This hasn't mattered but with the new nvme
controllers there are cases where zero PORTS_IMPL is valid and should
be honored.

Disable the workaround for &gt;= AHCI 1.3.

Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
Reported-by: Andy Lutomirski &lt;luto@amacapital.net&gt;
Link: http://lkml.kernel.org/g/CALCETrU7yMvXEDhjAUShoHEhDwifJGapdw--BKxsP0jmjKGmRw@mail.gmail.com
Cc: Sergei Shtylyov &lt;sergei.shtylyov@cogentembedded.com&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Sasha Levin &lt;sasha.levin@oracle.com&gt;
</content>
</entry>
<entry>
<title>Add factory recertified Crucial M500s to blacklist</title>
<updated>2015-09-22T19:20:20Z</updated>
<author>
<name>Guillermo A. Amaral</name>
<email>g@maral.me</email>
</author>
<published>2015-08-26T06:29:13Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=670805f14a8151fd4560a9c795fe2fc4c0376167'/>
<id>urn:sha1:670805f14a8151fd4560a9c795fe2fc4c0376167</id>
<content type='text'>
[ Upstream commit 7a7184b01aa9deb86df661c6f7cbcf69a95b728c ]

The Crucial M500 is known to have issues with queued TRIM commands, the
factory recertified SSDs use a different model number naming convention
which causes them to get ignored by the blacklist.

The new naming convention boils down to: s/Crucial_/FC/

Signed-off-by: Guillermo A. Amaral &lt;g@maral.me&gt;
Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Sasha Levin &lt;sasha.levin@oracle.com&gt;
</content>
</entry>
<entry>
<title>libata: Do not blacklist M510DC</title>
<updated>2015-08-27T17:26:12Z</updated>
<author>
<name>Martin K. Petersen</name>
<email>martin.petersen@oracle.com</email>
</author>
<published>2015-07-16T01:03:23Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=a0f0adf9e73f8f8157afc7d587943e70700f2a56'/>
<id>urn:sha1:a0f0adf9e73f8f8157afc7d587943e70700f2a56</id>
<content type='text'>
[ Upstream commit 9051bd393cf25e76dfb45409792719a854661500 ]

A new Micron drive was just announced, once again recycling the first
part of the model string. Add an underscore to the M510/M550 pattern to
avoid picking up the new DC drive.

Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
Cc: &lt;stable@vger.kernel.org&gt;
Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
Signed-off-by: Sasha Levin &lt;sasha.levin@oracle.com&gt;
</content>
</entry>
<entry>
<title>libata: force disable trim for SuperSSpeed S238</title>
<updated>2015-08-27T17:26:12Z</updated>
<author>
<name>Arne Fitzenreiter</name>
<email>arne_f@ipfire.org</email>
</author>
<published>2015-07-15T11:54:37Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=dfacf53c1a6ecfd3ae1d81ac173c00366cb4db79'/>
<id>urn:sha1:dfacf53c1a6ecfd3ae1d81ac173c00366cb4db79</id>
<content type='text'>
[ Upstream commit cda57b1b05cf7b8b99ab4b732bea0b05b6c015cc ]

This device loses blocks, often the partition table area, on trim.
Disable TRIM.
http://pcengines.ch/msata16a.htm

Signed-off-by: Arne Fitzenreiter &lt;arne_f@ipfire.org&gt;
Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Sasha Levin &lt;sasha.levin@oracle.com&gt;
</content>
</entry>
<entry>
<title>libata: add ATA_HORKAGE_NOTRIM</title>
<updated>2015-08-27T17:26:11Z</updated>
<author>
<name>Arne Fitzenreiter</name>
<email>arne_f@ipfire.org</email>
</author>
<published>2015-07-15T11:54:36Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=3fa84d66219c984590bd59959e283fba6d4bc9e0'/>
<id>urn:sha1:3fa84d66219c984590bd59959e283fba6d4bc9e0</id>
<content type='text'>
[ Upstream commit 71d126fd28de2d4d9b7b2088dbccd7ca62fad6e0 ]

Some devices lose data on TRIM whether queued or not.  This patch adds
a horkage to disable TRIM.

tj: Collapsed unnecessary if() nesting.

Signed-off-by: Arne Fitzenreiter &lt;arne_f@ipfire.org&gt;
Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Sasha Levin &lt;sasha.levin@oracle.com&gt;
</content>
</entry>
</feed>
