linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Sell, Timothy C" <Timothy.Sell@unisys.com>
To: "'Greg KH'" <gregkh@linuxfoundation.org>
Cc: "Kershner, David A" <David.Kershner@unisys.com>,
	"dzickus@redhat.com" <dzickus@redhat.com>,
	"prarit@redhat.com" <prarit@redhat.com>,
	"driverdev-devel@linuxdriverproject.org" 
	<driverdev-devel@linuxdriverproject.org>,
	*S-Par-Maintainer <SParMaintainer@unisys.com>,
	"janani.rvchndrn@gmail.com" <janani.rvchndrn@gmail.com>,
	"corbet@lwn.net" <corbet@lwn.net>,
	"jes.sorensen@redhat.com" <jes.sorensen@redhat.com>,
	"Binder, David Anthony" <David.Binder@unisys.com>,
	"hofrat@osadl.org" <hofrat@osadl.org>,
	"dan.j.williams@intel.com" <dan.j.williams@intel.com>,
	"nhorman@redhat.com" <nhorman@redhat.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"mingo@redhat.com" <mingo@redhat.com>,
	"hpa@zytor.com" <hpa@zytor.com>,
	"tglx@linutronix.de" <tglx@linutronix.de>,
	"sudipm.mukherjee@gmail.com" <sudipm.mukherjee@gmail.com>,
	"linux-doc@vger.kernel.org" <linux-doc@vger.kernel.org>
Subject: RE: [PATCH 3/3] drivers: Add visorbus to the drivers/virt directory
Date: Sun, 11 Sep 2016 14:46:19 +0000	[thread overview]
Message-ID: <BN3PR07MB2580EA192759C372E2A395AEFCFC0@BN3PR07MB2580.namprd07.prod.outlook.com> (raw)
In-Reply-To: <20160911091629.GA17608@kroah.com>

On Sun, 11 Sep 2016 02:17:10 -0700, Greg KH wrote:
> On Tue, Aug 30, 2016 at 04:29:07PM +0000, Sell, Timothy C wrote:
>> E.g., so even though no obvious error-recovery occurs above in-response to
>> kzalloc() failures, the fact that -CONTROLVM_RESP_ERROR_KMALLOC_FAILED is
>> provided to bus_epilog() is in-fact sufficient to report the error.
>> 
>> Is this making sense?

> Yes, it does a bit more, but, you should make this more explicit.

Agreed.  I believe your recommendation below is the right way to accomplish
this.

>> Can you suggest how we might modify our code to make this error-handling /
>> recovery strategy clearer?

> Have a real error be returned by the function, and then have the caller
> handle the error by propagating it back to the firmware through the
> message.  That might save you a lot of boiler-plate error handling logic
> as well, right?

> That will make it obvious that if an error happens, it is caught, and
> how it is handled correctly.

> Does that help?

Yes it does.  We'll work out a scheme where all of these functions in fact
return their status code to a common dispatch function, whose job it will
be to send this status code back to the firmware.  This might even let us
consolidate/eliminate a few of the other functions we have that deal with
various ways of formatting firmware responses, by encompassing their logic
into this common dispatch function.

That strategy should make it clearer and more explicit as to what is
going on here.

Thanks!

Tim Sell

  reply	other threads:[~2016-09-11 15:19 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-11  3:23 [PATCH 0/3] move visorbus out of staging to drivers/virt/visorbus David Kershner
2016-06-11  3:23 ` [PATCH 1/3] include: linux: visorbus: Add visorbus to include/linux directory David Kershner
2016-08-21 15:37   ` Greg KH
2016-06-11  3:23 ` [PATCH 2/3] Documentation: Move visorbus documentation from staging to Documentation/ David Kershner
2016-06-11  3:23 ` [PATCH 3/3] drivers: Add visorbus to the drivers/virt directory David Kershner
2016-08-21 18:04   ` Greg KH
2016-08-22  2:48     ` Sell, Timothy C
2016-08-22  8:15       ` 'Greg KH'
2016-08-22 10:46         ` Sell, Timothy C
2016-08-22 14:02           ` 'Greg KH'
2016-08-22 14:10             ` 'Greg KH'
2016-08-30 16:29     ` Sell, Timothy C
2016-09-11  9:16       ` 'Greg KH'
2016-09-11 14:46         ` Sell, Timothy C [this message]
2016-06-14 13:30 ` [PATCH 0/3] move visorbus out of staging to drivers/virt/visorbus Neil Horman

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=BN3PR07MB2580EA192759C372E2A395AEFCFC0@BN3PR07MB2580.namprd07.prod.outlook.com \
    --to=timothy.sell@unisys.com \
    --cc=David.Binder@unisys.com \
    --cc=David.Kershner@unisys.com \
    --cc=SParMaintainer@unisys.com \
    --cc=corbet@lwn.net \
    --cc=dan.j.williams@intel.com \
    --cc=driverdev-devel@linuxdriverproject.org \
    --cc=dzickus@redhat.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=hofrat@osadl.org \
    --cc=hpa@zytor.com \
    --cc=janani.rvchndrn@gmail.com \
    --cc=jes.sorensen@redhat.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=nhorman@redhat.com \
    --cc=prarit@redhat.com \
    --cc=sudipm.mukherjee@gmail.com \
    --cc=tglx@linutronix.de \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).