Received: by 2002:a05:7412:31a9:b0:e2:908c:2ebd with SMTP id et41csp3495360rdb; Wed, 13 Sep 2023 13:58:23 -0700 (PDT) X-Google-Smtp-Source: AGHT+IE58BDkXpGEgCehKYQuzX+YdmVzmQfhMPoYtPEybw2OXLZ0PV8sjnYoqMJmbff+hCjoa1sT X-Received: by 2002:a17:90a:e003:b0:26d:416a:b027 with SMTP id u3-20020a17090ae00300b0026d416ab027mr3509727pjy.31.1694638702720; Wed, 13 Sep 2023 13:58:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1694638702; cv=none; d=google.com; s=arc-20160816; b=k8s6VPkANErxGTHzXXVpCQijsEcjFsjsiIFJ0W91OKE67rGe8ke+ZZrfhgLybQqZqr f4zjHCm0NDjl0xA3vGr0j7By1x4XBaXfBtON2ZodKbRJuiB0mpNhE4D9z+brfsB12aSs pX1lRCHF8dLDzpVOL9g43MQJVQAQzXxK+3vcjwNNApODuYGUWqSon4aLr3vDKD0v0Bk8 7n6ktxaQh9m6VrYIFmmyedSM2cbP1mEeQAasV8AGJpsMNkckbaTDrcWgTnsNNhU/rMPR 4EurUpWROeFYlk5516szHe84zPXRH+dMI7DjZ2BL15ifoxEyBTP9D2dX3A4b1GP/4Gk1 7eqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=S23CEnMeJdTaF1wh/8Xtb3VuYAITdQdPBuxYkl3lkBw=; fh=dIJ0fwgK9+3oGkKZ9OMClFaNDznDPhuZugwfjzXqD2A=; b=sIy1LzYIhnQGJEUKSrwnko27Kt+hmc0mCJA762fGTQCj2gOY/jp4Qh8zGQZs2Mq1Rz dnyYYgjKYF2honLEdG+f32zwrcyasL4FaE38MBuAd1bVvE8NIjnmE0YfssdCQXiNy61U qbm+OxDgkiy8ICuEveISzkCjNmzN4HHaqx0CPROsKQfsdI4OTtMUQqBK/Ey/HVms+4p3 XnGGcH6VSr9Y84aM608scj2Kht8TdWk+rch0RLnYKTyd3JXDJW7q0RA88x8Blo/+yW4B 2ffkG+Ev395IMcmXZW77qpkBhug8ykkW7ztNae+8EPDrrPlPOj0M+C1KVnLt8jHMtHO8 M04w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=JbNIquAj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id rm9-20020a17090b3ec900b00267b910cb37si125134pjb.52.2023.09.13.13.58.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Sep 2023 13:58:22 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=JbNIquAj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id A55E980417D8; Wed, 13 Sep 2023 07:43:51 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241398AbjIMOnu (ORCPT + 99 others); Wed, 13 Sep 2023 10:43:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36950 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232390AbjIMOnt (ORCPT ); Wed, 13 Sep 2023 10:43:49 -0400 Received: from madras.collabora.co.uk (madras.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e5ab]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4A85591 for ; Wed, 13 Sep 2023 07:43:45 -0700 (PDT) Received: from mercury (dyndsl-091-248-208-175.ewe-ip-backbone.de [91.248.208.175]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: sre) by madras.collabora.co.uk (Postfix) with ESMTPSA id B6AAC6607341; Wed, 13 Sep 2023 15:43:43 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1694616223; bh=45c5gw/f2jBbyJLhmpXqI2WamtRnBzbETao/nifAbys=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=JbNIquAj9HcChNrpbB3TnOOJK8C+DH65aCaaEYo+Cwknu6g9wyUu4UcEPx9pKvrhe PZQZkm03AsVscnb5msvheRmMHLaxu813A/+LEWCzsEsDWwaf/JSU6OPiWyiJ0Xc5AE FmIWXAK22CVO0g/YX5k1lsaj5YVWen4fZUOAlqrT42gOhcz1ENVowuntOfISNRFTpq C+xGan02w+ZdhL9GyTKqqzlR5EDgSCA0zoEzUEM9nZDCChwFhRLeQPCeisTIKbKuon mut2P2FJGvF9VidzNYES3J9gQy3+jhGRDNCAE00y+f4J8idGP/WvDf5hJ6w/07FmGx 6k5TrUUmvoMnQ== Received: by mercury (Postfix, from userid 1000) id D2377106098A; Wed, 13 Sep 2023 16:43:40 +0200 (CEST) Date: Wed, 13 Sep 2023 16:43:40 +0200 From: Sebastian Reichel To: Bjorn Andersson Cc: oe-kbuild-all@lists.linux.dev, linux-kernel@vger.kernel.org, Neil Armstrong Subject: Re: drivers/power/supply/qcom_battmgr.c:357:31: sparse: sparse: incorrect type in initializer (different base types) Message-ID: <20230913144340.l2vg6wtq56lnzejn@mercury.elektranox.org> References: <202308280602.nE6xa80J-lkp@intel.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="kg7dkqg6i3kdnmsn" Content-Disposition: inline In-Reply-To: <202308280602.nE6xa80J-lkp@intel.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Wed, 13 Sep 2023 07:43:51 -0700 (PDT) X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email --kg7dkqg6i3kdnmsn Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi Bjorn, On Mon, Aug 28, 2023 at 06:19:22AM +0800, kernel test robot wrote: > tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.gi= t master > head: 85eb043618bb17124050197d71c453d4a1f556e5 > commit: 29e8142b5623b5949587bcc4f591c4e6595c4aca power: supply: Introduce= Qualcomm PMIC GLINK power supply > date: 7 months ago > config: i386-randconfig-061-20230828 (https://download.01.org/0day-ci/arc= hive/20230828/202308280602.nE6xa80J-lkp@intel.com/config) > compiler: gcc-12 (Debian 12.2.0-14) 12.2.0 > reproduce: (https://download.01.org/0day-ci/archive/20230828/202308280602= =2EnE6xa80J-lkp@intel.com/reproduce) >=20 > If you fix the issue in a separate patch/commit (i.e. not just a new vers= ion of > the same patch/commit), kindly add following tags > | Reported-by: kernel test robot > | Closes: https://lore.kernel.org/oe-kbuild-all/202308280602.nE6xa80J-lkp= @intel.com/ >=20 > sparse warnings: (new ones prefixed by >>) > >> drivers/power/supply/qcom_battmgr.c:357:31: sparse: sparse: incorrect = type in initializer (different base types) @@ expected unsigned int [us= ertype] battery_id @@ got restricted __le32 [usertype] @@ > drivers/power/supply/qcom_battmgr.c:357:31: sparse: expected unsig= ned int [usertype] battery_id > drivers/power/supply/qcom_battmgr.c:357:31: sparse: got restricted= __le32 [usertype] > drivers/power/supply/qcom_battmgr.c:369:31: sparse: sparse: incorrect = type in initializer (different base types) @@ expected unsigned int [us= ertype] battery_id @@ got restricted __le32 [usertype] @@ > drivers/power/supply/qcom_battmgr.c:369:31: sparse: expected unsig= ned int [usertype] battery_id > drivers/power/supply/qcom_battmgr.c:369:31: sparse: got restricted= __le32 [usertype] > >> drivers/power/supply/qcom_battmgr.c:1286:30: sparse: sparse: incorrect= type in initializer (different base types) @@ expected restricted __le= 32 [usertype] owner @@ got int @@ > drivers/power/supply/qcom_battmgr.c:1286:30: sparse: expected rest= ricted __le32 [usertype] owner > drivers/power/supply/qcom_battmgr.c:1286:30: sparse: got int > >> drivers/power/supply/qcom_battmgr.c:1287:29: sparse: sparse: incorrect= type in initializer (different base types) @@ expected restricted __le= 32 [usertype] type @@ got int @@ > drivers/power/supply/qcom_battmgr.c:1287:29: sparse: expected rest= ricted __le32 [usertype] type > drivers/power/supply/qcom_battmgr.c:1287:29: sparse: got int > >> drivers/power/supply/qcom_battmgr.c:1288:31: sparse: sparse: incorrect= type in initializer (different base types) @@ expected restricted __le= 32 [usertype] opcode @@ got int @@ > drivers/power/supply/qcom_battmgr.c:1288:31: sparse: expected rest= ricted __le32 [usertype] opcode > drivers/power/supply/qcom_battmgr.c:1288:31: sparse: got int >=20 > vim +357 drivers/power/supply/qcom_battmgr.c >=20 > 350=09 > 351 static int qcom_battmgr_update_status(struct qcom_battmgr *battmgr) > 352 { > 353 struct qcom_battmgr_update_request request =3D { > 354 .hdr.owner =3D cpu_to_le32(PMIC_GLINK_OWNER_BATTMGR), > 355 .hdr.type =3D cpu_to_le32(PMIC_GLINK_REQ_RESP), > 356 .hdr.opcode =3D cpu_to_le32(BATTMGR_BAT_STATUS), > > 357 .battery_id =3D cpu_to_le32(0), > 358 }; > 359=09 > 360 return qcom_battmgr_request(battmgr, &request, sizeof(request)); > 361 } > 362=09 It looks like battery_id should be __le32 in 'struct qcom_battmgr_update_request', care to send a patch for that? Greetings, -- Sebastian --kg7dkqg6i3kdnmsn Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIyBAABCgAdFiEE72YNB0Y/i3JqeVQT2O7X88g7+poFAmUBypYACgkQ2O7X88g7 +pq/rw/3SEKux/ZBackYrIw9y9Z/kn115vH7rfdk3/pfhpgjpVVGENZso9k+tHE5 lj6/Fu6Dbe2e0qQWYEDSxRrMVvSrJsEKYdt9j+s9r+0DseOJQkzXIIq3LNzLrN5F t3Cntgfn5XZiA0RaIEuRQAZSTcU37bYVc5F/JQ3WmENF39dfFSS7EQJvSZSxJ5RR 6ET1iKroiMbxnFvM1UDDxyMgl0tr66e85es4zm4V2D4F/LwHmsprfgTfLtQs7izT l8NkyKy2MYbe0TsVT5ombTwsaXcg8A03jgb3m32gI6Z5MUzcVFw9Ke+uWRHgVCF6 7f+hoRjk3bhdgex0g+XjLRO3AeuIoNo9JGhbezTaOJClSu6Ew7vw7Z6N4y5df4e3 XoruytZrG/Ck4cLJ4ypgHcKzLBk2bSF8/h/IBls484pX4XAm1PuPGWQuObNII45S SEz1/6vSRs4KlCeJMcx7JT0IrTCdK5d78UHLk3T2fdK7afH8blL+PoDLDqLZQOhf WADrZ6mTE0xR7UtQhp+Q43Ra4eWRSbL1+HzydaPuFjFFtZdpg+PorQYXNA/UcgeH j8i/fRqqoLfB/GlCI2ihh6W0zX/nXFv9hz1cjReu/Ldma/6Vw4zwn+tHCD/4LEN8 A1FOp6px43ciBsvYSxiUfUBrl9UQAvtkpMPjSbOjiXz4plQbJg== =xOI2 -----END PGP SIGNATURE----- --kg7dkqg6i3kdnmsn--