All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Dave Jiang <dave.jiang@intel.com>
Cc: oe-kbuild-all@lists.linux.dev
Subject: Re: [RFC PATCH 6/6] cxl: Add mce notifier to emit aliased address for extended linear cache
Date: Sat, 28 Sep 2024 09:18:45 +0800	[thread overview]
Message-ID: <202409280948.0QFDTcPb-lkp@intel.com> (raw)
In-Reply-To: <20240927142108.1156362-7-dave.jiang@intel.com>

Hi Dave,

[This is a private test report for your RFC patch.]
kernel test robot noticed the following build errors:

[auto build test ERROR on driver-core/driver-core-testing]
[also build test ERROR on driver-core/driver-core-next driver-core/driver-core-linus tip/x86/core tip/x86/mm v6.11]
[cannot apply to rafael-pm/linux-next rafael-pm/bleeding-edge cxl/next linus/master cxl/pending next-20240927]
[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/Dave-Jiang/ACPICA-actbl1-h-Add-extended-linear-address-mode-to-MSCIS/20240927-222421
base:   driver-core/driver-core-testing
patch link:    https://lore.kernel.org/r/20240927142108.1156362-7-dave.jiang%40intel.com
patch subject: [RFC PATCH 6/6] cxl: Add mce notifier to emit aliased address for extended linear cache
config: powerpc-allyesconfig (https://download.01.org/0day-ci/archive/20240928/202409280948.0QFDTcPb-lkp@intel.com/config)
compiler: clang version 20.0.0git (https://github.com/llvm/llvm-project 7773243d9916f98ba0ffce0c3a960e4aa9f03e81)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240928/202409280948.0QFDTcPb-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 <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202409280948.0QFDTcPb-lkp@intel.com/

All errors (new ones prefixed by >>):

   In file included from drivers/cxl/core/mbox.c:3:
   In file included from include/linux/security.h:33:
   In file included from include/linux/mm.h:2228:
   include/linux/vmstat.h:503:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion]
     503 |         return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
         |                            ~~~~~~~~~~~~~~~~~~~~~ ^
     504 |                            item];
         |                            ~~~~
   include/linux/vmstat.h:510:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion]
     510 |         return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
         |                            ~~~~~~~~~~~~~~~~~~~~~ ^
     511 |                            NR_VM_NUMA_EVENT_ITEMS +
         |                            ~~~~~~~~~~~~~~~~~~~~~~
   include/linux/vmstat.h:517:36: warning: arithmetic between different enumeration types ('enum node_stat_item' and 'enum lru_list') [-Wenum-enum-conversion]
     517 |         return node_stat_name(NR_LRU_BASE + lru) + 3; // skip "nr_"
         |                               ~~~~~~~~~~~ ^ ~~~
   include/linux/vmstat.h:523:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion]
     523 |         return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
         |                            ~~~~~~~~~~~~~~~~~~~~~ ^
     524 |                            NR_VM_NUMA_EVENT_ITEMS +
         |                            ~~~~~~~~~~~~~~~~~~~~~~
>> drivers/cxl/core/mbox.c:1461:15: error: call to undeclared function 'mce_usable_address'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
    1461 |         if (!mce || !mce_usable_address(mce))
         |                      ^
>> drivers/cxl/core/mbox.c:1464:11: error: incomplete definition of type 'struct mce'
    1464 |         spa = mce->addr & MCI_ADDR_PHYSADDR;
         |               ~~~^
   drivers/cxl/core/mbox.c:1457:9: note: forward declaration of 'struct mce'
    1457 |         struct mce *mce = (struct mce *)data;
         |                ^
>> drivers/cxl/core/mbox.c:1464:20: error: use of undeclared identifier 'MCI_ADDR_PHYSADDR'
    1464 |         spa = mce->addr & MCI_ADDR_PHYSADDR;
         |                           ^
>> drivers/cxl/core/mbox.c:1508:31: error: use of undeclared identifier 'MCE_PRIO_CXL'
    1508 |         mds->mce_notifier.priority = MCE_PRIO_CXL;
         |                                      ^
>> drivers/cxl/core/mbox.c:1509:2: error: call to undeclared function 'mce_register_decode_chain'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
    1509 |         mce_register_decode_chain(&mds->mce_notifier);
         |         ^
   4 warnings and 5 errors generated.


vim +/mce_usable_address +1461 drivers/cxl/core/mbox.c

  1449	
  1450	static int cxl_handle_mce(struct notifier_block *nb, unsigned long val,
  1451				  void *data)
  1452	{
  1453		struct cxl_memdev_state *mds = container_of(nb, struct cxl_memdev_state,
  1454							    mce_notifier);
  1455		struct cxl_memdev *cxlmd = mds->cxlds.cxlmd;
  1456		struct cxl_port *endpoint = cxlmd->endpoint;
  1457		struct mce *mce = (struct mce *)data;
  1458		u64 spa, spa_alias;
  1459		unsigned long pfn;
  1460	
> 1461		if (!mce || !mce_usable_address(mce))
  1462			return NOTIFY_DONE;
  1463	
> 1464		spa = mce->addr & MCI_ADDR_PHYSADDR;
  1465	
  1466		pfn = spa >> PAGE_SHIFT;
  1467		if (!pfn_valid(pfn))
  1468			return NOTIFY_DONE;
  1469	
  1470		spa_alias = cxl_port_get_spa_cache_alias(endpoint, spa);
  1471		if (!spa_alias)
  1472			return NOTIFY_DONE;
  1473	
  1474		pfn = spa_alias >> PAGE_SHIFT;
  1475	
  1476		/*
  1477		 * Take down the aliased memory page. The original memory page flagged
  1478		 * by the MCE will be taken cared of by the standard MCE handler.
  1479		 */
  1480		dev_emerg(mds->cxlds.dev, "Offlining aliased SPA address: %#llx\n",
  1481			  spa_alias);
  1482		if (!memory_failure(pfn, 0))
  1483			set_mce_nospec(pfn);
  1484	
  1485		return NOTIFY_OK;
  1486	}
  1487	
  1488	struct cxl_memdev_state *cxl_memdev_state_create(struct device *dev)
  1489	{
  1490		struct cxl_memdev_state *mds;
  1491	
  1492		mds = devm_kzalloc(dev, sizeof(*mds), GFP_KERNEL);
  1493		if (!mds) {
  1494			dev_err(dev, "No memory available\n");
  1495			return ERR_PTR(-ENOMEM);
  1496		}
  1497	
  1498		mutex_init(&mds->mbox_mutex);
  1499		mutex_init(&mds->event.log_lock);
  1500		mds->cxlds.dev = dev;
  1501		mds->cxlds.reg_map.host = dev;
  1502		mds->cxlds.reg_map.resource = CXL_RESOURCE_NONE;
  1503		mds->cxlds.type = CXL_DEVTYPE_CLASSMEM;
  1504		mds->ram_perf.qos_class = CXL_QOS_CLASS_INVALID;
  1505		mds->pmem_perf.qos_class = CXL_QOS_CLASS_INVALID;
  1506	
  1507		mds->mce_notifier.notifier_call = cxl_handle_mce;
> 1508		mds->mce_notifier.priority = MCE_PRIO_CXL;
> 1509		mce_register_decode_chain(&mds->mce_notifier);
  1510	
  1511		return mds;
  1512	}
  1513	EXPORT_SYMBOL_NS_GPL(cxl_memdev_state_create, CXL);
  1514	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

  parent reply	other threads:[~2024-09-28  1:18 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-27 14:16 [RFC PATCH 0/6] acpi/hmat / cxl: Add exclusive caching enumeration and RAS support Dave Jiang
2024-09-27 14:16 ` [RFC PATCH 1/6] ACPICA: actbl1.h: Add extended linear address mode to MSCIS Dave Jiang
2024-10-02 17:57   ` Rafael J. Wysocki
2024-09-27 14:16 ` [RFC PATCH 2/6] acpi: numa: Add support to enumerate and store extended linear address mode Dave Jiang
2024-10-17 16:00   ` Jonathan Cameron
2024-10-29 21:01     ` Dave Jiang
2024-09-27 14:16 ` [RFC PATCH 3/6] acpi/hmat / cxl: Add extended linear cache support for CXL Dave Jiang
2024-09-28  1:08   ` kernel test robot
2024-10-17 16:20   ` Jonathan Cameron
2024-10-29 22:04     ` Dave Jiang
2024-09-27 14:16 ` [RFC PATCH 4/6] acpi/hmat: Add helper functions to provide extended linear cache translation Dave Jiang
2024-10-17 16:33   ` Jonathan Cameron
2024-10-17 16:46     ` Luck, Tony
2024-10-17 16:59       ` Jonathan Cameron
2024-10-29 22:51         ` Dave Jiang
2024-10-30 22:53     ` Dave Jiang
2024-11-01 11:56       ` Jonathan Cameron
2024-09-27 14:16 ` [RFC PATCH 5/6] cxl: Add extended linear cache address alias emission for cxl events Dave Jiang
2024-10-17 16:38   ` Jonathan Cameron
2024-10-30 23:29     ` Dave Jiang
2024-09-27 14:16 ` [RFC PATCH 6/6] cxl: Add mce notifier to emit aliased address for extended linear cache Dave Jiang
2024-09-28  1:08   ` kernel test robot
2024-09-28  1:18   ` kernel test robot [this message]
2024-10-17 16:40   ` Jonathan Cameron
2024-10-30 23:37     ` Dave Jiang
2024-10-31 21:12       ` Dave Jiang
2024-10-17 16:46 ` [RFC PATCH 0/6] acpi/hmat / cxl: Add exclusive caching enumeration and RAS support Jonathan Cameron
2024-10-29 22:55   ` Dave Jiang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202409280948.0QFDTcPb-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=dave.jiang@intel.com \
    --cc=oe-kbuild-all@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.