All of lore.kernel.org
 help / color / mirror / Atom feed
From: Joerg Roedel <joro@8bytes.org>
To: Dan Carpenter <dan.carpenter-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
Cc: kernel-janitors-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org,
	linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	Matthias Brugger
	<matthias.bgg-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Subject: Re: [patch 1/2] iommu/mediatek: signedness bug in probe function
Date: Wed, 02 Mar 2016 13:53:52 +0000	[thread overview]
Message-ID: <20160302135351.GC20213@8bytes.org> (raw)
In-Reply-To: <20160302101006.GF5533@mwanda>

On Wed, Mar 02, 2016 at 01:10:06PM +0300, Dan Carpenter wrote:
> "larb_nr" needs to be signed for the error handling to work.  "i" can
> be int as well.
> 
> Fixes: 0df4fabe208d ('iommu/mediatek: Add mt8173 IOMMU driver')
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
> 
> diff --git a/drivers/iommu/mtk_iommu.c b/drivers/iommu/mtk_iommu.c
> index 721ffdb..1a4022c 100644
> --- a/drivers/iommu/mtk_iommu.c
> +++ b/drivers/iommu/mtk_iommu.c
> @@ -578,7 +578,7 @@ static int mtk_iommu_probe(struct platform_device *pdev)
>  	struct resource         *res;
>  	struct component_match  *match = NULL;
>  	void                    *protect;
> -	unsigned int            i, larb_nr;
> +	int			i, larb_nr;
>  	int                     ret;
>  
>  	data = devm_kzalloc(dev, sizeof(*data), GFP_KERNEL);

I merged a similar fix from Andrzej Hajda yesterday.

WARNING: multiple messages have this Message-ID (diff)
From: Joerg Roedel <joro-zLv9SwRftAIdnm+yROfE0A@public.gmane.org>
To: Dan Carpenter <dan.carpenter-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
Cc: kernel-janitors-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org,
	linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	Matthias Brugger
	<matthias.bgg-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Subject: Re: [patch 1/2] iommu/mediatek: signedness bug in probe function
Date: Wed, 2 Mar 2016 14:53:52 +0100	[thread overview]
Message-ID: <20160302135351.GC20213@8bytes.org> (raw)
In-Reply-To: <20160302101006.GF5533@mwanda>

On Wed, Mar 02, 2016 at 01:10:06PM +0300, Dan Carpenter wrote:
> "larb_nr" needs to be signed for the error handling to work.  "i" can
> be int as well.
> 
> Fixes: 0df4fabe208d ('iommu/mediatek: Add mt8173 IOMMU driver')
> Signed-off-by: Dan Carpenter <dan.carpenter-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
> 
> diff --git a/drivers/iommu/mtk_iommu.c b/drivers/iommu/mtk_iommu.c
> index 721ffdb..1a4022c 100644
> --- a/drivers/iommu/mtk_iommu.c
> +++ b/drivers/iommu/mtk_iommu.c
> @@ -578,7 +578,7 @@ static int mtk_iommu_probe(struct platform_device *pdev)
>  	struct resource         *res;
>  	struct component_match  *match = NULL;
>  	void                    *protect;
> -	unsigned int            i, larb_nr;
> +	int			i, larb_nr;
>  	int                     ret;
>  
>  	data = devm_kzalloc(dev, sizeof(*data), GFP_KERNEL);

I merged a similar fix from Andrzej Hajda yesterday.

WARNING: multiple messages have this Message-ID (diff)
From: Joerg Roedel <joro@8bytes.org>
To: Dan Carpenter <dan.carpenter@oracle.com>
Cc: Yong Wu <yong.wu@mediatek.com>,
	Matthias Brugger <matthias.bgg@gmail.com>,
	iommu@lists.linux-foundation.org,
	linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org,
	kernel-janitors@vger.kernel.org
Subject: Re: [patch 1/2] iommu/mediatek: signedness bug in probe function
Date: Wed, 2 Mar 2016 14:53:52 +0100	[thread overview]
Message-ID: <20160302135351.GC20213@8bytes.org> (raw)
In-Reply-To: <20160302101006.GF5533@mwanda>

On Wed, Mar 02, 2016 at 01:10:06PM +0300, Dan Carpenter wrote:
> "larb_nr" needs to be signed for the error handling to work.  "i" can
> be int as well.
> 
> Fixes: 0df4fabe208d ('iommu/mediatek: Add mt8173 IOMMU driver')
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
> 
> diff --git a/drivers/iommu/mtk_iommu.c b/drivers/iommu/mtk_iommu.c
> index 721ffdb..1a4022c 100644
> --- a/drivers/iommu/mtk_iommu.c
> +++ b/drivers/iommu/mtk_iommu.c
> @@ -578,7 +578,7 @@ static int mtk_iommu_probe(struct platform_device *pdev)
>  	struct resource         *res;
>  	struct component_match  *match = NULL;
>  	void                    *protect;
> -	unsigned int            i, larb_nr;
> +	int			i, larb_nr;
>  	int                     ret;
>  
>  	data = devm_kzalloc(dev, sizeof(*data), GFP_KERNEL);

I merged a similar fix from Andrzej Hajda yesterday.

  reply	other threads:[~2016-03-02 13:53 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-02 10:10 [patch 1/2] iommu/mediatek: signedness bug in probe function Dan Carpenter
2016-03-02 10:10 ` Dan Carpenter
2016-03-02 10:10 ` Dan Carpenter
2016-03-02 13:53 ` Joerg Roedel [this message]
2016-03-02 13:53   ` Joerg Roedel
2016-03-02 13:53   ` Joerg Roedel

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=20160302135351.GC20213@8bytes.org \
    --to=joro@8bytes.org \
    --cc=dan.carpenter-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org \
    --cc=iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org \
    --cc=kernel-janitors-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
    --cc=matthias.bgg-Re5JQEeQqe8AvxtiuMwx3w@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.