[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v3 1/5] xen/ppc: Implement atomic.h


  • To: Shawn Anastasio <sanastasio@xxxxxxxxxxxxxxxxxxxxx>
  • From: Jan Beulich <jbeulich@xxxxxxxx>
  • Date: Fri, 8 Sep 2023 08:14:33 +0200
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=6IZjPNJsBIC0HAb1Ix/VriCMSpqI8pj/UJpDYUmsmhc=; b=PHomsOht025NUKeLFUyTJepkNg+JqHuIvUZrsChivSD63Qbo3av+XElB4dLp/PG+VBDqpHU5NTeZXiBQDjzoDtRZ+2Ms/MMmvecKJl6Rq8vCYQxx68p010NJ0y2n9XfAqWtPbsbvNdznQcxMDFazOEojowT6ZChDb82LgXGwRTEgWOQWMYtf80TF3rWGxjlugQmHopN4fDRlF6g9FteqfjTw6Ns8bPBjsOqLdvwl0xCnePCAyLpaTk5FA8Zcu2zOmOwrcDW614toDON1eUxeSYJKyJYkkV9Z47RnRGU5K0GGgwbpbZz5fJOdj/XCTz6avxvajY67hhB9tOjAjLt1Jw==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=HntPE3XTOFuvqsmdBHN27kW39IUw6g+D7hi1x6m3eNEcb3/NtpKhxBjuQGF+yqZtRuj2uU3Lch07V0rB6sXATD6OXQy22/1RTERyCZkaVkasNn9nVRJ0KmEawrNTPeMMfvGsi9UBBQkG7doZ5gHwpkV1u3vM6Rp+E+R05tdlx3eaPwfptEX1nSs2nPiyR6DdjkLXEeCAIN6OJU1/VaXWl7IMM0yJxNaPZVbwbeIGX8AWHPd4wgDnFHWOtzPyYA3vKxL9ioXt/FRSaimiBLCDTqFKkX8MJSZuP+mcyQt2ApT4TyNBYAc6NVNEL88aUVR8od8WUKaKUB1HSwLjdeIZ8g==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
  • Cc: Timothy Pearson <tpearson@xxxxxxxxxxxxxxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
  • Delivery-date: Fri, 08 Sep 2023 06:14:40 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 07.09.2023 22:10, Shawn Anastasio wrote:
> On 9/5/23 9:58 AM, Jan Beulich wrote:
>> On 01.09.2023 20:25, Shawn Anastasio wrote:
>>> +static inline atomic_t atomic_compareandswap(atomic_t old, atomic_t new,
>>> +                                             atomic_t *v)
>>> +{
>>> +    atomic_t rc;
>>> +    rc.counter = __cmpxchg(&v->counter, old.counter, new.counter, 
>>> sizeof(int));
>>
>> I can't seem to be able to spot where __cmpxchg() is defined. (I really
>> only wanted to check why it needs the 4th argument, which here rather
>> would want to be e.g. sizeof(v->counter). If it can't be omitted.)
>>
> 
> As you later saw, it's defined in system.h later in patch 3. This was an
> error I made when splitting up the changes into this patchset. If you're
> fine with it I'll just add a mention in the commit message that the
> definitions in this commit are not yet fully usable.

Sure, that's going to be okay.

Jan



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.