From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from relay5-d.mail.gandi.net (relay5-d.mail.gandi.net [217.70.183.197]) (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 9161750279; Tue, 5 Mar 2024 09:03:09 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.70.183.197 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709629392; cv=none; b=ptrM1pYrMYgT/iJIx5pWZrjUYBCQ956TSYAezL3APU1XH9EfZBAu3Gig0hgl2kbB+qTH+JTWZpM1fAFo/OVr3e8mQHW6SN+4L1MP8m9TdA5GKtyOq7NHNHdmNruRZWSO2jyw+j10xXbd5mAjzWx8CEvuyKezP6EkGDkezETzSXQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709629392; c=relaxed/simple; bh=cNdEM8vfnnYOXnE1/pcVWlwHUFEK9a4YCyqrTtuWxqY=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=prQPrgRAM6dtmQDGEpaKb4NpnV1h1YBL5UU/ehX8uPTNsaR7rVCpaSDG0Mc1v/wVKtH72XzpQvcDoGjuJ8sAkRm0M0KizvPdC3Mr6HxGJTZbN8AFS1InQj0pifVZZcTSinDsF5gI0NjPDdbGj6f+4lgRtiSTMH1PWCIb6sqJU18= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com; spf=pass smtp.mailfrom=bootlin.com; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b=J0+RPNQo; arc=none smtp.client-ip=217.70.183.197 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=bootlin.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b="J0+RPNQo" Received: by mail.gandi.net (Postfix) with ESMTPSA id CBBA41C0007; Tue, 5 Mar 2024 09:02:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1709629381; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=cNdEM8vfnnYOXnE1/pcVWlwHUFEK9a4YCyqrTtuWxqY=; b=J0+RPNQo0kcjTB3ttmpSW3fsCHfG2oBuLSV5YRYq7/iuchbARjyDkg63NdsGyVWILyMgkz /+xZmZBTTg2nh0ZujNTW6e6BO/JgjmlHuV3VLvCXXvEAz8cw2dFfIauAntKOcVjP9KoYLs W0IW5GwI73PadZElK0Gf5vVByQDUkAPA21sAkLCTHJJiZwe8VV0PDfS9NH8khrj7vrFFDq 5bXy1HOqq4lTJDy77JYDC+PgLLwqsalcFOEfxvqzB5S/x4q2q0o5RT2hM4IwJ0cPS6MYDN krtZs2LQv3orKmyCJbzTxoTWTFil86eFX0R67KuVnMnrgIqMiZpH4r6C3K1wUA== Date: Tue, 5 Mar 2024 10:02:59 +0100 From: =?UTF-8?B?S8O2cnk=?= Maincent To: Jakub Kicinski Cc: Florian Fainelli , Broadcom internal kernel review list , Andrew Lunn , Heiner Kallweit , Russell King , "David S. Miller" , Eric Dumazet , Paolo Abeni , Richard Cochran , Radu Pirea , Jay Vosburgh , Andy Gospodarek , Nicolas Ferre , Claudiu Beznea , Willem de Bruijn , Jonathan Corbet , Horatiu Vultur , UNGLinuxDriver@microchip.com, Simon Horman , Vladimir Oltean , Thomas Petazzoni , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, Maxime Chevallier , Rahul Rameshbabu Subject: Re: [PATCH net-next v9 07/13] ptp: Move from simple ida to xarray Message-ID: <20240305100259.006b3137@kmaincent-XPS-13-7390> In-Reply-To: <20240304184737.30cac57b@kernel.org> References: <20240226-feature_ptp_netnext-v9-0-455611549f21@bootlin.com> <20240226-feature_ptp_netnext-v9-7-455611549f21@bootlin.com> <20240304184737.30cac57b@kernel.org> Organization: bootlin X-Mailer: Claws Mail 3.17.5 (GTK+ 2.24.32; x86_64-pc-linux-gnu) Precedence: bulk X-Mailing-List: linux-doc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-GND-Sasl: kory.maincent@bootlin.com On Mon, 4 Mar 2024 18:47:37 -0800 Jakub Kicinski wrote: > On Mon, 26 Feb 2024 14:39:58 +0100 Kory Maincent wrote: > > +static DEFINE_XARRAY_FLAGS(ptp_clocks_map, XA_FLAGS_LOCK_IRQ | > > XA_FLAGS_ALLOC); =20 >=20 > Why _IRQ? anything on the fastpath hopefully has a pointer to the clock > already, I'd hope. And we often reserve ID 0 as invalid. To keep the same flag as IDA_INIT_FLAGS, I am not expert in xarray so I just keep it without questioning it. Do you think I should remove it? ID 0 was valid for phc. IMHO makes it invalid is not a good idea, it will change the phc id value for current board on the field. >=20 > BTW could be a standalone patch, Xarray conversion from IDA is an > improvement in itself. Indeed. Do you prefer this patch to be standalone? Regards, --=20 K=C3=B6ry Maincent, Bootlin Embedded Linux and kernel engineering https://bootlin.com