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 A162BC3DA4A for ; Thu, 22 Aug 2024 10:11:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:In-Reply-To: Content-Transfer-Encoding:Content-Type:MIME-Version:References:Message-ID: Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=zXvaogXbompG9W6t7F8G4hkJrtkDP4F6kuRjCY5d7Oo=; b=29kYx8qAkLjPJmVuJwhhz4m+H2 j1wY/Snhmf77wyqteEJXQbjDHtrxkRUFUs85EK+7Kcm3Y5XwgAYT5dSsz74xFL4Ck48H+gn718JTq x8v5/9asdDj6IOFWuaGWCMTi6yXFmazSACuSubCB2nH3zu2jlDOANGJUkGG993jckp0FLNDm9BrGZ fK0IcskKzaQb9gC5yb5a/qkluXN3MH2Aq4zd3MtPF5DizR1am8ncCiu106msfluS74vHF0Coqg0jK 0DXzCjdJPxO+pYGp8SCQO7WI+s+mZeWrfcfKzqQhz25KTeyiULodTpLPRXavq8Q7++yRimwqqe3b6 AsCwYhBA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sh4mp-0000000CNn4-1OpI; Thu, 22 Aug 2024 10:11:23 +0000 Received: from sin.source.kernel.org ([2604:1380:40e1:4800::1]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sh4lx-0000000CNeu-0qnj; Thu, 22 Aug 2024 10:10:30 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by sin.source.kernel.org (Postfix) with ESMTP id 59940CE0F0F; Thu, 22 Aug 2024 10:10:27 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 638D7C32782; Thu, 22 Aug 2024 10:10:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1724321426; bh=0ApU82SZWq6n9EuyshuodUqSF2/9WM8FQ5lruXW/bCQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=lDi3xLFENzGU+hwTJNHpp2Tv9TkveDcGPJzLrErcnV2m3J+wIGxAVTL89EfAU7mC1 qan8wL6poGR5P5BzvhGZVchExNIHO9fgZFABEWm2iRstQv8dMCCXg4gCY4+a9LTdfz 2v4Txgn5TMg2THG96HTc3SOjFaoaKKHfVOKQ5SD2H023KnQIf+qu52AIsxL5sxQq+w d9HMp8JBexoZYP4T671NgsUdb0ocilmLUtCvoyR+Qo3TErQ942yqwbsRSC+R16ZCoB MJjmgY6yQJnlZTDVIKNi5gvTFFwkcObt0a9lGCuI+rF1aKYhw2aeYfy/IeG4wJDa+Q e0weELHrOI0Qg== Date: Thu, 22 Aug 2024 11:10:20 +0100 From: Lee Jones To: Heiko =?iso-8859-1?Q?St=FCbner?= Cc: jdelvare@suse.com, linux@roeck-us.net, dmitry.torokhov@gmail.com, pavel@ucw.cz, robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org, ukleinek@debian.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-hwmon@vger.kernel.org, linux-input@vger.kernel.org, linux-leds@vger.kernel.org Subject: Re: [PATCH v4 2/7] mfd: add base driver for qnap-mcu devices Message-ID: <20240822101020.GG6858@google.com> References: <20240810184743.277248-1-heiko@sntech.de> <20240810184743.277248-3-heiko@sntech.de> <20240816171336.GF5853@google.com> <2875938.88bMQJbFj6@diego> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <2875938.88bMQJbFj6@diego> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240822_031029_436559_6C2F38E9 X-CRM114-Status: GOOD ( 20.72 ) 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Sun, 18 Aug 2024, Heiko Stübner wrote: > Hi Lee, > > thanks a lot for your review, > > Am Freitag, 16. August 2024, 19:13:36 CEST schrieb Lee Jones: > > On Sat, 10 Aug 2024, Heiko Stuebner wrote: > > > > > +/* > > > + * MFD core driver for the MCU in Qnap NAS devices that is connected > > > > No such thing as an "MFD". Please describe the device. > > > > Is it QNAP or Qnap? Please be consistent. > > Looks like QNAP spells itself in all upper case on their website, so I did > go with that Super, thanks. > > > + > > > +/* > > > + * The MCU controls power to the peripherals but not the CPU. > > > + * > > > + * So using the pmic to power off the system keeps the MCU and hard-drives > > > + * running. This also then prevents the system from turning back on until > > > + * the MCU is turned off by unplugging the power-cable. > > > + * Turning off the MCU alone on the other hand turns off the hard-drives, > > > + * LEDs, etc while the main SoC stays running - including its network ports. > > > + */ > > > +static int qnap_mcu_power_off(struct sys_off_data *data) > > > +{ > > > + struct qnap_mcu *mcu = data->cb_data; > > > + int ret; > > > + u8 cmd[] = { > > > + [0] = 0x40, /* @ */ > > > + [1] = 0x43, /* C */ > > > + [2] = 0x30 /* 0 */ > > > + }; > > > > u8 cmd [] = { '@', 'C', '0' }; ? > > see above. > > I guess this is a style choice, we could of course go with > u8 cmd[] = { 0x40, 0x43, 0x30 } > if you prefer that. Yes please. -- Lee Jones [李琼斯]