Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp631418pxu; Thu, 26 Nov 2020 07:36:55 -0800 (PST) X-Google-Smtp-Source: ABdhPJzzqNKa+x01Vz6w1tFxgt79pRXetUNAprNsk+fvNOHCFFO1tJ6wrpAbHGjiMuimgGWecIsw X-Received: by 2002:a17:906:4c82:: with SMTP id q2mr3083276eju.285.1606405015489; Thu, 26 Nov 2020 07:36:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606405015; cv=none; d=google.com; s=arc-20160816; b=0V1JyzNAzw+449nOs8iwsXL5O1UcCUIDlysamOBeF21gasP8zQhSbpLOcTzxeUmA0V mqSamaKOp3ORtS8QnXVNqrJ/Gri6YR8soYWRaqPZW910UJ4IS0ZgdT0YLcub+rvFE/vd nQ2Jx+qA4anTWYzJmAc/qksE1ZhWO9EsD5jMqPghM/qKC8nBR5HwpNMsvGXMM3k68ljK rlRx5A2k5Rv8B3mcjApQWjlmAp2ZqHXCdrGj57snSiL6qifr1uhbtL0+FLRuUbcb0lzK jEbxannwRZvhRd+DVdnUxI9oBFHUTpsddnPrv1z8ezsuRLx8CbHLRsl0f6BFFHabSwlL 08Lg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:subject:cc:to:from :dkim-signature; bh=f18jjpAb3a6wwaCwAQVq0XjGDSvE4J1ZBEOKED5Wevo=; b=wzeq7Hyf2xricuwy7sjEokmpWJ2oJxlHpO6G8wVLJ4tF29jH8Pe8ED+IB9ZYKJoa0l oGavxZShRGf3VHzLJxbfDSvYZDj6jHS685UzxwAuacssF0Mj1kAfAD4ZCKwVW1u/XzfX +RbUOzesNNKZQDSzKO4ZHImux7tsffqhANjQG5vB8Almx8LrQwNLL3aquMD/25EQhgr2 d1/oztBgYeFTHy11q4cVol6zces6NDjMMjSTIa1gvEgfEd9IjzeQbZoT7X35vvoDfiP2 pUhtaYjyIRV2PH9lejt/Lg+74/9X+22l0T9VmF1UCS4Irb0OijK5tS/rGHBJh16fzVEz kXQg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=on+EDg2Z; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m7si3870978edq.548.2020.11.26.07.36.33; Thu, 26 Nov 2020 07:36:55 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=on+EDg2Z; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2391356AbgKZPfF (ORCPT + 99 others); Thu, 26 Nov 2020 10:35:05 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48084 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731552AbgKZPfD (ORCPT ); Thu, 26 Nov 2020 10:35:03 -0500 Received: from mail-pf1-x442.google.com (mail-pf1-x442.google.com [IPv6:2607:f8b0:4864:20::442]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D4D6DC0613D4; Thu, 26 Nov 2020 07:35:03 -0800 (PST) Received: by mail-pf1-x442.google.com with SMTP id w202so1916759pff.10; Thu, 26 Nov 2020 07:35:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=f18jjpAb3a6wwaCwAQVq0XjGDSvE4J1ZBEOKED5Wevo=; b=on+EDg2Z1e4uBbPphYAsXBdymQ1mDw1L7F4O+cc3NuYhxJmsVg1q4l0KdjogSr0UmM 5zX3C570Udeih/3brql3WxCCiAIZw+1Lf1952jtEqG2jsSOX3xqxQk7Xuf0OIbWUz0br hiShsEQNM0vzINR6dKHYML6X7wfzmY7aAH11ekUPkl3PhnFVS9VnHKRIM0ULwfuJqZBD L2LyRWHFu6IQAuWmsWK/+7aQqqhBPc6eOEbUKFF1229In9jIuG9TxcJyEnYunJ7WrJhg cyhHUZK9vAJ6KnDbTzZtc0aUb67mksJOUh8/HT9iAelnsyCsL6I8CPW1KJNqEUMEBeEz co4Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=f18jjpAb3a6wwaCwAQVq0XjGDSvE4J1ZBEOKED5Wevo=; b=rbo/h5MuMpi7UqZGu6YGW4kHYoTuu4oc6kLv582Gnh9tnFHvi4rSqcCHOb8O2w2kwl z4E9ACVlaiaX4DKfGPNxCTiJ/4RRCaHy3ADb26TiB0fjzT6iIj4CLGULbp5vFFWkD5xi O/rEwuUmjC5scMP7FuJx8mBidIkESIbllqvO45awVCZ+sxCPwBnCaawuBU0xj0VD6OKp ZW2XSiGhPeGQewcPMH7dK4X5/Bm9beez2d8QD1zD2J/iBmeoWTmqBoPKGyU4hl3Wy0oJ 9O2FYe/YPQoNLkqZKjm+3/DFzVVRSkMaolrxOGPiS9+f77CgZyhm4ZpGG3UQNXSEQBol 2Xbw== X-Gm-Message-State: AOAM531ki4ShbP1NQTb5X2IoQjtRlE0NebGfAhwFoiKXTP/3krshzdBW yCD3KynVnE4X2vfhgIlaAjQ= X-Received: by 2002:a17:90a:a81:: with SMTP id 1mr4229453pjw.165.1606404903469; Thu, 26 Nov 2020 07:35:03 -0800 (PST) Received: from localhost.localdomain ([182.226.226.37]) by smtp.googlemail.com with ESMTPSA id g6sm6506481pjd.3.2020.11.26.07.35.00 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 26 Nov 2020 07:35:02 -0800 (PST) From: bongsu.jeon2@gmail.com X-Google-Original-From: bongsu.jeon@samsung.com To: krzk@kernel.org, k.opasiak@samsung.com Cc: linux-nfc@lists.01.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Subject: [PATCH net-next 1/3] nfc: s3fwrn5: use signed integer for parsing GPIO numbers Date: Fri, 27 Nov 2020 00:33:37 +0900 Message-Id: <1606404819-30647-1-git-send-email-bongsu.jeon@samsung.com> X-Mailer: git-send-email 1.9.1 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Krzysztof Kozlowski GPIOs - as returned by of_get_named_gpio() and used by the gpiolib - are signed integers, where negative number indicates error. The return value of of_get_named_gpio() should not be assigned to an unsigned int because in case of !CONFIG_GPIOLIB such number would be a valid GPIO. Fixes: c04c674fadeb ("nfc: s3fwrn5: Add driver for Samsung S3FWRN5 NFC Chip") Cc: Signed-off-by: Krzysztof Kozlowski --- drivers/nfc/s3fwrn5/i2c.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/nfc/s3fwrn5/i2c.c b/drivers/nfc/s3fwrn5/i2c.c index 0ffa389..ae26594 100644 --- a/drivers/nfc/s3fwrn5/i2c.c +++ b/drivers/nfc/s3fwrn5/i2c.c @@ -25,8 +25,8 @@ struct s3fwrn5_i2c_phy { struct i2c_client *i2c_dev; struct nci_dev *ndev; - unsigned int gpio_en; - unsigned int gpio_fw_wake; + int gpio_en; + int gpio_fw_wake; struct mutex mutex; -- 1.9.1