Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp519453imu; Fri, 9 Nov 2018 01:24:21 -0800 (PST) X-Google-Smtp-Source: AJdET5ccDGK6l/9VQbIk17i0/GUgI22NOVMcHC4QY2AVTwzyY8nU6VU9EvQQ1yDhsaVfaiPbpakq X-Received: by 2002:a17:902:d806:: with SMTP id a6-v6mr7804631plz.301.1541755461543; Fri, 09 Nov 2018 01:24:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541755461; cv=none; d=google.com; s=arc-20160816; b=cjD0zUX+IuwU8q9FPv9Lc0KX/XjTyEvx3mPnJ7EqbYmXe4YWMdCLLZXzPMVJzzTIRz z/jk7Tsr7YGCP6zCfWw9SUZtD/tMUftHO1pnXpYcJCZlSF7RM6IarCUc0Y3Mf3YViL3W sW9Jn90LHfDYEteirGzL6uoAdCGOt0PSXHRkuUkTv15EJicuhdAZrkFsGc9tbM26Uh2/ 1PVBYlvjecjEcAn53x1K9mwY5la/gxNST5lfB7xuxgwEzb5JZT0mZGVA+03+x6MJcnVs 916VQxbLHKSdAwkDqSvle3AvHLYbv4UVbZ4Owpk4WaKWV9OpVWf3etqQlXtVIkfVROg2 WY1w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=ThCZt9zVWkwqGt7TEPGWG2j1KJOMyCrcKrGwBQNDiY0=; b=cu2/ZJ10en47RmLa7EWfSi39/F91fsdx5apcWbM0DpUCIoTYiskPQsiDGUnwq4sGQY 2kC/lTiFNdC/P5UBImkJ/L76YySXIyonMHAKuhd8885VloV0lEkcC7spbkY1QZDm/lqh kAZ3B7QLdjMHJH+2wswMkABs+E1cgi5jCyve09v13PyMrjxmnDUQRKjGB6X4ZPT4Svue eqn+3L0X1HFp2I1divMOFrtRuVum59GX5EabZv15alnVvZyaWTF3R8mBXfcL6vky9IUR SAFYaiAIU/u44MCvzWG84dNU8qvqIgkQkMH4zakt0mZ0Bnt71DRF//GmGw3xowv5eaa8 gBQw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hCBdIZr9; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b14si6730014pgj.20.2018.11.09.01.24.05; Fri, 09 Nov 2018 01:24:21 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hCBdIZr9; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728081AbeKITDH (ORCPT + 99 others); Fri, 9 Nov 2018 14:03:07 -0500 Received: from mail-lj1-f196.google.com ([209.85.208.196]:40447 "EHLO mail-lj1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728031AbeKITDH (ORCPT ); Fri, 9 Nov 2018 14:03:07 -0500 Received: by mail-lj1-f196.google.com with SMTP id t22-v6so983912lji.7 for ; Fri, 09 Nov 2018 01:23:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=ThCZt9zVWkwqGt7TEPGWG2j1KJOMyCrcKrGwBQNDiY0=; b=hCBdIZr9MfvSwAmFlCJwVHu/kBr5QKWCYSFUsHkfT2F5AJL+BBGV7opJBpd5pxw29u ZaGIpYN5maWZUHt+ZyWiZEWwcpLGOpG2JUD/UvQaOPTkqi1Bjq1rXp6N7Ja5J27+Hg4u fBpzuH28ro6VO2H/Wtis3KrCAQu627k3byuEc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=ThCZt9zVWkwqGt7TEPGWG2j1KJOMyCrcKrGwBQNDiY0=; b=rP1Pnct5Fhd/jiEex/KA5ILoT0T4NJDDiwl50WrE8ddRheWksjwiV7UpFrf63Yi7+r njIK9u9kYA5JNcwk6REmU45ma49SwHC4dSICZcvjSyfqMc31vbqQQN1wy7fPE8t3WzMB wuV2oPiqzxB5W19c5v3+Zt2eadOoH0sy9UVLRF/mI2G5Kbw0QWQ1ajL9yvw775+eqGKD OfZrbtCfAKi6HCQ4K4oRgjJzUOryd+Ps31azd8oyE473JANuL63Vg7HwEYznbmxSSwkR ZPfoDuL5GsUwSV2TvpL3JM+7mlC6791gBtvLQQxq0BU93jRTp8bCHn/7OFMnS3SDeQzF Imlw== X-Gm-Message-State: AGRZ1gKwlQFrvCz4UaSvfBehtmm88iCBhHEZ3IPsrselqIf7O74BGyCe aam2HPZw0FXURPme/B5n6ISL9VfadUa7Dhxu/TBGCA== X-Received: by 2002:a2e:874e:: with SMTP id q14-v6mr4516938ljj.120.1541755404763; Fri, 09 Nov 2018 01:23:24 -0800 (PST) MIME-Version: 1.0 References: <20181101004653.7552-1-natechancellor@gmail.com> In-Reply-To: <20181101004653.7552-1-natechancellor@gmail.com> From: Linus Walleij Date: Fri, 9 Nov 2018 10:23:13 +0100 Message-ID: Subject: Re: [PATCH] pinctrl: bcm2835: Use define directive for BCM2835_PINCONF_PARAM_PULL To: Nathan Chancellor Cc: Eric Anholt , Stefan Wahren , Florian Fainelli , Ray Jui , Scott Branden , bcm-kernel-feedback-list@broadcom.com, "open list:GPIO SUBSYSTEM" , linux-rpi-kernel , Linux ARM , "linux-kernel@vger.kernel.org" , Nick Desaulniers Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Nov 1, 2018 at 1:47 AM Nathan Chancellor wrote: > Clang warns when one enumerated type is implicitly converted to another: > > drivers/pinctrl/bcm/pinctrl-bcm2835.c:707:40: warning: implicit > conversion from enumeration type 'enum bcm2835_pinconf_param' to > different enumeration type 'enum pin_config_param' [-Wenum-conversion] > configs[0] = pinconf_to_config_packed(BCM2835_PINCONF_PARAM_PULL, pull); > ~~~~~~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~ > 1 warning generated. > > It is expected that pinctrl drivers can extend pin_config_param because > of the gap between PIN_CONFIG_END and PIN_CONFIG_MAX so this conversion > isn't an issue. Most drivers that take advantage of this define the > PIN_CONFIG variables as constants, rather than enumerated values. Do the > same thing here so that Clang no longer warns. > > Signed-off-by: Nathan Chancellor Patch applied with Stefan's ACK. Yours, Linus Walleij