From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 212F5C2BB3F for ; Thu, 16 Nov 2023 03:27:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1344863AbjKPD1S (ORCPT ); Wed, 15 Nov 2023 22:27:18 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46376 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235703AbjKPD1N (ORCPT ); Wed, 15 Nov 2023 22:27:13 -0500 Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.7]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9E636131 for ; Wed, 15 Nov 2023 19:27:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1700105231; x=1731641231; h=date:from:to:cc:subject:message-id:mime-version; bh=/0K1H045kyUOlj19cM6FNJrtLr6++RU8/Y3z42rgiCQ=; b=EZkYD7JsQrmVpjO9oTMOVghtNwPTrqji28klnEWfijtVi/SfnvDCqhdk GLE1GtnwShWS3+11c9bj95xNesDIkjKrroSL06kf2UTZHSQ2xBKT2LqTP V/DobfI5E5LYqH50lW7XgLKFx6x7ovDVjdKleJy8fNWk1DYN4DGL2C1ej 1cwUdadng8uayMhrdSbOsFMUuSSHUjX7cwqrBIN2Sc7lpnA80A6YBfyfE NxXuqU7wV2xKLxVPIkkYN5xZQ2+YkZu2LkCQmbny0nduq6YMMdTUKNg+e B8P8Z5KOslcoXY2Mm1mWjJr2DqEiKAXKtSQlQza5mHt5LhVZyM82fiIxG Q==; X-IronPort-AV: E=McAfee;i="6600,9927,10895"; a="12557784" X-IronPort-AV: E=Sophos;i="6.03,307,1694761200"; d="scan'208";a="12557784" Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmvoesa101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Nov 2023 19:27:10 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10895"; a="855853280" X-IronPort-AV: E=Sophos;i="6.03,307,1694761200"; d="scan'208";a="855853280" Received: from lkp-server02.sh.intel.com (HELO b8de5498638e) ([10.239.97.151]) by FMSMGA003.fm.intel.com with ESMTP; 15 Nov 2023 19:27:09 -0800 Received: from kbuild by b8de5498638e with local (Exim 4.96) (envelope-from ) id 1r3T22-0001Eo-2i; Thu, 16 Nov 2023 03:27:06 +0000 Date: Thu, 16 Nov 2023 11:26:12 +0800 From: kernel test robot To: Jens Axboe Cc: oe-kbuild-all@lists.linux.dev, linux-kernel@vger.kernel.org Subject: fs/splice.c:53:19: sparse: sparse: cast from restricted fmode_t Message-ID: <202311161151.kqFAHfLD-lkp@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: c42d9eeef8e5ba9292eda36fd8e3c11f35ee065c commit: 0f99fc513ddd28de155c58547824a9fd63daacea splice: clear FMODE_NOWAIT on file if splice/vmsplice is used date: 7 months ago config: sparc-randconfig-r021-20230427 (https://download.01.org/0day-ci/archive/20231116/202311161151.kqFAHfLD-lkp@intel.com/config) compiler: sparc-linux-gcc (GCC) 12.3.0 reproduce: (https://download.01.org/0day-ci/archive/20231116/202311161151.kqFAHfLD-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/202311161151.kqFAHfLD-lkp@intel.com/ sparse warnings: (new ones prefixed by >>) >> fs/splice.c:53:19: sparse: sparse: cast from restricted fmode_t >> fs/splice.c:53:19: sparse: sparse: cast from restricted fmode_t >> fs/splice.c:53:19: sparse: sparse: cast to restricted fmode_t fs/splice.c: note: in included file (through include/linux/mmzone.h, include/linux/gfp.h, include/linux/xarray.h, ...): include/linux/page-flags.h:246:46: sparse: sparse: self-comparison always evaluates to false vim +53 fs/splice.c 39 40 /* 41 * Splice doesn't support FMODE_NOWAIT. Since pipes may set this flag to 42 * indicate they support non-blocking reads or writes, we must clear it 43 * here if set to avoid blocking other users of this pipe if splice is 44 * being done on it. 45 */ 46 static noinline void noinline pipe_clear_nowait(struct file *file) 47 { 48 fmode_t fmode = READ_ONCE(file->f_mode); 49 50 do { 51 if (!(fmode & FMODE_NOWAIT)) 52 break; > 53 } while (!try_cmpxchg(&file->f_mode, &fmode, fmode & ~FMODE_NOWAIT)); 54 } 55 -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki