<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-stable.git/drivers/mtd/ubi, branch v4.13</title>
<subtitle>Linux kernel stable tree</subtitle>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/'/>
<entry>
<title>Merge tag 'driver-core-4.13-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core</title>
<updated>2017-07-04T03:27:48+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2017-07-04T03:27:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=974668417b74ec5f68df2411f53b3d3812565059'/>
<id>974668417b74ec5f68df2411f53b3d3812565059</id>
<content type='text'>
Pull driver core updates from Greg KH:
 "Here is the big driver core update for 4.13-rc1.

  The large majority of this is a lot of cleanup of old fields in the
  driver core structures and their remaining usages in random drivers.
  All of those fixes have been reviewed by the various subsystem
  maintainers. There's also some small firmware updates in here, a new
  kobject uevent api interface that makes userspace interaction easier,
  and a few other minor things.

  All of these have been in linux-next for a long while with no reported
  issues"

* tag 'driver-core-4.13-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: (56 commits)
  arm: mach-rpc: ecard: fix build error
  zram: convert remaining CLASS_ATTR() to CLASS_ATTR_RO()
  driver-core: remove struct bus_type.dev_attrs
  powerpc: vio_cmo: use dev_groups and not dev_attrs for bus_type
  powerpc: vio: use dev_groups and not dev_attrs for bus_type
  USB: usbip: convert to use DRIVER_ATTR_RW
  s390: drivers: convert to use DRIVER_ATTR_RO/WO
  platform: thinkpad_acpi: convert to use DRIVER_ATTR_RO/RW
  pcmcia: ds: convert to use DRIVER_ATTR_RO
  wireless: ipw2x00: convert to use DRIVER_ATTR_RW
  net: ehea: convert to use DRIVER_ATTR_RO
  net: caif: convert to use DRIVER_ATTR_RO
  TTY: hvc: convert to use DRIVER_ATTR_RW
  PCI: pci-driver: convert to use DRIVER_ATTR_WO
  IB: nes: convert to use DRIVER_ATTR_RW
  HID: hid-core: convert to use DRIVER_ATTR_RO and drv_groups
  arm: ecard: fix dev_groups patch typo
  tty: serdev: use dev_groups and not dev_attrs for bus_type
  sparc: vio: use dev_groups and not dev_attrs for bus_type
  hid: intel-ish-hid: use dev_groups and not dev_attrs for bus_type
  ...
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Pull driver core updates from Greg KH:
 "Here is the big driver core update for 4.13-rc1.

  The large majority of this is a lot of cleanup of old fields in the
  driver core structures and their remaining usages in random drivers.
  All of those fixes have been reviewed by the various subsystem
  maintainers. There's also some small firmware updates in here, a new
  kobject uevent api interface that makes userspace interaction easier,
  and a few other minor things.

  All of these have been in linux-next for a long while with no reported
  issues"

* tag 'driver-core-4.13-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: (56 commits)
  arm: mach-rpc: ecard: fix build error
  zram: convert remaining CLASS_ATTR() to CLASS_ATTR_RO()
  driver-core: remove struct bus_type.dev_attrs
  powerpc: vio_cmo: use dev_groups and not dev_attrs for bus_type
  powerpc: vio: use dev_groups and not dev_attrs for bus_type
  USB: usbip: convert to use DRIVER_ATTR_RW
  s390: drivers: convert to use DRIVER_ATTR_RO/WO
  platform: thinkpad_acpi: convert to use DRIVER_ATTR_RO/RW
  pcmcia: ds: convert to use DRIVER_ATTR_RO
  wireless: ipw2x00: convert to use DRIVER_ATTR_RW
  net: ehea: convert to use DRIVER_ATTR_RO
  net: caif: convert to use DRIVER_ATTR_RO
  TTY: hvc: convert to use DRIVER_ATTR_RW
  PCI: pci-driver: convert to use DRIVER_ATTR_WO
  IB: nes: convert to use DRIVER_ATTR_RW
  HID: hid-core: convert to use DRIVER_ATTR_RO and drv_groups
  arm: ecard: fix dev_groups patch typo
  tty: serdev: use dev_groups and not dev_attrs for bus_type
  sparc: vio: use dev_groups and not dev_attrs for bus_type
  hid: intel-ish-hid: use dev_groups and not dev_attrs for bus_type
  ...
</pre>
</div>
</content>
</entry>
<entry>
<title>blk-mq: switch -&gt;queue_rq return value to blk_status_t</title>
<updated>2017-06-09T15:27:32+00:00</updated>
<author>
<name>Christoph Hellwig</name>
<email>hch@lst.de</email>
</author>
<published>2017-06-03T07:38:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=fc17b6534eb8395f0b3133eb31d87deec32c642b'/>
<id>fc17b6534eb8395f0b3133eb31d87deec32c642b</id>
<content type='text'>
Use the same values for use for request completion errors as the return
value from -&gt;queue_rq.  BLK_STS_RESOURCE is special cased to cause
a requeue, and all the others are completed as-is.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Jens Axboe &lt;axboe@fb.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use the same values for use for request completion errors as the return
value from -&gt;queue_rq.  BLK_STS_RESOURCE is special cased to cause
a requeue, and all the others are completed as-is.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Jens Axboe &lt;axboe@fb.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>block: introduce new block status code type</title>
<updated>2017-06-09T15:27:32+00:00</updated>
<author>
<name>Christoph Hellwig</name>
<email>hch@lst.de</email>
</author>
<published>2017-06-03T07:38:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=2a842acab109f40f0d7d10b38e9ca88390628996'/>
<id>2a842acab109f40f0d7d10b38e9ca88390628996</id>
<content type='text'>
Currently we use nornal Linux errno values in the block layer, and while
we accept any error a few have overloaded magic meanings.  This patch
instead introduces a new  blk_status_t value that holds block layer specific
status codes and explicitly explains their meaning.  Helpers to convert from
and to the previous special meanings are provided for now, but I suspect
we want to get rid of them in the long run - those drivers that have a
errno input (e.g. networking) usually get errnos that don't know about
the special block layer overloads, and similarly returning them to userspace
will usually return somethings that strictly speaking isn't correct
for file system operations, but that's left as an exercise for later.

For now the set of errors is a very limited set that closely corresponds
to the previous overloaded errno values, but there is some low hanging
fruite to improve it.

blk_status_t (ab)uses the sparse __bitwise annotations to allow for sparse
typechecking, so that we can easily catch places passing the wrong values.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Jens Axboe &lt;axboe@fb.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Currently we use nornal Linux errno values in the block layer, and while
we accept any error a few have overloaded magic meanings.  This patch
instead introduces a new  blk_status_t value that holds block layer specific
status codes and explicitly explains their meaning.  Helpers to convert from
and to the previous special meanings are provided for now, but I suspect
we want to get rid of them in the long run - those drivers that have a
errno input (e.g. networking) usually get errnos that don't know about
the special block layer overloads, and similarly returning them to userspace
will usually return somethings that strictly speaking isn't correct
for file system operations, but that's left as an exercise for later.

For now the set of errors is a very limited set that closely corresponds
to the previous overloaded errno values, but there is some low hanging
fruite to improve it.

blk_status_t (ab)uses the sparse __bitwise annotations to allow for sparse
typechecking, so that we can easily catch places passing the wrong values.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Jens Axboe &lt;axboe@fb.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>mtd: use class_groups instead of class_attrs</title>
<updated>2017-06-09T08:41:00+00:00</updated>
<author>
<name>Greg Kroah-Hartman</name>
<email>gregkh@linuxfoundation.org</email>
</author>
<published>2017-06-08T08:12:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=219eccdabb3a877d285b35b59cfeb242381f9d50'/>
<id>219eccdabb3a877d285b35b59cfeb242381f9d50</id>
<content type='text'>
The class_attrs pointer is long depreciated, and is about to be finally
removed, so move to use the class_groups pointer instead.

Cc: Artem Bityutskiy &lt;dedekind1@gmail.com&gt;
Acked-by: Richard Weinberger &lt;richard@nod.at&gt;
Cc: David Woodhouse &lt;dwmw2@infradead.org&gt;
Cc: Brian Norris &lt;computersforpeace@gmail.com&gt;
Cc: Boris Brezillon &lt;boris.brezillon@free-electrons.com&gt;
Cc: Marek Vasut &lt;marek.vasut@gmail.com&gt;
Cc: Cyrille Pitchen &lt;cyrille.pitchen@wedev4u.fr&gt;
Cc: &lt;linux-mtd@lists.infradead.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The class_attrs pointer is long depreciated, and is about to be finally
removed, so move to use the class_groups pointer instead.

Cc: Artem Bityutskiy &lt;dedekind1@gmail.com&gt;
Acked-by: Richard Weinberger &lt;richard@nod.at&gt;
Cc: David Woodhouse &lt;dwmw2@infradead.org&gt;
Cc: Brian Norris &lt;computersforpeace@gmail.com&gt;
Cc: Boris Brezillon &lt;boris.brezillon@free-electrons.com&gt;
Cc: Marek Vasut &lt;marek.vasut@gmail.com&gt;
Cc: Cyrille Pitchen &lt;cyrille.pitchen@wedev4u.fr&gt;
Cc: &lt;linux-mtd@lists.infradead.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge tag 'upstream-4.12-rc1' of git://git.infradead.org/linux-ubifs</title>
<updated>2017-05-13T17:23:12+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2017-05-13T17:23:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=b53c4d5eb7cda86f7bf495f52116ae43bdc9cf23'/>
<id>b53c4d5eb7cda86f7bf495f52116ae43bdc9cf23</id>
<content type='text'>
Pull UBI/UBIFS updates from Richard Weinberger:

 - new config option CONFIG_UBIFS_FS_SECURITY

 - minor improvements

 - random fixes

* tag 'upstream-4.12-rc1' of git://git.infradead.org/linux-ubifs:
  ubi: Add debugfs file for tracking PEB state
  ubifs: Fix a typo in comment of ioctl2ubifs &amp; ubifs2ioctl
  ubifs: Remove unnecessary assignment
  ubifs: Fix cut and paste error on sb type comparisons
  ubi: fastmap: Fix slab corruption
  ubifs: Add CONFIG_UBIFS_FS_SECURITY to disable/enable security labels
  ubi: Make mtd parameter readable
  ubi: Fix section mismatch
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Pull UBI/UBIFS updates from Richard Weinberger:

 - new config option CONFIG_UBIFS_FS_SECURITY

 - minor improvements

 - random fixes

* tag 'upstream-4.12-rc1' of git://git.infradead.org/linux-ubifs:
  ubi: Add debugfs file for tracking PEB state
  ubifs: Fix a typo in comment of ioctl2ubifs &amp; ubifs2ioctl
  ubifs: Remove unnecessary assignment
  ubifs: Fix cut and paste error on sb type comparisons
  ubi: fastmap: Fix slab corruption
  ubifs: Add CONFIG_UBIFS_FS_SECURITY to disable/enable security labels
  ubi: Make mtd parameter readable
  ubi: Fix section mismatch
</pre>
</div>
</content>
</entry>
<entry>
<title>ubi: Add debugfs file for tracking PEB state</title>
<updated>2017-05-08T18:49:02+00:00</updated>
<author>
<name>Ben Shelton</name>
<email>ben.shelton@ni.com</email>
</author>
<published>2017-03-27T18:24:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=7bccd12d27b7e358823feb5429731b8ee698b173'/>
<id>7bccd12d27b7e358823feb5429731b8ee698b173</id>
<content type='text'>
Add a file under debugfs to allow easy access to the erase count for
each physical erase block on an UBI device.  This is useful when
debugging data integrity issues with UBIFS on NAND flash devices.

Signed-off-by: Ben Shelton &lt;ben.shelton@ni.com&gt;
Signed-off-by: Zach Brown &lt;zach.brown@ni.com&gt;

v2:
* If ubi_io_is_bad eraseblk_count_seq_show just returns the err.
* if ubi-&gt;lookuptbl returns null, its no longer treated as an error
  instead info for that block is not printeded
* Removed check for UBI_MAX_ERASECOUNTER since it is impossible to hit
* Removed block state from print, if a block is printed then it is good and
  if it is not printed, then it is bad.

v3:
* Remove errant ! symbol from if statement checking if erase count is valid.
Signed-off-by: Richard Weinberger &lt;richard@nod.at&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add a file under debugfs to allow easy access to the erase count for
each physical erase block on an UBI device.  This is useful when
debugging data integrity issues with UBIFS on NAND flash devices.

Signed-off-by: Ben Shelton &lt;ben.shelton@ni.com&gt;
Signed-off-by: Zach Brown &lt;zach.brown@ni.com&gt;

v2:
* If ubi_io_is_bad eraseblk_count_seq_show just returns the err.
* if ubi-&gt;lookuptbl returns null, its no longer treated as an error
  instead info for that block is not printeded
* Removed check for UBI_MAX_ERASECOUNTER since it is impossible to hit
* Removed block state from print, if a block is printed then it is good and
  if it is not printed, then it is bad.

v3:
* Remove errant ! symbol from if statement checking if erase count is valid.
Signed-off-by: Richard Weinberger &lt;richard@nod.at&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ubi: fastmap: Fix slab corruption</title>
<updated>2017-05-08T18:48:33+00:00</updated>
<author>
<name>Rabin Vincent</name>
<email>rabinv@axis.com</email>
</author>
<published>2017-04-03T11:44:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=8a1435880f452430b41374d27ac4a33e7bd381ea'/>
<id>8a1435880f452430b41374d27ac4a33e7bd381ea</id>
<content type='text'>
Booting with UBI fastmap and SLUB debugging enabled results in the
following splats.  The problem is that ubi_scan_fastmap() moves the
fastmap blocks from the scan_ai (allocated in scan_fast()) to the ai
allocated in ubi_attach().  This results in two problems:

 - When the scan_ai is freed, aebs which were allocated from its slab
   cache are still in use.

 - When the other ai is being destroyed in destroy_ai(), the
   arguments to kmem_cache_free() call are incorrect since aebs on its
   -&gt;fastmap list were allocated with a slab cache from a differnt ai.

Fix this by making a copy of the aebs in ubi_scan_fastmap() instead of
moving them.

 =============================================================================
 BUG ubi_aeb_slab_cache (Not tainted): Objects remaining in ubi_aeb_slab_cache on __kmem_cache_shutdown()
 -----------------------------------------------------------------------------

 INFO: Slab 0xbfd2da3c objects=17 used=1 fp=0xb33d7748 flags=0x40000080
 CPU: 1 PID: 118 Comm: ubiattach Tainted: G    B           4.9.15 #3
 [&lt;80111910&gt;] (unwind_backtrace) from [&lt;8010d498&gt;] (show_stack+0x18/0x1c)
 [&lt;8010d498&gt;] (show_stack) from [&lt;804a3274&gt;] (dump_stack+0xb4/0xe0)
 [&lt;804a3274&gt;] (dump_stack) from [&lt;8026c47c&gt;] (slab_err+0x78/0x88)
 [&lt;8026c47c&gt;] (slab_err) from [&lt;802735bc&gt;] (__kmem_cache_shutdown+0x180/0x3e0)
 [&lt;802735bc&gt;] (__kmem_cache_shutdown) from [&lt;8024e13c&gt;] (shutdown_cache+0x1c/0x60)
 [&lt;8024e13c&gt;] (shutdown_cache) from [&lt;8024ed64&gt;] (kmem_cache_destroy+0x19c/0x20c)
 [&lt;8024ed64&gt;] (kmem_cache_destroy) from [&lt;8057cc14&gt;] (destroy_ai+0x1dc/0x1e8)
 [&lt;8057cc14&gt;] (destroy_ai) from [&lt;8057f04c&gt;] (ubi_attach+0x3f4/0x450)
 [&lt;8057f04c&gt;] (ubi_attach) from [&lt;8056fe70&gt;] (ubi_attach_mtd_dev+0x60c/0xff8)
 [&lt;8056fe70&gt;] (ubi_attach_mtd_dev) from [&lt;80571d78&gt;] (ctrl_cdev_ioctl+0x110/0x2b8)
 [&lt;80571d78&gt;] (ctrl_cdev_ioctl) from [&lt;8029c77c&gt;] (do_vfs_ioctl+0xac/0xa00)
 [&lt;8029c77c&gt;] (do_vfs_ioctl) from [&lt;8029d10c&gt;] (SyS_ioctl+0x3c/0x64)
 [&lt;8029d10c&gt;] (SyS_ioctl) from [&lt;80108860&gt;] (ret_fast_syscall+0x0/0x1c)
 INFO: Object 0xb33d7e88 @offset=3720
 INFO: Allocated in scan_peb+0x608/0x81c age=72 cpu=1 pid=118
 	kmem_cache_alloc+0x3b0/0x43c
 	scan_peb+0x608/0x81c
 	ubi_attach+0x124/0x450
 	ubi_attach_mtd_dev+0x60c/0xff8
 	ctrl_cdev_ioctl+0x110/0x2b8
 	do_vfs_ioctl+0xac/0xa00
 	SyS_ioctl+0x3c/0x64
 	ret_fast_syscall+0x0/0x1c
 kmem_cache_destroy ubi_aeb_slab_cache: Slab cache still has objects
 CPU: 1 PID: 118 Comm: ubiattach Tainted: G    B           4.9.15 #3
 [&lt;80111910&gt;] (unwind_backtrace) from [&lt;8010d498&gt;] (show_stack+0x18/0x1c)
 [&lt;8010d498&gt;] (show_stack) from [&lt;804a3274&gt;] (dump_stack+0xb4/0xe0)
 [&lt;804a3274&gt;] (dump_stack) from [&lt;8024ed80&gt;] (kmem_cache_destroy+0x1b8/0x20c)
 [&lt;8024ed80&gt;] (kmem_cache_destroy) from [&lt;8057cc14&gt;] (destroy_ai+0x1dc/0x1e8)
 [&lt;8057cc14&gt;] (destroy_ai) from [&lt;8057f04c&gt;] (ubi_attach+0x3f4/0x450)
 [&lt;8057f04c&gt;] (ubi_attach) from [&lt;8056fe70&gt;] (ubi_attach_mtd_dev+0x60c/0xff8)
 [&lt;8056fe70&gt;] (ubi_attach_mtd_dev) from [&lt;80571d78&gt;] (ctrl_cdev_ioctl+0x110/0x2b8)
 [&lt;80571d78&gt;] (ctrl_cdev_ioctl) from [&lt;8029c77c&gt;] (do_vfs_ioctl+0xac/0xa00)
 [&lt;8029c77c&gt;] (do_vfs_ioctl) from [&lt;8029d10c&gt;] (SyS_ioctl+0x3c/0x64)
 [&lt;8029d10c&gt;] (SyS_ioctl) from [&lt;80108860&gt;] (ret_fast_syscall+0x0/0x1c)
 cache_from_obj: Wrong slab cache. ubi_aeb_slab_cache but object is from ubi_aeb_slab_cache
 ------------[ cut here ]------------
 WARNING: CPU: 1 PID: 118 at mm/slab.h:354 kmem_cache_free+0x39c/0x450
 Modules linked in:
 CPU: 1 PID: 118 Comm: ubiattach Tainted: G    B           4.9.15 #3
 [&lt;80111910&gt;] (unwind_backtrace) from [&lt;8010d498&gt;] (show_stack+0x18/0x1c)
 [&lt;8010d498&gt;] (show_stack) from [&lt;804a3274&gt;] (dump_stack+0xb4/0xe0)
 [&lt;804a3274&gt;] (dump_stack) from [&lt;80120e40&gt;] (__warn+0xf4/0x10c)
 [&lt;80120e40&gt;] (__warn) from [&lt;80120f20&gt;] (warn_slowpath_null+0x28/0x30)
 [&lt;80120f20&gt;] (warn_slowpath_null) from [&lt;80271fe0&gt;] (kmem_cache_free+0x39c/0x450)
 [&lt;80271fe0&gt;] (kmem_cache_free) from [&lt;8057cb88&gt;] (destroy_ai+0x150/0x1e8)
 [&lt;8057cb88&gt;] (destroy_ai) from [&lt;8057ef1c&gt;] (ubi_attach+0x2c4/0x450)
 [&lt;8057ef1c&gt;] (ubi_attach) from [&lt;8056fe70&gt;] (ubi_attach_mtd_dev+0x60c/0xff8)
 [&lt;8056fe70&gt;] (ubi_attach_mtd_dev) from [&lt;80571d78&gt;] (ctrl_cdev_ioctl+0x110/0x2b8)
 [&lt;80571d78&gt;] (ctrl_cdev_ioctl) from [&lt;8029c77c&gt;] (do_vfs_ioctl+0xac/0xa00)
 [&lt;8029c77c&gt;] (do_vfs_ioctl) from [&lt;8029d10c&gt;] (SyS_ioctl+0x3c/0x64)
 [&lt;8029d10c&gt;] (SyS_ioctl) from [&lt;80108860&gt;] (ret_fast_syscall+0x0/0x1c)
 ---[ end trace 2bd8396277fd0a0b ]---
 =============================================================================
 BUG ubi_aeb_slab_cache (Tainted: G    B   W      ): page slab pointer corrupt.
 -----------------------------------------------------------------------------

 INFO: Allocated in scan_peb+0x608/0x81c age=104 cpu=1 pid=118
 	kmem_cache_alloc+0x3b0/0x43c
 	scan_peb+0x608/0x81c
 	ubi_attach+0x124/0x450
 	ubi_attach_mtd_dev+0x60c/0xff8
 	ctrl_cdev_ioctl+0x110/0x2b8
 	do_vfs_ioctl+0xac/0xa00
 	SyS_ioctl+0x3c/0x64
 	ret_fast_syscall+0x0/0x1c
 INFO: Slab 0xbfd2da3c objects=17 used=1 fp=0xb33d7748 flags=0x40000081
 INFO: Object 0xb33d7e88 @offset=3720 fp=0xb33d7da0

 Redzone b33d7e80: cc cc cc cc cc cc cc cc                          ........
 Object b33d7e88: 02 00 00 00 01 00 00 00 00 f0 ff 7f ff ff ff ff  ................
 Object b33d7e98: 00 00 00 00 00 00 00 00 bd 16 00 00 00 00 00 00  ................
 Object b33d7ea8: 00 01 00 00 00 02 00 00 00 00 00 00 00 00 00 00  ................
 Redzone b33d7eb8: cc cc cc cc                                      ....
 Padding b33d7f60: 5a 5a 5a 5a 5a 5a 5a 5a                          ZZZZZZZZ
 CPU: 1 PID: 118 Comm: ubiattach Tainted: G    B   W       4.9.15 #3
 [&lt;80111910&gt;] (unwind_backtrace) from [&lt;8010d498&gt;] (show_stack+0x18/0x1c)
 [&lt;8010d498&gt;] (show_stack) from [&lt;804a3274&gt;] (dump_stack+0xb4/0xe0)
 [&lt;804a3274&gt;] (dump_stack) from [&lt;80271770&gt;] (free_debug_processing+0x320/0x3c4)
 [&lt;80271770&gt;] (free_debug_processing) from [&lt;80271ad0&gt;] (__slab_free+0x2bc/0x430)
 [&lt;80271ad0&gt;] (__slab_free) from [&lt;80272024&gt;] (kmem_cache_free+0x3e0/0x450)
 [&lt;80272024&gt;] (kmem_cache_free) from [&lt;8057cb88&gt;] (destroy_ai+0x150/0x1e8)
 [&lt;8057cb88&gt;] (destroy_ai) from [&lt;8057ef1c&gt;] (ubi_attach+0x2c4/0x450)
 [&lt;8057ef1c&gt;] (ubi_attach) from [&lt;8056fe70&gt;] (ubi_attach_mtd_dev+0x60c/0xff8)
 [&lt;8056fe70&gt;] (ubi_attach_mtd_dev) from [&lt;80571d78&gt;] (ctrl_cdev_ioctl+0x110/0x2b8)
 [&lt;80571d78&gt;] (ctrl_cdev_ioctl) from [&lt;8029c77c&gt;] (do_vfs_ioctl+0xac/0xa00)
 [&lt;8029c77c&gt;] (do_vfs_ioctl) from [&lt;8029d10c&gt;] (SyS_ioctl+0x3c/0x64)
 [&lt;8029d10c&gt;] (SyS_ioctl) from [&lt;80108860&gt;] (ret_fast_syscall+0x0/0x1c)
 FIX ubi_aeb_slab_cache: Object at 0xb33d7e88 not freed

Signed-off-by: Rabin Vincent &lt;rabinv@axis.com&gt;
Signed-off-by: Richard Weinberger &lt;richard@nod.at&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Booting with UBI fastmap and SLUB debugging enabled results in the
following splats.  The problem is that ubi_scan_fastmap() moves the
fastmap blocks from the scan_ai (allocated in scan_fast()) to the ai
allocated in ubi_attach().  This results in two problems:

 - When the scan_ai is freed, aebs which were allocated from its slab
   cache are still in use.

 - When the other ai is being destroyed in destroy_ai(), the
   arguments to kmem_cache_free() call are incorrect since aebs on its
   -&gt;fastmap list were allocated with a slab cache from a differnt ai.

Fix this by making a copy of the aebs in ubi_scan_fastmap() instead of
moving them.

 =============================================================================
 BUG ubi_aeb_slab_cache (Not tainted): Objects remaining in ubi_aeb_slab_cache on __kmem_cache_shutdown()
 -----------------------------------------------------------------------------

 INFO: Slab 0xbfd2da3c objects=17 used=1 fp=0xb33d7748 flags=0x40000080
 CPU: 1 PID: 118 Comm: ubiattach Tainted: G    B           4.9.15 #3
 [&lt;80111910&gt;] (unwind_backtrace) from [&lt;8010d498&gt;] (show_stack+0x18/0x1c)
 [&lt;8010d498&gt;] (show_stack) from [&lt;804a3274&gt;] (dump_stack+0xb4/0xe0)
 [&lt;804a3274&gt;] (dump_stack) from [&lt;8026c47c&gt;] (slab_err+0x78/0x88)
 [&lt;8026c47c&gt;] (slab_err) from [&lt;802735bc&gt;] (__kmem_cache_shutdown+0x180/0x3e0)
 [&lt;802735bc&gt;] (__kmem_cache_shutdown) from [&lt;8024e13c&gt;] (shutdown_cache+0x1c/0x60)
 [&lt;8024e13c&gt;] (shutdown_cache) from [&lt;8024ed64&gt;] (kmem_cache_destroy+0x19c/0x20c)
 [&lt;8024ed64&gt;] (kmem_cache_destroy) from [&lt;8057cc14&gt;] (destroy_ai+0x1dc/0x1e8)
 [&lt;8057cc14&gt;] (destroy_ai) from [&lt;8057f04c&gt;] (ubi_attach+0x3f4/0x450)
 [&lt;8057f04c&gt;] (ubi_attach) from [&lt;8056fe70&gt;] (ubi_attach_mtd_dev+0x60c/0xff8)
 [&lt;8056fe70&gt;] (ubi_attach_mtd_dev) from [&lt;80571d78&gt;] (ctrl_cdev_ioctl+0x110/0x2b8)
 [&lt;80571d78&gt;] (ctrl_cdev_ioctl) from [&lt;8029c77c&gt;] (do_vfs_ioctl+0xac/0xa00)
 [&lt;8029c77c&gt;] (do_vfs_ioctl) from [&lt;8029d10c&gt;] (SyS_ioctl+0x3c/0x64)
 [&lt;8029d10c&gt;] (SyS_ioctl) from [&lt;80108860&gt;] (ret_fast_syscall+0x0/0x1c)
 INFO: Object 0xb33d7e88 @offset=3720
 INFO: Allocated in scan_peb+0x608/0x81c age=72 cpu=1 pid=118
 	kmem_cache_alloc+0x3b0/0x43c
 	scan_peb+0x608/0x81c
 	ubi_attach+0x124/0x450
 	ubi_attach_mtd_dev+0x60c/0xff8
 	ctrl_cdev_ioctl+0x110/0x2b8
 	do_vfs_ioctl+0xac/0xa00
 	SyS_ioctl+0x3c/0x64
 	ret_fast_syscall+0x0/0x1c
 kmem_cache_destroy ubi_aeb_slab_cache: Slab cache still has objects
 CPU: 1 PID: 118 Comm: ubiattach Tainted: G    B           4.9.15 #3
 [&lt;80111910&gt;] (unwind_backtrace) from [&lt;8010d498&gt;] (show_stack+0x18/0x1c)
 [&lt;8010d498&gt;] (show_stack) from [&lt;804a3274&gt;] (dump_stack+0xb4/0xe0)
 [&lt;804a3274&gt;] (dump_stack) from [&lt;8024ed80&gt;] (kmem_cache_destroy+0x1b8/0x20c)
 [&lt;8024ed80&gt;] (kmem_cache_destroy) from [&lt;8057cc14&gt;] (destroy_ai+0x1dc/0x1e8)
 [&lt;8057cc14&gt;] (destroy_ai) from [&lt;8057f04c&gt;] (ubi_attach+0x3f4/0x450)
 [&lt;8057f04c&gt;] (ubi_attach) from [&lt;8056fe70&gt;] (ubi_attach_mtd_dev+0x60c/0xff8)
 [&lt;8056fe70&gt;] (ubi_attach_mtd_dev) from [&lt;80571d78&gt;] (ctrl_cdev_ioctl+0x110/0x2b8)
 [&lt;80571d78&gt;] (ctrl_cdev_ioctl) from [&lt;8029c77c&gt;] (do_vfs_ioctl+0xac/0xa00)
 [&lt;8029c77c&gt;] (do_vfs_ioctl) from [&lt;8029d10c&gt;] (SyS_ioctl+0x3c/0x64)
 [&lt;8029d10c&gt;] (SyS_ioctl) from [&lt;80108860&gt;] (ret_fast_syscall+0x0/0x1c)
 cache_from_obj: Wrong slab cache. ubi_aeb_slab_cache but object is from ubi_aeb_slab_cache
 ------------[ cut here ]------------
 WARNING: CPU: 1 PID: 118 at mm/slab.h:354 kmem_cache_free+0x39c/0x450
 Modules linked in:
 CPU: 1 PID: 118 Comm: ubiattach Tainted: G    B           4.9.15 #3
 [&lt;80111910&gt;] (unwind_backtrace) from [&lt;8010d498&gt;] (show_stack+0x18/0x1c)
 [&lt;8010d498&gt;] (show_stack) from [&lt;804a3274&gt;] (dump_stack+0xb4/0xe0)
 [&lt;804a3274&gt;] (dump_stack) from [&lt;80120e40&gt;] (__warn+0xf4/0x10c)
 [&lt;80120e40&gt;] (__warn) from [&lt;80120f20&gt;] (warn_slowpath_null+0x28/0x30)
 [&lt;80120f20&gt;] (warn_slowpath_null) from [&lt;80271fe0&gt;] (kmem_cache_free+0x39c/0x450)
 [&lt;80271fe0&gt;] (kmem_cache_free) from [&lt;8057cb88&gt;] (destroy_ai+0x150/0x1e8)
 [&lt;8057cb88&gt;] (destroy_ai) from [&lt;8057ef1c&gt;] (ubi_attach+0x2c4/0x450)
 [&lt;8057ef1c&gt;] (ubi_attach) from [&lt;8056fe70&gt;] (ubi_attach_mtd_dev+0x60c/0xff8)
 [&lt;8056fe70&gt;] (ubi_attach_mtd_dev) from [&lt;80571d78&gt;] (ctrl_cdev_ioctl+0x110/0x2b8)
 [&lt;80571d78&gt;] (ctrl_cdev_ioctl) from [&lt;8029c77c&gt;] (do_vfs_ioctl+0xac/0xa00)
 [&lt;8029c77c&gt;] (do_vfs_ioctl) from [&lt;8029d10c&gt;] (SyS_ioctl+0x3c/0x64)
 [&lt;8029d10c&gt;] (SyS_ioctl) from [&lt;80108860&gt;] (ret_fast_syscall+0x0/0x1c)
 ---[ end trace 2bd8396277fd0a0b ]---
 =============================================================================
 BUG ubi_aeb_slab_cache (Tainted: G    B   W      ): page slab pointer corrupt.
 -----------------------------------------------------------------------------

 INFO: Allocated in scan_peb+0x608/0x81c age=104 cpu=1 pid=118
 	kmem_cache_alloc+0x3b0/0x43c
 	scan_peb+0x608/0x81c
 	ubi_attach+0x124/0x450
 	ubi_attach_mtd_dev+0x60c/0xff8
 	ctrl_cdev_ioctl+0x110/0x2b8
 	do_vfs_ioctl+0xac/0xa00
 	SyS_ioctl+0x3c/0x64
 	ret_fast_syscall+0x0/0x1c
 INFO: Slab 0xbfd2da3c objects=17 used=1 fp=0xb33d7748 flags=0x40000081
 INFO: Object 0xb33d7e88 @offset=3720 fp=0xb33d7da0

 Redzone b33d7e80: cc cc cc cc cc cc cc cc                          ........
 Object b33d7e88: 02 00 00 00 01 00 00 00 00 f0 ff 7f ff ff ff ff  ................
 Object b33d7e98: 00 00 00 00 00 00 00 00 bd 16 00 00 00 00 00 00  ................
 Object b33d7ea8: 00 01 00 00 00 02 00 00 00 00 00 00 00 00 00 00  ................
 Redzone b33d7eb8: cc cc cc cc                                      ....
 Padding b33d7f60: 5a 5a 5a 5a 5a 5a 5a 5a                          ZZZZZZZZ
 CPU: 1 PID: 118 Comm: ubiattach Tainted: G    B   W       4.9.15 #3
 [&lt;80111910&gt;] (unwind_backtrace) from [&lt;8010d498&gt;] (show_stack+0x18/0x1c)
 [&lt;8010d498&gt;] (show_stack) from [&lt;804a3274&gt;] (dump_stack+0xb4/0xe0)
 [&lt;804a3274&gt;] (dump_stack) from [&lt;80271770&gt;] (free_debug_processing+0x320/0x3c4)
 [&lt;80271770&gt;] (free_debug_processing) from [&lt;80271ad0&gt;] (__slab_free+0x2bc/0x430)
 [&lt;80271ad0&gt;] (__slab_free) from [&lt;80272024&gt;] (kmem_cache_free+0x3e0/0x450)
 [&lt;80272024&gt;] (kmem_cache_free) from [&lt;8057cb88&gt;] (destroy_ai+0x150/0x1e8)
 [&lt;8057cb88&gt;] (destroy_ai) from [&lt;8057ef1c&gt;] (ubi_attach+0x2c4/0x450)
 [&lt;8057ef1c&gt;] (ubi_attach) from [&lt;8056fe70&gt;] (ubi_attach_mtd_dev+0x60c/0xff8)
 [&lt;8056fe70&gt;] (ubi_attach_mtd_dev) from [&lt;80571d78&gt;] (ctrl_cdev_ioctl+0x110/0x2b8)
 [&lt;80571d78&gt;] (ctrl_cdev_ioctl) from [&lt;8029c77c&gt;] (do_vfs_ioctl+0xac/0xa00)
 [&lt;8029c77c&gt;] (do_vfs_ioctl) from [&lt;8029d10c&gt;] (SyS_ioctl+0x3c/0x64)
 [&lt;8029d10c&gt;] (SyS_ioctl) from [&lt;80108860&gt;] (ret_fast_syscall+0x0/0x1c)
 FIX ubi_aeb_slab_cache: Object at 0xb33d7e88 not freed

Signed-off-by: Rabin Vincent &lt;rabinv@axis.com&gt;
Signed-off-by: Richard Weinberger &lt;richard@nod.at&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ubi: Make mtd parameter readable</title>
<updated>2017-05-08T18:48:17+00:00</updated>
<author>
<name>Andy Shevchenko</name>
<email>andriy.shevchenko@linux.intel.com</email>
</author>
<published>2017-01-10T12:56:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=997d30cb7490eb1ac37a3fb02a222fabf1f25fa9'/>
<id>997d30cb7490eb1ac37a3fb02a222fabf1f25fa9</id>
<content type='text'>
Fix permissions to allow read mtd parameter back (only for owner).

Signed-off-by: Andy Shevchenko &lt;andriy.shevchenko@linux.intel.com&gt;
Signed-off-by: Richard Weinberger &lt;richard@nod.at&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix permissions to allow read mtd parameter back (only for owner).

Signed-off-by: Andy Shevchenko &lt;andriy.shevchenko@linux.intel.com&gt;
Signed-off-by: Richard Weinberger &lt;richard@nod.at&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ubi: Fix section mismatch</title>
<updated>2017-05-08T18:47:59+00:00</updated>
<author>
<name>Andy Shevchenko</name>
<email>andriy.shevchenko@linux.intel.com</email>
</author>
<published>2017-01-10T12:56:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=435009d4064af72b283fdd47025cede4dfefc6d2'/>
<id>435009d4064af72b283fdd47025cede4dfefc6d2</id>
<content type='text'>
WARNING: vmlinux.o(.text+0x1f2a80): Section mismatch in reference from the variable __param_ops_mtd to the function .init.text:ubi_mtd_param_parse()
The function __param_ops_mtd() references
the function __init ubi_mtd_param_parse().
This is often because __param_ops_mtd lacks a __init
annotation or the annotation of ubi_mtd_param_parse is wrong.

Cc: Richard Weinberger &lt;richard@nod.at&gt;
Signed-off-by: Andy Shevchenko &lt;andriy.shevchenko@linux.intel.com&gt;
Signed-off-by: Richard Weinberger &lt;richard@nod.at&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
WARNING: vmlinux.o(.text+0x1f2a80): Section mismatch in reference from the variable __param_ops_mtd to the function .init.text:ubi_mtd_param_parse()
The function __param_ops_mtd() references
the function __init ubi_mtd_param_parse().
This is often because __param_ops_mtd lacks a __init
annotation or the annotation of ubi_mtd_param_parse is wrong.

Cc: Richard Weinberger &lt;richard@nod.at&gt;
Signed-off-by: Andy Shevchenko &lt;andriy.shevchenko@linux.intel.com&gt;
Signed-off-by: Richard Weinberger &lt;richard@nod.at&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge branch 'for-linus' of git://git.kernel.dk/linux-block</title>
<updated>2017-05-06T18:25:08+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2017-05-06T18:25:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=044f1daaaaf7c86bc4fcf433848b7baae236946b'/>
<id>044f1daaaaf7c86bc4fcf433848b7baae236946b</id>
<content type='text'>
Pull block fixes and updates from Jens Axboe:
 "Some fixes and followup features/changes that should go in, in this
  merge window. This contains:

   - Two fixes for lightnvm from Javier, fixing problems in the new code
     merge previously in this merge window.

   - A fix from Jan for the backing device changes, fixing an issue in
     NFS that causes a failure to mount on certain setups.

   - A change from Christoph, cleaning up the blk-mq init and exit
     request paths.

   - Remove elevator_change(), which is now unused. From Bart.

   - A fix for queue operation invocation on a dead queue, from Bart.

   - A series fixing up mtip32xx for blk-mq scheduling, removing a
     bandaid we previously had in place for this. From me.

   - A regression fix for this series, fixing a case where we wait on
     workqueue flushing from an invalid (non-blocking) context. From me.

   - A fix/optimization from Ming, ensuring that we don't both quiesce
     and freeze a queue at the same time.

   - A fix from Peter on lock ordering for CPU hotplug. Not a real
     problem right now, but will be once the CPU hotplug rework goes in.

   - A series from Omar, cleaning up out blk-mq debugfs support, and
     adding support for exporting info from schedulers in debugfs as
     well. This is really useful in debugging stalls or livelocks. From
     Omar"

* 'for-linus' of git://git.kernel.dk/linux-block: (28 commits)
  mq-deadline: add debugfs attributes
  kyber: add debugfs attributes
  blk-mq-debugfs: allow schedulers to register debugfs attributes
  blk-mq: untangle debugfs and sysfs
  blk-mq: move debugfs declarations to a separate header file
  blk-mq: Do not invoke queue operations on a dead queue
  blk-mq-debugfs: get rid of a bunch of boilerplate
  blk-mq-debugfs: rename hw queue directories from &lt;n&gt; to hctx&lt;n&gt;
  blk-mq-debugfs: don't open code strstrip()
  blk-mq-debugfs: error on long write to queue "state" file
  blk-mq-debugfs: clean up flag definitions
  blk-mq-debugfs: separate flags with |
  nfs: Fix bdi handling for cloned superblocks
  block/mq: Cure cpu hotplug lock inversion
  lightnvm: fix bad back free on error path
  lightnvm: create cmd before allocating request
  blk-mq: don't use sync workqueue flushing from drivers
  mtip32xx: convert internal commands to regular block infrastructure
  mtip32xx: cleanup internal tag assumptions
  block: don't call blk_mq_quiesce_queue() after queue is frozen
  ...
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Pull block fixes and updates from Jens Axboe:
 "Some fixes and followup features/changes that should go in, in this
  merge window. This contains:

   - Two fixes for lightnvm from Javier, fixing problems in the new code
     merge previously in this merge window.

   - A fix from Jan for the backing device changes, fixing an issue in
     NFS that causes a failure to mount on certain setups.

   - A change from Christoph, cleaning up the blk-mq init and exit
     request paths.

   - Remove elevator_change(), which is now unused. From Bart.

   - A fix for queue operation invocation on a dead queue, from Bart.

   - A series fixing up mtip32xx for blk-mq scheduling, removing a
     bandaid we previously had in place for this. From me.

   - A regression fix for this series, fixing a case where we wait on
     workqueue flushing from an invalid (non-blocking) context. From me.

   - A fix/optimization from Ming, ensuring that we don't both quiesce
     and freeze a queue at the same time.

   - A fix from Peter on lock ordering for CPU hotplug. Not a real
     problem right now, but will be once the CPU hotplug rework goes in.

   - A series from Omar, cleaning up out blk-mq debugfs support, and
     adding support for exporting info from schedulers in debugfs as
     well. This is really useful in debugging stalls or livelocks. From
     Omar"

* 'for-linus' of git://git.kernel.dk/linux-block: (28 commits)
  mq-deadline: add debugfs attributes
  kyber: add debugfs attributes
  blk-mq-debugfs: allow schedulers to register debugfs attributes
  blk-mq: untangle debugfs and sysfs
  blk-mq: move debugfs declarations to a separate header file
  blk-mq: Do not invoke queue operations on a dead queue
  blk-mq-debugfs: get rid of a bunch of boilerplate
  blk-mq-debugfs: rename hw queue directories from &lt;n&gt; to hctx&lt;n&gt;
  blk-mq-debugfs: don't open code strstrip()
  blk-mq-debugfs: error on long write to queue "state" file
  blk-mq-debugfs: clean up flag definitions
  blk-mq-debugfs: separate flags with |
  nfs: Fix bdi handling for cloned superblocks
  block/mq: Cure cpu hotplug lock inversion
  lightnvm: fix bad back free on error path
  lightnvm: create cmd before allocating request
  blk-mq: don't use sync workqueue flushing from drivers
  mtip32xx: convert internal commands to regular block infrastructure
  mtip32xx: cleanup internal tag assumptions
  block: don't call blk_mq_quiesce_queue() after queue is frozen
  ...
</pre>
</div>
</content>
</entry>
</feed>
