2015-10-13 06:38:41

by Christophe JAILLET

[permalink] [raw]
Subject: [PATCH] NFC: nfcwilink: Drop a useless static qualifier

There is no need to have the 'struct nfcwilink *drv' variable static in the
probe function.
It only wastes a few bytes of memory.

Signed-off-by: Christophe JAILLET <[email protected]>
---
drivers/nfc/nfcwilink.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/nfc/nfcwilink.c b/drivers/nfc/nfcwilink.c
index ce2e2cf..f81e500 100644
--- a/drivers/nfc/nfcwilink.c
+++ b/drivers/nfc/nfcwilink.c
@@ -497,7 +497,7 @@ static struct nci_ops nfcwilink_ops = {

static int nfcwilink_probe(struct platform_device *pdev)
{
- static struct nfcwilink *drv;
+ struct nfcwilink *drv;
int rc;
__u32 protocols;

--
2.1.4



2015-10-20 04:50:54

by Samuel Ortiz

[permalink] [raw]
Subject: Re: [PATCH] NFC: nfcwilink: Drop a useless static qualifier

Hi Christophe,

On Tue, Oct 13, 2015 at 08:31:04AM +0200, Christophe JAILLET wrote:
> There is no need to have the 'struct nfcwilink *drv' variable static in the
> probe function.
> It only wastes a few bytes of memory.
>
> Signed-off-by: Christophe JAILLET <[email protected]>
> ---
> drivers/nfc/nfcwilink.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied, thanks a lot.

Cheers,
Samuel.