--- /dev/null
+From 0e16e4cfde70e1cf00f9fe3a8f601d10e73e0ec6 Mon Sep 17 00:00:00 2001
+From: Alex Deucher <alexander.deucher@amd.com>
+Date: Fri, 1 Aug 2014 20:05:29 +0200
+Subject: drm/radeon: use packet2 for nop on hawaii with old firmware
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+From: Alex Deucher <alexander.deucher@amd.com>
+
+commit 0e16e4cfde70e1cf00f9fe3a8f601d10e73e0ec6 upstream.
+
+Older firmware didn't support the new nop packet.
+
+v2 (Andreas Boll):
+ - Drop usage of packet3 for new firmware
+
+Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
+Reviewed-by: Christian König <christian.koenig@amd.com> (v1)
+Signed-off-by: Andreas Boll <andreas.boll.dev@gmail.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/gpu/drm/radeon/cik.c | 13 ++++++++++---
+ 1 file changed, 10 insertions(+), 3 deletions(-)
+
+--- a/drivers/gpu/drm/radeon/cik.c
++++ b/drivers/gpu/drm/radeon/cik.c
+@@ -7779,6 +7779,7 @@ restart_ih:
+ static int cik_startup(struct radeon_device *rdev)
+ {
+ struct radeon_ring *ring;
++ u32 nop;
+ int r;
+
+ /* enable pcie gen2/3 link */
+@@ -7896,9 +7897,15 @@ static int cik_startup(struct radeon_dev
+ }
+ cik_irq_set(rdev);
+
++ if (rdev->family == CHIP_HAWAII) {
++ nop = RADEON_CP_PACKET2;
++ } else {
++ nop = PACKET3(PACKET3_NOP, 0x3FFF);
++ }
++
+ ring = &rdev->ring[RADEON_RING_TYPE_GFX_INDEX];
+ r = radeon_ring_init(rdev, ring, ring->ring_size, RADEON_WB_CP_RPTR_OFFSET,
+- PACKET3(PACKET3_NOP, 0x3FFF));
++ nop);
+ if (r)
+ return r;
+
+@@ -7906,7 +7913,7 @@ static int cik_startup(struct radeon_dev
+ /* type-2 packets are deprecated on MEC, use type-3 instead */
+ ring = &rdev->ring[CAYMAN_RING_TYPE_CP1_INDEX];
+ r = radeon_ring_init(rdev, ring, ring->ring_size, RADEON_WB_CP1_RPTR_OFFSET,
+- PACKET3(PACKET3_NOP, 0x3FFF));
++ nop);
+ if (r)
+ return r;
+ ring->me = 1; /* first MEC */
+@@ -7917,7 +7924,7 @@ static int cik_startup(struct radeon_dev
+ /* type-2 packets are deprecated on MEC, use type-3 instead */
+ ring = &rdev->ring[CAYMAN_RING_TYPE_CP2_INDEX];
+ r = radeon_ring_init(rdev, ring, ring->ring_size, RADEON_WB_CP2_RPTR_OFFSET,
+- PACKET3(PACKET3_NOP, 0x3FFF));
++ nop);
+ if (r)
+ return r;
+ /* dGPU only have 1 MEC */
--- /dev/null
+From aee530cfecf4f3ec83b78406bac618cec35853f8 Mon Sep 17 00:00:00 2001
+From: Guenter Roeck <linux@roeck-us.net>
+Date: Wed, 13 Aug 2014 11:21:34 -0700
+Subject: firmware: Do not use WARN_ON(!spin_is_locked())
+
+From: Guenter Roeck <linux@roeck-us.net>
+
+commit aee530cfecf4f3ec83b78406bac618cec35853f8 upstream.
+
+spin_is_locked() always returns false for uniprocessor configurations
+in several architectures, so do not use WARN_ON with it.
+Use lockdep_assert_held() instead to also reduce overhead in
+non-debug kernels.
+
+Signed-off-by: Guenter Roeck <linux@roeck-us.net>
+Signed-off-by: Matt Fleming <matt.fleming@intel.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/firmware/efi/vars.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+--- a/drivers/firmware/efi/vars.c
++++ b/drivers/firmware/efi/vars.c
+@@ -481,7 +481,7 @@ EXPORT_SYMBOL_GPL(efivar_entry_remove);
+ */
+ static void efivar_entry_list_del_unlock(struct efivar_entry *entry)
+ {
+- WARN_ON(!spin_is_locked(&__efivars->lock));
++ lockdep_assert_held(&__efivars->lock);
+
+ list_del(&entry->list);
+ spin_unlock_irq(&__efivars->lock);
+@@ -507,7 +507,7 @@ int __efivar_entry_delete(struct efivar_
+ const struct efivar_operations *ops = __efivars->ops;
+ efi_status_t status;
+
+- WARN_ON(!spin_is_locked(&__efivars->lock));
++ lockdep_assert_held(&__efivars->lock);
+
+ status = ops->set_variable(entry->var.VariableName,
+ &entry->var.VendorGuid,
+@@ -667,7 +667,7 @@ struct efivar_entry *efivar_entry_find(e
+ int strsize1, strsize2;
+ bool found = false;
+
+- WARN_ON(!spin_is_locked(&__efivars->lock));
++ lockdep_assert_held(&__efivars->lock);
+
+ list_for_each_entry_safe(entry, n, head, list) {
+ strsize1 = ucs2_strsize(name, 1024);
+@@ -739,7 +739,7 @@ int __efivar_entry_get(struct efivar_ent
+ const struct efivar_operations *ops = __efivars->ops;
+ efi_status_t status;
+
+- WARN_ON(!spin_is_locked(&__efivars->lock));
++ lockdep_assert_held(&__efivars->lock);
+
+ status = ops->get_variable(entry->var.VariableName,
+ &entry->var.VendorGuid,
--- /dev/null
+From 9b29d3c6510407d91786c1cf9183ff4debb3473a Mon Sep 17 00:00:00 2001
+From: Joerg Roedel <jroedel@suse.de>
+Date: Tue, 5 Aug 2014 17:50:15 +0200
+Subject: iommu/amd: Fix cleanup_domain for mass device removal
+
+From: Joerg Roedel <jroedel@suse.de>
+
+commit 9b29d3c6510407d91786c1cf9183ff4debb3473a upstream.
+
+When multiple devices are detached in __detach_device, they
+are also removed from the domains dev_list. This makes it
+unsafe to use list_for_each_entry_safe, as the next pointer
+might also not be in the list anymore after __detach_device
+returns. So just repeatedly remove the first element of the
+list until it is empty.
+
+Tested-by: Marti Raudsepp <marti@juffo.org>
+Signed-off-by: Joerg Roedel <jroedel@suse.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/iommu/amd_iommu.c | 10 ++++++----
+ 1 file changed, 6 insertions(+), 4 deletions(-)
+
+--- a/drivers/iommu/amd_iommu.c
++++ b/drivers/iommu/amd_iommu.c
+@@ -3227,14 +3227,16 @@ free_domains:
+
+ static void cleanup_domain(struct protection_domain *domain)
+ {
+- struct iommu_dev_data *dev_data, *next;
++ struct iommu_dev_data *entry;
+ unsigned long flags;
+
+ write_lock_irqsave(&amd_iommu_devtable_lock, flags);
+
+- list_for_each_entry_safe(dev_data, next, &domain->dev_list, list) {
+- __detach_device(dev_data);
+- atomic_set(&dev_data->bind, 0);
++ while (!list_empty(&domain->dev_list)) {
++ entry = list_first_entry(&domain->dev_list,
++ struct iommu_dev_data, list);
++ __detach_device(entry);
++ atomic_set(&entry->bind, 0);
+ }
+
+ write_unlock_irqrestore(&amd_iommu_devtable_lock, flags);
--- /dev/null
+From f8ca6ac00d2ba24c5557f08f81439cd3432f0802 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Salva=20Peir=C3=B3?= <speiro@ai2.upv.es>
+Date: Sat, 7 Jun 2014 11:41:44 -0300
+Subject: media: media-device: Remove duplicated memset() in media_enum_entities()
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+From: Salva Peiró <speiro@ai2.upv.es>
+
+commit f8ca6ac00d2ba24c5557f08f81439cd3432f0802 upstream.
+
+After the zeroing the whole struct struct media_entity_desc u_ent,
+it is no longer necessary to memset(0) its u_ent.name field.
+
+Signed-off-by: Salva Peiró <speiro@ai2.upv.es>
+Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
+Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/media/media-device.c | 2 --
+ 1 file changed, 2 deletions(-)
+
+--- a/drivers/media/media-device.c
++++ b/drivers/media/media-device.c
+@@ -106,8 +106,6 @@ static long media_device_enum_entities(s
+ if (ent->name) {
+ strncpy(u_ent.name, ent->name, sizeof(u_ent.name));
+ u_ent.name[sizeof(u_ent.name) - 1] = '\0';
+- } else {
+- memset(u_ent.name, 0, sizeof(u_ent.name));
+ }
+ u_ent.type = ent->type;
+ u_ent.revision = ent->revision;
--- /dev/null
+From f17bc3f4707eb87bdb80b895911c551cdd606fbd Mon Sep 17 00:00:00 2001
+From: Philipp Zabel <p.zabel@pengutronix.de>
+Date: Mon, 26 May 2014 10:55:51 -0300
+Subject: media: mt9v032: fix hblank calculation
+
+From: Philipp Zabel <p.zabel@pengutronix.de>
+
+commit f17bc3f4707eb87bdb80b895911c551cdd606fbd upstream.
+
+Since (min_row_time - crop->width) can be negative, we have to do a signed
+comparison here. Otherwise max_t casts the negative value to unsigned int
+and sets min_hblank to that invalid value.
+
+Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
+Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
+Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/media/i2c/mt9v032.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+--- a/drivers/media/i2c/mt9v032.c
++++ b/drivers/media/i2c/mt9v032.c
+@@ -305,8 +305,8 @@ mt9v032_update_hblank(struct mt9v032 *mt
+
+ if (mt9v032->version->version == MT9V034_CHIP_ID_REV1)
+ min_hblank += (mt9v032->hratio - 1) * 10;
+- min_hblank = max_t(unsigned int, (int)mt9v032->model->data->min_row_time - crop->width,
+- (int)min_hblank);
++ min_hblank = max_t(int, mt9v032->model->data->min_row_time - crop->width,
++ min_hblank);
+ hblank = max_t(unsigned int, mt9v032->hblank, min_hblank);
+
+ return mt9v032_write(client, MT9V032_HORIZONTAL_BLANKING, hblank);
--- /dev/null
+From 3c4b422adb7694418848cefc2a4669d63192c649 Mon Sep 17 00:00:00 2001
+From: Paul Bolle <pebolle@tiscali.nl>
+Date: Wed, 16 Apr 2014 12:47:43 -0300
+Subject: media: sms: Remove CONFIG_ prefix from Kconfig symbols
+
+From: Paul Bolle <pebolle@tiscali.nl>
+
+commit 3c4b422adb7694418848cefc2a4669d63192c649 upstream.
+
+X-Patchwork-Delegate: mchehab@redhat.com
+Remove the CONFIG_ prefix from two Kconfig symbols in a dependency for
+SMS_SIANO_DEBUGFS. This prefix is invalid inside Kconfig files.
+
+Note that the current (common sense) dependency on SMS_USB_DRV and
+SMS_SDIO_DRV being equal ensures that SMS_SIANO_DEBUGFS will not
+violate its constraints. These constraint are that:
+- it should only be built if SMS_USB_DRV is set;
+- it can't be builtin if USB support is modular.
+
+So drop the dependency on SMS_USB_DRV, as it is unneeded.
+
+Fixes: 6c84b214284e ("[media] sms: fix randconfig building error")
+
+Reported-by: Martin Walch <walch.martin@web.de>
+Signed-off-by: Paul Bolle <pebolle@tiscali.nl>
+Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/media/common/siano/Kconfig | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+--- a/drivers/media/common/siano/Kconfig
++++ b/drivers/media/common/siano/Kconfig
+@@ -22,8 +22,7 @@ config SMS_SIANO_DEBUGFS
+ bool "Enable debugfs for smsdvb"
+ depends on SMS_SIANO_MDTV
+ depends on DEBUG_FS
+- depends on SMS_USB_DRV
+- depends on CONFIG_SMS_USB_DRV = CONFIG_SMS_SDIO_DRV
++ depends on SMS_USB_DRV = SMS_SDIO_DRV
+
+ ---help---
+ Choose Y to enable visualizing a dump of the frontend
--- /dev/null
+From e51daefc228aa164adcc17fe8fce0f856ad0a1cc Mon Sep 17 00:00:00 2001
+From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
+Date: Wed, 21 May 2014 17:39:16 -0300
+Subject: media: v4l: vsp1: Remove the unneeded vsp1_video_buffer video field
+
+From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
+
+commit e51daefc228aa164adcc17fe8fce0f856ad0a1cc upstream.
+
+The field is assigned but never read, remove it.
+
+This fixes a bug caused by the struct vb2_buffer field not being be the
+very first field of the vsp1_video_buffer buffer structure as required
+by videobuf2.
+
+Reported-by: Takanari Hayama <taki@igel.co.jp>
+Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
+Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/media/platform/vsp1/vsp1_video.c | 2 --
+ drivers/media/platform/vsp1/vsp1_video.h | 1 -
+ 2 files changed, 3 deletions(-)
+
+--- a/drivers/media/platform/vsp1/vsp1_video.c
++++ b/drivers/media/platform/vsp1/vsp1_video.c
+@@ -635,8 +635,6 @@ static int vsp1_video_buffer_prepare(str
+ if (vb->num_planes < format->num_planes)
+ return -EINVAL;
+
+- buf->video = video;
+-
+ for (i = 0; i < vb->num_planes; ++i) {
+ buf->addr[i] = vb2_dma_contig_plane_dma_addr(vb, i);
+ buf->length[i] = vb2_plane_size(vb, i);
+--- a/drivers/media/platform/vsp1/vsp1_video.h
++++ b/drivers/media/platform/vsp1/vsp1_video.h
+@@ -89,7 +89,6 @@ static inline struct vsp1_pipeline *to_v
+ }
+
+ struct vsp1_video_buffer {
+- struct vsp1_video *video;
+ struct vb2_buffer buf;
+ struct list_head queue;
+
--- /dev/null
+From 36e7fdaa1a04fcf65b864232e1af56a51c7814d6 Mon Sep 17 00:00:00 2001
+From: Christian Borntraeger <borntraeger@de.ibm.com>
+Date: Tue, 5 Aug 2014 09:57:51 +0200
+Subject: s390/locking: Reenable optimistic spinning
+
+From: Christian Borntraeger <borntraeger@de.ibm.com>
+
+commit 36e7fdaa1a04fcf65b864232e1af56a51c7814d6 upstream.
+
+commit 4badad352a6bb202ec68afa7a574c0bb961e5ebc (locking/mutex: Disable
+optimistic spinning on some architectures) fenced spinning for
+architectures without proper cmpxchg.
+There is no need to disable mutex spinning on s390, though:
+The instructions CS,CSG and friends provide the proper guarantees.
+(We dont implement cmpxchg with locks).
+
+Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
+Cc: Ingo Molnar <mingo@kernel.org>
+Cc: Peter Zijlstra <peterz@infradead.org>
+Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
+Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/s390/Kconfig | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/arch/s390/Kconfig
++++ b/arch/s390/Kconfig
+@@ -93,6 +93,7 @@ config S390
+ select ARCH_INLINE_WRITE_UNLOCK_IRQ
+ select ARCH_INLINE_WRITE_UNLOCK_IRQRESTORE
+ select ARCH_SAVE_PAGE_KEYS if HIBERNATION
++ select ARCH_SUPPORTS_ATOMIC_RMW
+ select ARCH_USE_CMPXCHG_LOCKREF
+ select ARCH_WANT_IPC_PARSE_VERSION
+ select BUILDTIME_EXTABLE_SORT
media-xc5000-fix-get_frequency.patch
media-xc4000-fix-get_frequency.patch
media-au0828-only-alt-setting-logic-when-needed.patch
+media-media-device-remove-duplicated-memset-in-media_enum_entities.patch
+media-mt9v032-fix-hblank-calculation.patch
+media-v4l-vsp1-remove-the-unneeded-vsp1_video_buffer-video-field.patch
+media-sms-remove-config_-prefix-from-kconfig-symbols.patch
+iommu-amd-fix-cleanup_domain-for-mass-device-removal.patch
+spi-orion-fix-incorrect-handling-of-cell-index-dt-property.patch
+spi-omap2-mcspi-configure-hardware-when-slave-driver-changes-mode.patch
+s390-locking-reenable-optimistic-spinning.patch
+drm-radeon-use-packet2-for-nop-on-hawaii-with-old-firmware.patch
+firmware-do-not-use-warn_on-spin_is_locked.patch
--- /dev/null
+From 97ca0d6cc118716840ea443e010cb3d5f2d25eaf Mon Sep 17 00:00:00 2001
+From: "Mark A. Greer" <mgreer@animalcreek.com>
+Date: Tue, 1 Jul 2014 20:28:32 -0700
+Subject: spi: omap2-mcspi: Configure hardware when slave driver changes mode
+
+From: "Mark A. Greer" <mgreer@animalcreek.com>
+
+commit 97ca0d6cc118716840ea443e010cb3d5f2d25eaf upstream.
+
+Commit id 2bd16e3e23d9df41592c6b257c59b6860a9cc3ea
+(spi: omap2-mcspi: Do not configure the controller
+on each transfer unless needed) does its job too
+well so omap2_mcspi_setup_transfer() isn't called
+even when an SPI slave driver changes 'spi->mode'.
+The result is that the mode requested by the SPI
+slave driver never takes effect.
+
+Fix this by adding the 'mode' member to the
+omap2_mcspi_cs structure which holds the mode
+value that the hardware is configured for.
+When the SPI slave driver changes 'spi->mode'
+it will be different than the value of this new
+member and the SPI master driver will know that
+the hardware must be reconfigured (by calling
+omap2_mcspi_setup_transfer()).
+
+Fixes: 2bd16e3e23 (spi: omap2-mcspi: Do not configure the controller on each transfer unless needed)
+Signed-off-by: Mark A. Greer <mgreer@animalcreek.com>
+Signed-off-by: Mark Brown <broonie@linaro.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/spi/spi-omap2-mcspi.c | 14 ++++++++++++++
+ 1 file changed, 14 insertions(+)
+
+--- a/drivers/spi/spi-omap2-mcspi.c
++++ b/drivers/spi/spi-omap2-mcspi.c
+@@ -147,6 +147,7 @@ struct omap2_mcspi_cs {
+ void __iomem *base;
+ unsigned long phys;
+ int word_len;
++ u16 mode;
+ struct list_head node;
+ /* Context save and restore shadow register */
+ u32 chconf0;
+@@ -899,6 +900,8 @@ static int omap2_mcspi_setup_transfer(st
+
+ mcspi_write_chconf0(spi, l);
+
++ cs->mode = spi->mode;
++
+ dev_dbg(&spi->dev, "setup: speed %d, sample %s edge, clk %s\n",
+ OMAP2_MCSPI_MAX_FREQ >> div,
+ (spi->mode & SPI_CPHA) ? "trailing" : "leading",
+@@ -971,6 +974,7 @@ static int omap2_mcspi_setup(struct spi_
+ return -ENOMEM;
+ cs->base = mcspi->base + spi->chip_select * 0x14;
+ cs->phys = mcspi->phys + spi->chip_select * 0x14;
++ cs->mode = 0;
+ cs->chconf0 = 0;
+ spi->controller_state = cs;
+ /* Link this to context save list */
+@@ -1051,6 +1055,16 @@ static void omap2_mcspi_work(struct omap
+ cs = spi->controller_state;
+ cd = spi->controller_data;
+
++ /*
++ * The slave driver could have changed spi->mode in which case
++ * it will be different from cs->mode (the current hardware setup).
++ * If so, set par_override (even though its not a parity issue) so
++ * omap2_mcspi_setup_transfer will be called to configure the hardware
++ * with the correct mode on the first iteration of the loop below.
++ */
++ if (spi->mode != cs->mode)
++ par_override = 1;
++
+ omap2_mcspi_set_enable(spi, 0);
+ list_for_each_entry(t, &m->transfers, transfer_list) {
+ if (t->tx_buf == NULL && t->rx_buf == NULL && t->len) {
--- /dev/null
+From e06871cd2c92e5c65d7ca1d32866b4ca5dd4ac30 Mon Sep 17 00:00:00 2001
+From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
+Date: Sun, 27 Jul 2014 23:53:19 +0200
+Subject: spi: orion: fix incorrect handling of cell-index DT property
+
+From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
+
+commit e06871cd2c92e5c65d7ca1d32866b4ca5dd4ac30 upstream.
+
+In commit f814f9ac5a81 ("spi/orion: add device tree binding"), Device
+Tree support was added to the spi-orion driver. However, this commit
+reads the "cell-index" property, without taking into account the fact
+that DT properties are big-endian encoded.
+
+Since most of the platforms using spi-orion with DT have apparently
+not used anything but cell-index = <0>, the problem was not
+visible. But as soon as one starts using cell-index = <1>, the problem
+becomes clearly visible, as the master->bus_num gets a wrong value
+(actually it gets the value 0, which conflicts with the first bus that
+has cell-index = <0>).
+
+This commit fixes that by using of_property_read_u32() to read the
+property value, which does the appropriate endianness conversion when
+needed.
+
+Fixes: f814f9ac5a81 ("spi/orion: add device tree binding")
+Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
+Acked-by: Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
+Signed-off-by: Mark Brown <broonie@linaro.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/spi/spi-orion.c | 10 ++++------
+ 1 file changed, 4 insertions(+), 6 deletions(-)
+
+--- a/drivers/spi/spi-orion.c
++++ b/drivers/spi/spi-orion.c
+@@ -404,8 +404,6 @@ static int orion_spi_probe(struct platfo
+ struct resource *r;
+ unsigned long tclk_hz;
+ int status = 0;
+- const u32 *iprop;
+- int size;
+
+ master = spi_alloc_master(&pdev->dev, sizeof(*spi));
+ if (master == NULL) {
+@@ -416,10 +414,10 @@ static int orion_spi_probe(struct platfo
+ if (pdev->id != -1)
+ master->bus_num = pdev->id;
+ if (pdev->dev.of_node) {
+- iprop = of_get_property(pdev->dev.of_node, "cell-index",
+- &size);
+- if (iprop && size == sizeof(*iprop))
+- master->bus_num = *iprop;
++ u32 cell_index;
++ if (!of_property_read_u32(pdev->dev.of_node, "cell-index",
++ &cell_index))
++ master->bus_num = cell_index;
+ }
+
+ /* we support only mode 0, and no options */