Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp983299yba; Wed, 24 Apr 2019 12:56:28 -0700 (PDT) X-Google-Smtp-Source: APXvYqxt6s3UrR9MOytd54+K9dIeb+7otV0v7CuLdvhBOh3u8/Vc5qBSRWZskaX6Hw47xEEs+Hd9 X-Received: by 2002:aa7:9194:: with SMTP id x20mr4786173pfa.29.1556135788803; Wed, 24 Apr 2019 12:56:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1556135788; cv=none; d=google.com; s=arc-20160816; b=dmLxZxnyQ5EPDqOABHAWxirqF6qPyA2O2L1qKr4ivkGFTYaWtsmdL+m6EqPTB7+tGf j7V+S9aE2mUM9HIpy/8CqNK+8ybcR8DPWJcjMqJuf9fPde9FjEiNEBVOq3/953QdFRL6 Ov5g3OM3EPGKZ/ODq6aYPheWwABygOioEamhZX+7kLXzW6HR5eND7tUhgPqDRIq28O9Z CHfj7yG7v7YSx/BlG99eCtWC0BiRb7zdGCAheHmLXbXAq2dqXkEPAiwEmofrjO9SC+48 SF3h99ZtkBsd5MF/XX6dOAbxRLTxk3WDR3LZ0nW05SmnYWuFn9GiC5Aosf2yIXA7TyON acOA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:reply-to:message-id :subject:cc:to:from:date:dkim-signature; bh=TiDnhjK/VArowtwPe5AuaHtBqWO5JLqyyuR7HAzGWwI=; b=VErgILOHOX+qgk3bDIHLJ77/ALfYv90u33iFSEoLbLVUVU0M7g+2/tWOqlerV4GKlp MH9Gr5skUHJUW2FZ1xzDGsQ/EujdrlJbLgEUs/h3unsw/H4Zv5tL8ZPntvVrQpz2E8VJ yH47luGrL6KZVVimy5+9QvS1nloX7gHZSJ5iRKGNIZp+Ew/mYzmV14U5STpZyehjMH2t bixQ5cIFv9SVwF3rsymYJGdm3pqIbS03wS2xzHJ7KUIpqhGKJr2kVjfwrWy5ftNL1fLz PA3GKWBUuT/KpXGXx5/2twjpSn7R6yg+TG6Jhu0Z0iNaelwtaVIa1MJXOZQtGFs1MXks soTg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=RTA8NQVT; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o9si18008790pgv.25.2019.04.24.12.56.08; Wed, 24 Apr 2019 12:56:28 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=RTA8NQVT; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726989AbfDXN1Z (ORCPT + 99 others); Wed, 24 Apr 2019 09:27:25 -0400 Received: from mail-oi1-f196.google.com ([209.85.167.196]:41266 "EHLO mail-oi1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726165AbfDXN1Y (ORCPT ); Wed, 24 Apr 2019 09:27:24 -0400 Received: by mail-oi1-f196.google.com with SMTP id v7so14246447oie.8 for ; Wed, 24 Apr 2019 06:27:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:date:from:to:cc:subject:message-id:reply-to:references :mime-version:content-disposition:in-reply-to:user-agent; bh=TiDnhjK/VArowtwPe5AuaHtBqWO5JLqyyuR7HAzGWwI=; b=RTA8NQVTixY3QcCRnFGfQn1eAmUTWMLgy8dlgw0bI/pnDYuTT5Lcj2hqodcJfwy0Xi sh3Ni+db7tJlS8eVdMge409nfSVso4fUqrxRLLJRCvT1LrbfBi/IS2Kcs55xpW4/WZkA 5TYuLQIe4fM9TCVIjm3Ie4xXIsc2dE624H54gmR/qoOlXY3Y0xK8mYZnwUMfmd5tecrC bx7aZ+mfAdqgQnYOqb3carGuky9Lw0+JUPlvTvNJbH6nvOLIHHe0spNMAJHY/vYb4B0B Vlz89AT0tWTIw2hAuJlzysIy7xslZLswAyA0DX6R/7j9mbMgGvovud3AZQWUd70xKd6u mdgw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :reply-to:references:mime-version:content-disposition:in-reply-to :user-agent; bh=TiDnhjK/VArowtwPe5AuaHtBqWO5JLqyyuR7HAzGWwI=; b=bPrSpV41MeWL3kDvo5MNkZ+3wcEfm0VtD0zMtmv6LrbdTUSrGwQfwTz9cHmjjzcne2 j2npV15vKOqGkHvvebADzS6PVz3mx6R6oXaRmsAyS4vtkufO3+JOLmwkAslkiu7bvt5J 3og3Is8KAeuLbaPG6Lzra8VlvhFuWQhrTxDnUhBBPMIfA+Wk5ZD4BQYh2QIPyQgltoL0 rdAdKsblyqSSk9OxT37nA5GWcEZGFqjwRPbDRoitxIJtZ/sNXAtkqKrScdBG8Vqn6IPT ZMNmwZ3DbtRT1eVGwDWb1mi8Of8yn5BsuHnciTItzRtYzTrYdg3iuqjvpR8Tmnfatww3 RZiw== X-Gm-Message-State: APjAAAUqUX+j4Ibpzo3XC72tuGrdksEyDp0SozgeePsdjuPVmhSHS8H4 CcwcSVqlBuW0eNFkSW0f/MX07zY= X-Received: by 2002:aca:abce:: with SMTP id u197mr5254580oie.151.1556112443479; Wed, 24 Apr 2019 06:27:23 -0700 (PDT) Received: from serve.minyard.net ([47.184.134.43]) by smtp.gmail.com with ESMTPSA id e133sm8291629oif.44.2019.04.24.06.27.22 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 24 Apr 2019 06:27:22 -0700 (PDT) Received: from minyard.net (unknown [IPv6:2001:470:b8f6:1b:d5e:aa5a:44d8:6907]) by serve.minyard.net (Postfix) with ESMTPSA id 041AA1800CF; Wed, 24 Apr 2019 13:27:22 +0000 (UTC) Date: Wed, 24 Apr 2019 08:27:20 -0500 From: Corey Minyard To: Kamlakant Patel Cc: "linux-kernel@vger.kernel.org" , "openipmi-developer@lists.sourceforge.net" Subject: Re: [PATCH] ipmi: fix slave-addr property add to ipmi platform device Message-ID: <20190424132720.GC6623@minyard.net> Reply-To: minyard@acm.org References: <1556102007-14083-1-git-send-email-kamlakantp@marvell.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1556102007-14083-1-git-send-email-kamlakantp@marvell.com> User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Apr 24, 2019 at 10:34:14AM +0000, Kamlakant Patel wrote: > Remove check for p->slave_addr while adding 'slave-addr' property entry > since it can be 0. > Currently, it throws following error: > "ipmi_ssif dmi-ipmi-ssif.0: ipmi_ssif: device has no slave-addr > property" > > This patch fixes the issue. This would cause things that don't supply slave addresses to get the wrong address, they will get 0x00 instead of 0x20, like they should. The right thing is to remote the warning, I guess. -corey > > Signed-off-by: Kamlakant Patel > --- > drivers/char/ipmi/ipmi_plat_data.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/drivers/char/ipmi/ipmi_plat_data.c b/drivers/char/ipmi/ipmi_plat_data.c > index 8f0ca2a..2b62104 100644 > --- a/drivers/char/ipmi/ipmi_plat_data.c > +++ b/drivers/char/ipmi/ipmi_plat_data.c > @@ -34,8 +34,7 @@ struct platform_device *ipmi_platform_add(const char *name, unsigned int inst, > p->regspacing = p->regsize; > > pr[pidx++] = PROPERTY_ENTRY_U8("ipmi-type", p->type); > - if (p->slave_addr) > - pr[pidx++] = PROPERTY_ENTRY_U8("slave-addr", p->slave_addr); > + pr[pidx++] = PROPERTY_ENTRY_U8("slave-addr", p->slave_addr); > pr[pidx++] = PROPERTY_ENTRY_U8("addr-source", p->addr_source); > if (p->regshift) > pr[pidx++] = PROPERTY_ENTRY_U8("reg-shift", p->regshift); > -- > 1.8.3.1 >