From: Christopher Bostic <cbostic@linux.vnet.ibm.com>
To: joel@jms.id.au, jk@ozlabs.org
Cc: Christopher Bostic <cbostic@linux.vnet.ibm.com>,
openbmc@lists.ozlabs.org
Subject: [PATCH linux dev-4.10 v2 3/3] fsi: core: Add check for master property no-scan-on-init
Date: Thu, 3 Aug 2017 22:26:22 -0500 [thread overview]
Message-ID: <20170804032622.88674-4-cbostic@linux.vnet.ibm.com> (raw)
In-Reply-To: <20170804032622.88674-1-cbostic@linux.vnet.ibm.com>
Prior to scanning a master check if the optional property
no-scan-on-init is present. If it is then avoid scanning. This is
necessary in cases where a master scan could interfere with another
FSI master on the same bus.
Signed-off-by: Christopher Bostic <cbostic@linux.vnet.ibm.com>
---
v2 - Remove changes in hub and gpio masters and make check for device
tree property in the core itself.
---
drivers/fsi/fsi-core.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/fsi/fsi-core.c b/drivers/fsi/fsi-core.c
index 9b83f1a..7b06b0d 100644
--- a/drivers/fsi/fsi-core.c
+++ b/drivers/fsi/fsi-core.c
@@ -900,6 +900,7 @@ static ssize_t master_break_store(struct device *dev,
int fsi_master_register(struct fsi_master *master)
{
int rc;
+ struct device_node *np;
if (!master)
return -EINVAL;
@@ -927,7 +928,9 @@ int fsi_master_register(struct fsi_master *master)
return rc;
}
- fsi_master_scan(master);
+ np = dev_of_node(&master->dev);
+ if (!of_property_read_bool(np, "no-scan-on-init"))
+ fsi_master_scan(master);
return 0;
}
--
1.8.2.2
next prev parent reply other threads:[~2017-08-04 3:26 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-08-04 3:26 [PATCH linux dev-4.10 v2 0/3] Add FSI master scan conditional Christopher Bostic
2017-08-04 3:26 ` [PATCH linux dev-4.10 v2 1/3] dt-bindings: fsi: Add optional property no-scan-on-init Christopher Bostic
2017-08-04 3:26 ` [PATCH linux dev-4.10 v2 2/3] ARM: dts: fsi: Add optional master " Christopher Bostic
2017-08-04 3:26 ` Christopher Bostic [this message]
2017-08-04 3:33 ` [PATCH linux dev-4.10 v2 3/3] fsi: core: Add check for " Jeremy Kerr
2017-08-08 13:02 ` Joel Stanley
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170804032622.88674-4-cbostic@linux.vnet.ibm.com \
--to=cbostic@linux.vnet.ibm.com \
--cc=jk@ozlabs.org \
--cc=joel@jms.id.au \
--cc=openbmc@lists.ozlabs.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.