From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.9]) (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 AE73A32C8B for ; Tue, 10 Feb 2026 14:45:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.175.65.9 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770734720; cv=none; b=sAdS5Z8GB56lr4HcgHxj4p0fwAKk5WYZ/bKJKtE3mtSfRFwefIRVNyLidI2bGI+3kSfwy7NZm0qglgtp2fJBIbsSvA7qa6RNwKWhJZIFZPcdr+m5ONkv0l5MAeTPH+T0S1O+aGceHZ2qxd+Gj0opFRD6hYhZ6cR7sP4MY6l7x2o= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770734720; c=relaxed/simple; bh=Yltjel1XmY4Ww8KkB64cnTsT+2R71mBZ+oug87haKX8=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=ChcgbKOSpZset8kyY7N+2e+SFxr7HqXDnYwwOzR9p8Npi76nUJFyXPKVQsndHlH5z5egyZ+5CV/6KWUDJOO0G9+rjv77GOQA2Kn5ZxaUFaNcpIATpWp1SKjG5n0xKgrp89PNkInNPqm1QTXdCE5biureOdm6MwgFPyVzWfvlbAU= 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=G+JHGphj; arc=none smtp.client-ip=198.175.65.9 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="G+JHGphj" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1770734719; x=1802270719; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=Yltjel1XmY4Ww8KkB64cnTsT+2R71mBZ+oug87haKX8=; b=G+JHGphjlUezAGl7K6o/AjamKQcSsyhLGseBSSbXUbAzvMJ7B0r5LBVS kngCyuiw+xFIsPNkID9UiBEISoZagCRDHcbZJ1expMmpg/XSnngVpxDM3 qT6xY8IRcKLVI63y8tbwzLc8JUZfCIGGbhrKkTOkXqPFByYra6ASW5H4F /IrPnhGU/SS7HtMBLNidPp6PmW++0FCr9WVFNdR8yc/7Du7vTbg2iUCIj kd3Fx7Vq9Iux/Jc07lhBrbJmH2a2MnzIL38rl50sfpnbHlGTUxVI7vc3T gAmBkYC7e2TypCiJdq/e1TqdjfRVG1InBAYvv+9Jlo0k8Jy6Q2Kbe3PtT A==; X-CSE-ConnectionGUID: H7QAI+1LSW65as5uzENi0A== X-CSE-MsgGUID: BLjdyte6SIKISyTZoTwQXQ== X-IronPort-AV: E=McAfee;i="6800,10657,11697"; a="94506236" X-IronPort-AV: E=Sophos;i="6.21,283,1763452800"; d="scan'208";a="94506236" Received: from orviesa001.jf.intel.com ([10.64.159.141]) by orvoesa101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 10 Feb 2026 06:45:19 -0800 X-CSE-ConnectionGUID: aSxYArWMRgqYsYncyDnQ4g== X-CSE-MsgGUID: eLGGViCFTSCpAy3KCVuVrQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.21,283,1763452800"; d="scan'208";a="249583389" Received: from egrumbac-mobl6.ger.corp.intel.com (HELO localhost) ([10.245.244.39]) by smtpauth.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 10 Feb 2026 06:45:18 -0800 Date: Tue, 10 Feb 2026 16:45:15 +0200 From: Andy Shevchenko To: Vignesh Raghavendra Cc: linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org, Miquel Raynal , Richard Weinberger Subject: Re: [PATCH v2 1/1] mtd: cfi_cmdset_0001: Factor out do_write_buffer_locked() to reduce stack frame Message-ID: References: <20260124133730.3454241-1-andriy.shevchenko@linux.intel.com> <202601250653.LXBUL5W6-lkp@intel.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline 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, Feb 10, 2026 at 03:35:39PM +0530, Vignesh Raghavendra wrote: > On 25/01/26 04:11, kernel test robot wrote: > > kernel test robot noticed the following build warnings: > > > > [auto build test WARNING on mtd/mtd/next] > > [also build test WARNING on mtd/mtd/fixes linus/master v6.19-rc6 next-20260123] > > [If your patch is applied to the wrong git tree, kindly drop us a note. > > And when submitting patch, we suggest to use '--base' as documented in > > https://git-scm.com/docs/git-format-patch#_base_tree_information] > > > > url: https://github.com/intel-lab-lkp/linux/commits/Andy-Shevchenko/mtd-cfi_cmdset_0001-Factor-out-do_write_buffer_locked-to-reduce-stack-frame/20260124-213936 > > base: https://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git mtd/next > > patch link: https://lore.kernel.org/r/20260124133730.3454241-1-andriy.shevchenko%40linux.intel.com > > patch subject: [PATCH v2 1/1] mtd: cfi_cmdset_0001: Factor out do_write_buffer_locked() to reduce stack frame > > config: xtensa-randconfig-002-20260125 (https://download.01.org/0day-ci/archive/20260125/202601250653.LXBUL5W6-lkp@intel.com/config) > > compiler: xtensa-linux-gcc (GCC) 8.5.0 > > reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260125/202601250653.LXBUL5W6-lkp@intel.com/reproduce) > > > > If you fix the issue in a separate patch/commit (i.e. not just a new version of > > the same patch/commit), kindly add following tags > > | Reported-by: kernel test robot > > | Closes: https://lore.kernel.org/oe-kbuild-all/202601250653.LXBUL5W6-lkp@intel.com/ > > > > All warnings (new ones prefixed by >>): > > > > drivers/mtd/chips/cfi_cmdset_0001.c: In function 'do_write_buffer_locked': > >>> drivers/mtd/chips/cfi_cmdset_0001.c:1734:6: warning: unused variable 'initial_len' [-Wunused-variable] > > int initial_len = len; > > ^~~~~~~~~~~ > >>> drivers/mtd/chips/cfi_cmdset_0001.c:1733:16: warning: variable 'initial_adr' set but not used [-Wunused-but-set-variable] > > unsigned long initial_adr; > > ^~~~~~~~~~~ > > Copying my response here again from [1] , as this LKP report seems to on a > different thread: Thanks! I will look at this after -rc1 is out. Maybe earlier, but quite busy with other issue(s). > Things become tricky with CONFIG_MTD_XIP enabled. With > XIP_INVAL_CACHED_RANGE() moved to caller, initial_adr becomes unused > when CONFIG_MTD_XIP=y > > One solution maybe to move calls to XIP_INVAL_CACHED_RANGE(), > ENABLE_VPP(map) and xip_disable() and their complementary functions to > do_write_buffer_locked() as these calls need to repeated for every > writes (if and when we find need to reuse do_write_buffer_locked()) > > Alternately move INVAL_CACHE_AND_WAIT() and everything after that to > caller [...] > [1] https://lore.kernel.org/all/4d4ab8af-3e09-4e48-a79d-0af3453600c3@ti.com/ -- With Best Regards, Andy Shevchenko