Received: by 2002:ab2:6a05:0:b0:1f8:1780:a4ed with SMTP id w5csp2281802lqo; Mon, 13 May 2024 13:22:24 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVUiKZyCrN4MXR/Wj8KSj59gL/JRtppScHmbqTFISXA07Ei2grai3tWz6azxSxm+gB6UKU3BltvB2aFRyQciTeKpYf77mDupnGPld++QA== X-Google-Smtp-Source: AGHT+IHd2xCq7sJJmo5PEMgt3mn6PSpycxDJ0y9qj8yVzP8yhmuYhoX9GLwZd0qkapxvQBnqlgkL X-Received: by 2002:a17:90a:a404:b0:2b5:fce8:59fa with SMTP id 98e67ed59e1d1-2b6ccd6bfa4mr8861120a91.31.1715631744226; Mon, 13 May 2024 13:22:24 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715631744; cv=pass; d=google.com; s=arc-20160816; b=bVRQtZ8Wlv4FqSEyC4+P1P5tgp/72dOSby5v1YbXMIqvglZeReRgTNteDZRLtu79IJ fB/er3rjpezHYuW2HGbJdEeMz9LBfUKkAS0pB0J8m6eKAdjg78jikCTfl/MSecYj+AJG eRuaarNYDeKWIbXedg15uRpLg3xDiKimojFngTH6vRXf8ILcYvwvUEjIOxwAgzFJaPlG LAXCbA0kv2NpHhRk4uNjXq8VPp/OntCrbrDL/8O1ofCMgrOewiyE9ZXArb/VD/DeHOv0 uIpodo8taShGw1XrKMFajZos3fPsq85HwC8CTU8hZkAv+cDR3405zrk/2tw1s8jf8RNr ZGNg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=DtIfyWjCrgt1EGu9Lx9mzz635kI1F/8RrAF0bzMyy8M=; fh=uS1vZuGJlj/Ennj1sSkEPiCK+Ej+zX5nxPeToaSkWIQ=; b=nyQASG4Hhgnlzut14TQHJ1GuQit8paqDlE+Q9TaJPfw2egOTII+VnPtDCIXmmDFA+L 3CBlatznMJyGNKaF+CvUBLJNTY4P8g+hn9jebfbWCtlhXX/jDiDrJWYgoY8OdtXHWiG/ sbR5L/nynpjFV63sF9QMb1G9X5sG7hg8pc1ItOc9mOVsk0yOBHkzY8ujIEMkkdoJ+hG1 1IferU7CV3LhVnaQKSDLjVho0CaI70aPNlN4GQOJx7WGWSyMBV2WWnNfSQNSxXAQFi31 KrZRzMUgD/+aTJOfsBrl0ars6HuJlORNN7vei61+9bKHVpXYkvXxNmJL4Z+ILJ/iTbod VwEQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b=RHVUT5fc; arc=pass (i=1 spf=pass spfdomain=lunn.ch dkim=pass dkdomain=lunn.ch dmarc=pass fromdomain=lunn.ch); spf=pass (google.com: domain of linux-kernel+bounces-178065-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-178065-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=lunn.ch Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id 98e67ed59e1d1-2b67177f00bsi10157900a91.186.2024.05.13.13.22.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 May 2024 13:22:24 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-178065-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b=RHVUT5fc; arc=pass (i=1 spf=pass spfdomain=lunn.ch dkim=pass dkdomain=lunn.ch dmarc=pass fromdomain=lunn.ch); spf=pass (google.com: domain of linux-kernel+bounces-178065-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-178065-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=lunn.ch Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id D6F55285B62 for ; Mon, 13 May 2024 20:22:23 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A51897E792; Mon, 13 May 2024 20:22:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=lunn.ch header.i=@lunn.ch header.b="RHVUT5fc" Received: from vps0.lunn.ch (vps0.lunn.ch [156.67.10.101]) (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 674AB39FD8; Mon, 13 May 2024 20:22:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=156.67.10.101 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715631735; cv=none; b=hDOxKTpf6XdcqAKOU1RVyGsaz4/L6HR8DPnx/tNI3kA0ftO73nMSjZkX+nxiXSGqLZDiLblQLbfq+jiROL5ZteQacBtk9u2KOysm1vaK4Cx8lel5Sim3uxN9WaTcuP1vXvos3I+dRH9pp8noFEvzG2LpoR+EvGwcC1JDod/Vph0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715631735; c=relaxed/simple; bh=xkIyIbZAjoDJctNIIOzX6lUajmD5zufFz56zALxN/9Y=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=UtDL3AuNsusCK1F0DJmhpK71vZmXzDiN8DBPB7ov9DVgF1im5WxJ7hvWzMFFJ0lE3L+pvAdmwP8P05/WI+bmff0V1hZ/1zH1j8avc98FfVwGJ9WNIfR99DSE1V40k+t8zjDC0n2WDHHUbRWagXNY+lnZRHmrOpVTHY2D2eccg30= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=lunn.ch; spf=pass smtp.mailfrom=lunn.ch; dkim=pass (1024-bit key) header.d=lunn.ch header.i=@lunn.ch header.b=RHVUT5fc; arc=none smtp.client-ip=156.67.10.101 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=lunn.ch Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lunn.ch DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lunn.ch; s=20171124; h=In-Reply-To:Content-Disposition:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:From:Sender:Reply-To:Subject: Date:Message-ID:To:Cc:MIME-Version:Content-Type:Content-Transfer-Encoding: Content-ID:Content-Description:Content-Disposition:In-Reply-To:References; bh=DtIfyWjCrgt1EGu9Lx9mzz635kI1F/8RrAF0bzMyy8M=; b=RHVUT5fcdaSQi2xY9RuDoEotGV D8Q+vaZuNHykP1iItOiM1cP3c0rgA5U+5D8Qj4ptLlD8F1ZnjX2oXjeq0RlIJvbaNIRCwArPTWLJv 3NBJMBQR1GPStEAWw9L9unnnBaDgNM78dbtwHi9Sixr7hmAn2IL72LbWfJ5JBY9rkmJc=; Received: from andrew by vps0.lunn.ch with local (Exim 4.94.2) (envelope-from ) id 1s6cBQ-00FKk3-2V; Mon, 13 May 2024 22:22:04 +0200 Date: Mon, 13 May 2024 22:22:04 +0200 From: Andrew Lunn To: admiyo@os.amperecomputing.com Cc: Jeremy Kerr , Matt Johnston , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/3] mctp pcc: Implement MCTP over PCC Transport Message-ID: <9006463d-27db-4715-a1ab-61c41823ce3c@lunn.ch> References: <20240513173546.679061-1-admiyo@os.amperecomputing.com> <20240513173546.679061-2-admiyo@os.amperecomputing.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240513173546.679061-2-admiyo@os.amperecomputing.com> > +struct mctp_pcc_hw_addr { > + int inbox_index; > + int outbox_index; > +}; > +static void mctp_pcc_setup(struct net_device *ndev) > +{ > + ndev->type = ARPHRD_MCTP; > + ndev->hard_header_len = 0; > + ndev->addr_len = sizeof(struct mctp_pcc_hw_addr); Another reason you should be using u32. ndev->addr_len is going to vary between 32 and 64 bit systems. I also wounder if when calling dev_addr_set() these need to be byte swapped? Does the specification define this? Andrew