public inbox for linux-next@vger.kernel.org 
 help / color / mirror / Atom feed
From: Dan Williams <dan.j.williams@intel•com>
To: Stephen Rothwell <sfr@canb•auug.org.au>,
	Dan Williams <dan.j.williams@intel•com>
Cc: Dave Jiang <dave.jiang@intel•com>,
	Linux Kernel Mailing List <linux-kernel@vger•kernel.org>,
	Linux Next Mailing List <linux-next@vger•kernel.org>
Subject: RE: linux-next: build failure after merge of the cxl tree
Date: Fri, 5 Jan 2024 19:23:47 -0800	[thread overview]
Message-ID: <6598c7c3db0fb_127da2294a6@dwillia2-xfh.jf.intel.com.notmuch> (raw)
In-Reply-To: <20240105161709.22d1b027@canb.auug.org.au>

Stephen Rothwell wrote:
> Hi all,
> 
> After merging the cxl tree, today's linux-next build (x86_64 allmodconfig)
> failed like this:
> 
> drivers/cxl/core/cdat.c: In function 'match_cxlrd_hb':
> drivers/cxl/core/cdat.c:327:43: error: 'struct cxl_switch_decoder' has no member named 'target_lock'
>   327 |                 seq = read_seqbegin(&cxlsd->target_lock);
>       |                                           ^~
> drivers/cxl/core/cdat.c:332:38: error: 'struct cxl_switch_decoder' has no member named 'target_lock'
>   332 |         } while (read_seqretry(&cxlsd->target_lock, seq));
>       |                                      ^~
> 
> Caused by commit
> 
>   185c1a489f87 ("cxl: Check qos_class validity on memdev probe")
> 
> interacting with commit
> 
>   5459e186a5c9 ("cxl/port: Fix missing target list lock")
> 
> from hte cls-fixes tree.
> 
> I have applied the following merge resolution for today.

Yup, this looks good, I will include a this merge in my next branch
going forward.

> 
> From: Stephen Rothwell <sfr@canb•auug.org.au>
> Date: Fri, 5 Jan 2024 15:44:24 +1100
> Subject: [PATCH] fix up for "cxl: Check qos_class validity on memdev probe"
> 
> interacting with "cxl/port: Fix missing target list lock"
> 
> Signed-off-by: Stephen Rothwell <sfr@canb•auug.org.au>
> ---
>  drivers/cxl/core/cdat.c | 14 ++++++--------
>  1 file changed, 6 insertions(+), 8 deletions(-)
> 
> diff --git a/drivers/cxl/core/cdat.c b/drivers/cxl/core/cdat.c
> index cd84d87f597a..10ac76bed477 100644
> --- a/drivers/cxl/core/cdat.c
> +++ b/drivers/cxl/core/cdat.c
> @@ -8,6 +8,7 @@
>  #include "cxlpci.h"
>  #include "cxlmem.h"
>  #include "cxl.h"
> +#include "core.h"
>  
>  struct dsmas_entry {
>  	struct range dpa_range;
> @@ -315,7 +316,6 @@ static int match_cxlrd_hb(struct device *dev, void *data)
>  	struct device *host_bridge = data;
>  	struct cxl_switch_decoder *cxlsd;
>  	struct cxl_root_decoder *cxlrd;
> -	unsigned int seq;
>  
>  	if (!is_root_decoder(dev))
>  		return 0;
> @@ -323,13 +323,11 @@ static int match_cxlrd_hb(struct device *dev, void *data)
>  	cxlrd = to_cxl_root_decoder(dev);
>  	cxlsd = &cxlrd->cxlsd;
>  
> -	do {
> -		seq = read_seqbegin(&cxlsd->target_lock);
> -		for (int i = 0; i < cxlsd->nr_targets; i++) {
> -			if (host_bridge == cxlsd->target[i]->dport_dev)
> -				return 1;
> -		}
> -	} while (read_seqretry(&cxlsd->target_lock, seq));
> +	guard(rwsem_read)(&cxl_region_rwsem);
> +	for (int i = 0; i < cxlsd->nr_targets; i++) {
> +		if (host_bridge == cxlsd->target[i]->dport_dev)
> +			return 1;
> +	}
>  
>  	return 0;
>  }
> -- 
> 2.43.0
> 
> -- 
> Cheers,
> Stephen Rothwell




  reply	other threads:[~2024-01-06  3:23 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-05  5:17 linux-next: build failure after merge of the cxl tree Stephen Rothwell
2024-01-06  3:23 ` Dan Williams [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-07-15  8:49 Stephen Rothwell
2025-07-15  8:57 ` Stephen Rothwell
2025-07-15 14:53   ` Dave Jiang
2021-09-06  4:20 Stephen Rothwell
2021-09-07 17:43 ` Dan Williams

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=6598c7c3db0fb_127da2294a6@dwillia2-xfh.jf.intel.com.notmuch \
    --to=dan.j.williams@intel$(echo .)com \
    --cc=dave.jiang@intel$(echo .)com \
    --cc=linux-kernel@vger$(echo .)kernel.org \
    --cc=linux-next@vger$(echo .)kernel.org \
    --cc=sfr@canb$(echo .)auug.org.au \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox