All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mark Brown <broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
To: Andrzej Hajda <a.hajda-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>,
	Mark Brown <broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
Cc: linux-spi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Applied "spi: davinci: fix handling platform_get_irq result" to the spi tree
Date: Fri, 25 Sep 2015 11:09:44 -0700	[thread overview]
Message-ID: <E1ZfXRI-0002vQ-KC@finisterre> (raw)
In-Reply-To: <1443103227-25612-3-git-send-email-a.hajda-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>

The patch

   spi: davinci: fix handling platform_get_irq result

has been applied to the spi tree at

   git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git 

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.  

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

>From 8494cdea2223b66491df1264619e2205b4487913 Mon Sep 17 00:00:00 2001
From: Andrzej Hajda <a.hajda-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
Date: Thu, 24 Sep 2015 16:00:10 +0200
Subject: [PATCH] spi: davinci: fix handling platform_get_irq result

The function can return negative value.

The problem has been detected using proposed semantic patch
scripts/coccinelle/tests/assign_signed_to_unsigned.cocci [1].

[1]: http://permalink.gmane.org/gmane.linux.kernel/2046107

Signed-off-by: Andrzej Hajda <a.hajda-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
Signed-off-by: Mark Brown <broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
---
 drivers/spi/spi-davinci.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/drivers/spi/spi-davinci.c b/drivers/spi/spi-davinci.c
index 3cf9faa..a85d863 100644
--- a/drivers/spi/spi-davinci.c
+++ b/drivers/spi/spi-davinci.c
@@ -992,11 +992,12 @@ static int davinci_spi_probe(struct platform_device *pdev)
 		goto free_master;
 	}
 
-	dspi->irq = platform_get_irq(pdev, 0);
-	if (dspi->irq <= 0) {
+	ret = platform_get_irq(pdev, 0);
+	if (ret == 0)
 		ret = -EINVAL;
+	if (ret < 0)
 		goto free_master;
-	}
+	dspi->irq = ret;
 
 	ret = devm_request_threaded_irq(&pdev->dev, dspi->irq, davinci_spi_irq,
 				dummy_thread_fn, 0, dev_name(&pdev->dev), dspi);
-- 
2.5.0

--
To unsubscribe from this list: send the line "unsubscribe linux-spi" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2015-09-25 18:09 UTC|newest]

Thread overview: 53+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-24 14:00 [PATCH 00/19] Fixes related to incorrect assignment of signed results function Andrzej Hajda
2015-09-24 14:00 ` [PATCH 01/19] SUNRPC: fix variable type Andrzej Hajda
2015-09-25 20:25   ` J. Bruce Fields
2015-09-25 20:25     ` J. Bruce Fields
2015-09-24 14:00 ` [PATCH 02/19] spi: davinci: fix handling platform_get_irq result Andrzej Hajda
2015-09-24 14:00   ` Andrzej Hajda
     [not found]   ` <1443103227-25612-3-git-send-email-a.hajda-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
2015-09-25 18:09     ` Mark Brown [this message]
2015-09-24 14:00 ` [PATCH 03/19] libata: samsung_cf: " Andrzej Hajda
2015-09-24 14:53   ` Tejun Heo
2015-09-25  6:43     ` [PATCH v2 " Andrzej Hajda
2015-09-25 15:50       ` Tejun Heo
2015-09-24 14:00 ` [PATCH 04/19] v4l: omap3isp: " Andrzej Hajda
2015-11-09 20:16   ` Laurent Pinchart
2015-11-10  6:48     ` Andrzej Hajda
2015-11-10  8:53       ` Laurent Pinchart
2015-11-10  9:59         ` Andrzej Hajda
2015-09-24 14:00 ` [PATCH 05/19] media: am437x-vpfe: " Andrzej Hajda
2015-09-24 14:00 ` [PATCH 06/19] staging: media: omap4iss: " Andrzej Hajda
2015-09-24 15:07   ` Dan Carpenter
2015-09-24 14:00 ` [PATCH 07/19] net: hisilicon: " Andrzej Hajda
2015-09-27  5:47   ` David Miller
2015-09-24 14:00 ` [PATCH 08/19] clk: st: fix handling result of of_property_count_strings Andrzej Hajda
2015-10-01 22:23   ` Stephen Boyd
2015-09-24 14:00 ` [PATCH 09/19] dmaengine: xgene-dma: fix handling xgene_dma_get_ring_size result Andrzej Hajda
2015-09-25  2:09   ` Vinod Koul
2015-09-24 14:00 ` [PATCH 10/19] cx231xx: fix handling cx231xx_read_i2c_data result Andrzej Hajda
2015-09-24 14:00 ` [PATCH 11/19] clocksource: fix __ftm_clk_init result Andrzej Hajda
2015-12-14 10:34   ` Andrzej Hajda
2015-12-14 13:27     ` Daniel Lezcano
2015-09-24 14:00 ` [PATCH 12/19] extcon: rt8973a: fix handling regmap_irq_get_virq result Andrzej Hajda
2015-09-24 23:40   ` Chanwoo Choi
2015-09-24 14:00 ` [PATCH 13/19] extcon: sm5502: " Andrzej Hajda
2015-09-24 23:40   ` Chanwoo Choi
2015-09-24 14:00 ` [PATCH 14/19] sony-laptop: fix handling sony_nc_hotkeys_decode result Andrzej Hajda
2015-10-03 16:39   ` Darren Hart
2015-10-05  7:42     ` Andrzej Hajda
2015-09-24 14:00 ` [PATCH 15/19] KVM: PPC: e500: fix handling local_sid_lookup result Andrzej Hajda
2015-09-24 14:00   ` Andrzej Hajda
2015-09-24 22:58   ` Scott Wood
2015-09-24 22:58     ` Scott Wood
2015-10-15  5:30   ` Paul Mackerras
2015-10-15  5:30     ` Paul Mackerras
2015-09-24 14:00 ` [PATCH 16/19] r8169: fix handling rtl_readphy result Andrzej Hajda
2015-09-27  5:48   ` David Miller
2015-09-24 14:00 ` [PATCH 17/19] tools: bpf_jit_disasm: make get_last_jit_image return unsigned Andrzej Hajda
2015-09-24 18:53   ` Daniel Borkmann
2015-09-25  6:45     ` [PATCH v2 " Andrzej Hajda
2015-09-29  5:18       ` David Miller
2015-09-24 14:00 ` [PATCH 18/19] mac80211: make ieee80211_new_mesh_header " Andrzej Hajda
2015-09-24 14:09   ` Johannes Berg
2015-09-25  6:42     ` [PATCH v2 " Andrzej Hajda
2015-09-24 14:00 ` [PATCH 19/19] block: nvme-scsi: make nvme_trans_get_blk_desc_len " Andrzej Hajda
2015-09-24 14:00   ` Andrzej Hajda

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=E1ZfXRI-0002vQ-KC@finisterre \
    --to=broonie-dgejt+ai2ygdnm+yrofe0a@public.gmane.org \
    --cc=a.hajda-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org \
    --cc=linux-spi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.