greybus: core: Don't initialize greybus if it is disabled

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Viresh Kumar 2015-03-20 20:29:13 +05:30 committed by Greg Kroah-Hartman
parent 792c17e643
commit 337b068722
1 changed files with 3 additions and 0 deletions

View File

@ -207,6 +207,9 @@ static int __init gb_init(void)
{
int retval;
if (greybus_disabled())
return -ENODEV;
BUILD_BUG_ON(HOST_DEV_CPORT_ID_MAX >= (long)CPORT_ID_BAD);
retval = gb_debugfs_init();