From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 93AFCC43334 for ; Thu, 2 Jun 2022 00:34:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:Reply-To:List-Subscribe:List-Help: List-Post:List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=tXvMNHZf7fRmVOHLaB7DfUEnsnJC61b/OM/lZQwmapk=; b=CNcguDqHkzZmTP Wb0eHEj00TqWJ9RgngN+NXnvnLgqt83J16iMeFySUbEmdWmUdTSx7Yjuog698NMfBziV1lCMrFMup pBCjlHPqpSfDtP61r9j+DN4rJ5wrydlWnZ0FGUOO6AuKFrpbToSXgi3XTISPhYPWZUTx7aSXzTe7m 9mY+6gy2PV9AxSXTyKFlE49q8BDbxUBGsVzg7pf/1Y4+X8vt80fRV3E62bFyzKTPRVpjTFzHrXjdu sdqeo8+OprnALM70ra/dHSFSzcTogfFv62HtakJpiYr1IDNrFg6V4g5YkoooGCOdwxx1wductdTHW M3Uep93/p8xWVOtyAV1A==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nwYlg-000sWF-2m; Thu, 02 Jun 2022 00:32:52 +0000 Received: from mail-oi1-x22f.google.com ([2607:f8b0:4864:20::22f]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nwYlc-000sVp-QM for linux-arm-kernel@lists.infradead.org; Thu, 02 Jun 2022 00:32:50 +0000 Received: by mail-oi1-x22f.google.com with SMTP id y131so4751547oia.6 for ; Wed, 01 Jun 2022 17:32:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=sender:date:from:to:cc:subject:message-id:reply-to:references :mime-version:content-disposition:in-reply-to; bh=sh16xGe/echtR67o8EYAV8ZtQjoNwgsJwYaCJqxIORY=; b=QPOHKu2JZdnGBtC7fmTtjOSE9oopRqCnfZOiDgt6Xq8NaeFj5LEpiNC4MBvSny6XAZ tP23yYoSibaO17BC+tN/4ndFzeu3y9sAlpFxVrvR46zGNkrmktR82tsnRYao912mVlgu sFnMmIo/6tg4Mf1sU3/boIWlqZvWGKl6F7TtFJWoKmbeKgyEm9YDB5EQd+wNDBuGyvTX E9bkmD/dKERVdm2JsF9okxmr6y9B2DO2czXcmSta8JmSRNupjJh1aMt94eWuHQdZiOYP kpQk2+ruD30huk1PRYNfV17WxAzjzkzOE8Zn/WugahtBCADPO8Sj5PlPfroNmHZkNiyY 469Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :reply-to:references:mime-version:content-disposition:in-reply-to; bh=sh16xGe/echtR67o8EYAV8ZtQjoNwgsJwYaCJqxIORY=; b=4/oujXolqPtbZmUKALiuXx9cTO2OHZVyy1wdBbnz4417bipZo0nDw6TlmdKnZnFnw3 C4EhsYMwVYp2f5ahQIf8TKHOlLdc1CU2TMUy6zjyhLs7zqppKWuSlwBX21LwrF4XGJpN xWedSiKh6sD8hb+XIwZ7jcLjXhAIsbJ+nL6GEslieb+U53RrurGC5G6ztgvjGo9RTcDV DK/lyPHH291gIolwEMXPE3KR+d8abvEd4H+dr5bu90JlxQjXSqlYQUvGGq3i+5iZkzlm puhBluESGGfIXhc25Eee2sM25TNVqg2CAGGLkF8/5IO6yJScj58V6PTrudFfhcjID6ZJ wwmw== X-Gm-Message-State: AOAM531PHQdlJ55sQuURAVYJrKXDBbrZk421h4nhCYCwmn2C3yRtlSg6 NycxaHSS3nSF6wQKhCzdhw== X-Google-Smtp-Source: ABdhPJzvSVAppomg02HmNv/mcRsuQs1poeKeWSDg8cjkuwsPJmAtobRPluwWod2pXyfwLfpU1Gm0fQ== X-Received: by 2002:a05:6808:2196:b0:32b:492a:3b4d with SMTP id be22-20020a056808219600b0032b492a3b4dmr1200787oib.255.1654129966739; Wed, 01 Jun 2022 17:32:46 -0700 (PDT) Received: from serve.minyard.net (serve.minyard.net. [2001:470:b8f6:1b::1]) by smtp.gmail.com with ESMTPSA id 12-20020aca120c000000b00325cda1ffa5sm1542462ois.36.2022.06.01.17.32.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jun 2022 17:32:46 -0700 (PDT) Received: from minyard.net (unknown [IPv6:2001:470:b8f6:1b:cca5:4cab:9a61:6930]) by serve.minyard.net (Postfix) with ESMTPSA id 423751800BB; Thu, 2 Jun 2022 00:32:45 +0000 (UTC) Date: Wed, 1 Jun 2022 19:32:44 -0500 From: Corey Minyard To: Quan Nguyen Cc: devicetree@vger.kernel.org, linux-aspeed@lists.ozlabs.org, Krzysztof Kozlowski , Andrew Jeffery , Benjamin Herrenschmidt , openbmc@lists.ozlabs.org, "Thang Q . Nguyen" , Brendan Higgins , linux-kernel@vger.kernel.org, Phong Vo , Wolfram Sang , Rob Herring , openipmi-developer@lists.sourceforge.net, Open Source Submission , linux-arm-kernel@lists.infradead.org, linux-i2c@vger.kernel.org Subject: Re: [Openipmi-developer] [PATCH v7 1/3] ipmi: ssif_bmc: Add SSIF BMC driver Message-ID: <20220602003244.GK3767252@minyard.net> References: <20220422040803.2524940-1-quan@os.amperecomputing.com> <20220422040803.2524940-2-quan@os.amperecomputing.com> <20220423015119.GE426325@minyard.net> <20220504120631.GE3767252@minyard.net> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220601_173248_896715_8BB3B64B X-CRM114-Status: GOOD ( 33.47 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: minyard@acm.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Wed, Jun 01, 2022 at 03:23:11PM +0700, Quan Nguyen wrote: > On 04/05/2022 19:06, Corey Minyard wrote: > > On Wed, May 04, 2022 at 01:45:03PM +0700, Quan Nguyen via Openipmi-developer wrote: > > > > > > > > I seem to remember mentioning this before, but there is no reason to > > > > pack the structures below. > > > > > > > > > > The packed structure is because we want to pick the len directly from user > > > space without worry about the padding byte. > > > > > > As we plan not to use the .h file in next version, I still would like to use > > > packed structure internally inside ssif_bmc.c file. > > > > Packed doesn't matter for the userspace API. If you look at other > > structures in the userspace API, they are not packed, either. The > > compiler will do the right thing on both ends. > > > > > > > > > And second, the following is a userspace API structures, so it needs to > > > > be in its own file in include/uapi/linux, along with any supporting > > > > things that users will need to use. And your userspace code should be > > > > using that file. > > > > > > > > > > Meantime, I'd like not to use .h as I see there is no demand for sharing the > > > data structure between kernel and user space yet. But we may do it in the > > > future. > > > > If you have a userspace API, it needs to be in include/uapi/linux. > > You may not be the only user of this code. In fact, you probably won't > > be. You need to have a .h with the structures in it, you don't want the > > same structure in two places if you can help it. > > > > Dear Corey, > > Is it OK to push the structure definition into the > include/uapi/linux/ipmi_bmc.h ? > > Or should it need to be in separate new header file in uapi/linux ? I think a different file, like ipmi_ssif_bmc, to match the file and operation. Unless you need the things in ipmi_bmc.h, which I don't think is the case. -corey > > Thank you, > - Quan > > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel