From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.10]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5E634331A71; Tue, 27 Jan 2026 09:14:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=192.198.163.10 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769505274; cv=none; b=SnmYj79KTVYolvFAU0qxxs3YUpvvRi7yfn7sEEH/X5NLXkgHtuac9vFNXiKPStqXZgCuvB/qt2aFIv+3XiEAuSREwFqbiOe/OWDUZGU3ZCmamREF3fixH+RWampltJ5Zd+QpTJTgq1bO54WBt0lBvVwZYs6yA0R6KADy+LOl7qQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769505274; c=relaxed/simple; bh=wA5rbgiEwVVcceiEGmwj1C3uIIzfloDmcPxun/ZMq80=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=GmseuPylGvAwd7Tv1S+YJlZubjYpccMlwpq6r207YFOi876Wn8yarMRDPZaXGVrT/w6w/OcdYchU0UjtPBRnIm5/Gtc45B2VradDqG2DR4uiDd3r/2h6KFGKndYARocY6H+/hh8iqgHS9cqr3IbLWFDQGJuil9bnBzInkP2T9ZQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com; spf=pass smtp.mailfrom=linux.intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=lu6LiKLz; arc=none smtp.client-ip=192.198.163.10 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="lu6LiKLz" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1769505273; x=1801041273; h=date:from:to:cc:subject:message-id:references: mime-version:content-transfer-encoding:in-reply-to; bh=wA5rbgiEwVVcceiEGmwj1C3uIIzfloDmcPxun/ZMq80=; b=lu6LiKLz2FAqdJ8qRl8wGNMUmYzx8bwBFUhk48E2vFPNdj/AjQaZKOdv DNFupMFM9aM/isHPI67ADsKYw8B+M572J7Q5Jbx2Ts3klNn1trI55hblG dRezsan8xCXjQuJMeRU58uzaz0/fp00Y3Px8Zc3w6t7w/8bvrbve/BYC2 oSc39rLMtYm7yp18Vc7kj7pR3mSPA3obE3mik8jeaYf/YqIP/krpTpTE6 VTY7MgDnKv05CyP2t1cxU7hpxbopJEf8BfUXV8ztPqK4SonvYx+sfkZkS kHOwK62BRKhbB0cMsRuhuffpdZe6BjLCx9laiakUlUfMerVzlD10oNutr Q==; X-CSE-ConnectionGUID: GCvdEQlTQvy4+YLMOYZF5A== X-CSE-MsgGUID: KKrWwR68RK+OrnIa6aQ96Q== X-IronPort-AV: E=McAfee;i="6800,10657,11683"; a="82063815" X-IronPort-AV: E=Sophos;i="6.21,256,1763452800"; d="scan'208";a="82063815" Received: from orviesa006.jf.intel.com ([10.64.159.146]) by fmvoesa104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 Jan 2026 01:14:33 -0800 X-CSE-ConnectionGUID: eZ8T0zA0QuOuSlCk9I6C5g== X-CSE-MsgGUID: edZl9nkTR1mG1M50Et7Lhg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.21,256,1763452800"; d="scan'208";a="207048789" Received: from egrumbac-mobl6.ger.corp.intel.com (HELO localhost) ([10.245.245.248]) by orviesa006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 Jan 2026 01:14:30 -0800 Date: Tue, 27 Jan 2026 11:14:27 +0200 From: Andy Shevchenko To: Bartosz Golaszewski Cc: Mika Westerberg , Denis Sergeev , westeri@kernel.org, linusw@kernel.org, linux-gpio@vger.kernel.org, linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org, lvc-project@linuxtesting.org Subject: Re: [PATCH] gpiolib: acpi: use BIT_ULL() for u64 mask in address space handler Message-ID: References: <20260126035914.16586-1-denserg.edu@gmail.com> <20260127080759.GY2275908@black.igk.intel.com> Precedence: bulk X-Mailing-List: linux-gpio@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: Organization: Intel Finland Oy - BIC 0357606-4 - c/o Alberga Business Park, 6 krs, Bertel Jungin Aukio 5, 02600 Espoo On Tue, Jan 27, 2026 at 10:06:33AM +0100, Bartosz Golaszewski wrote: > On Tue, Jan 27, 2026 at 9:08 AM Mika Westerberg > wrote: > > > > On Mon, Jan 26, 2026 at 06:59:14AM +0300, Denis Sergeev wrote: > > > The BIT() macro uses unsigned long, which is 32 bits on 32-bit > > > architectures. When iterating over GPIO pins with index >= 32, > > > the expression (*value & BIT(i)) causes undefined behavior due > > > to shifting by a value >= type width. > > > > > > Since 'value' is a pointer to u64, use BIT_ULL() to ensure correct > > > 64-bit mask on all architectures. > > > > > > Found by Linux Verification Center (linuxtesting.org) with Svace. > > > > > > Fixes: 2c4d00cb8fc5 ("gpiolib: acpi: Use BIT() macro to increase readability") > > > Signed-off-by: Denis Sergeev > > > > Reviewed-by: Mika Westerberg > > I'll queue this for v6.19-rc8. This is half-baked solution... But okay, let's shut up at least the stream of this type of "fixes" in this file. -- With Best Regards, Andy Shevchenko