greybus: svc: don't trust any struct devices
authorGreg Kroah-Hartman <gregkh@google.com>
Fri, 16 Oct 2015 23:53:31 +0000 (16:53 -0700)
committerGreg Kroah-Hartman <gregkh@google.com>
Mon, 19 Oct 2015 19:09:10 +0000 (12:09 -0700)
commitb50a24e9471290fae7f7d16be467b3b0937d3d0e
tree59db04b9ca1c75aeafec0200e1cc22d379f2eb23
parentc69b98d15fff68e83396d800f43508a1dab4130a
greybus: svc: don't trust any struct devices

As the svc code is "odd" in how things are set up at initial connection
time, we can't always "know" that we have a valid bundle to use for
error messages.  So just punt and always use pr_*() calls to ensure that
we never incorrectly dereference a pointer.

This will get fixed up soon, but for now, let's just live with a bit
messier error messages in the log.

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Reviewed-by: Viresh Kumar <viresh.kumar@linaro.org>
Reviewed-by: Alex Elder <elder@linaro.org>
Reviewed-by: Johan Hovold <johan@hovoldconsulting.com>
drivers/staging/greybus/svc.c