Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1506309
| Path | csiph.com!news.mixmin.net!aioe.org!bofh.it!news.nic.it!robomod |
|---|---|
| From | "Rafael J. Wysocki" <rjw@rjwysocki.net> |
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] mailbox: PCC: Fix return value of pcc_mbox_request_channel() |
| Date | Fri, 21 Oct 2016 23:30:02 +0200 |
| Message-ID | <suPy2-2Jv-23@gated-at.bofh.it> (permalink) |
| References | <ssk5j-82w-3@gated-at.bofh.it> |
| X-Original-To | Hoan Tran <hotran@apm.com> |
| User-Agent | KMail/4.11.5 (Linux/4.8.0-rc2+; KDE/4.11.5; x86_64; ; ) |
| MIME-Version | 1.0 |
| Content-Transfer-Encoding | 7Bit |
| Content-Type | text/plain; charset="utf-8" |
| Sender | robomod@news.nic.it |
| List-ID | <linux-kernel.vger.kernel.org> |
| X-Mailing-List | linux-kernel@vger.kernel.org |
| Approved | robomod@news.nic.it |
| Lines | 30 |
| Organization | linux.* mail to news gateway |
| X-Original-Cc | "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>, Len Brown <lenb@kernel.org>, Robert Moore <robert.moore@intel.com>, Prakash Prashanth <pprakash@codeaurora.org>, linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org, lho@apm.com, Duc Dang <dhdang@apm.com>, devel@acpica.org |
| X-Original-Date | Fri, 21 Oct 2016 23:31:18 +0200 |
| X-Original-Message-ID | <9431714.tmtHQX6MJq@vostro.rjw.lan> |
| X-Original-References | <1476487221-20337-1-git-send-email-hotran@apm.com> |
| X-Original-Sender | linux-kernel-owner@vger.kernel.org |
| Xref | csiph.com linux.kernel:1506309 |
Show key headers only | View raw
On Friday, October 14, 2016 04:20:21 PM Hoan Tran wrote:
> When CONFIG_PCC is disabled, pcc_mbox_request_channel() needs to
> return ERR_PTR(-ENODEV), not a NULL pointer, as the callers of
> this function use IS_ERR() to check for error code.
>
> Signed-off-by: Duc Dang <dhdang@apm.com>
> Signed-off-by: Hoan Tran <hotran@apm.com>
> ---
> include/acpi/pcc.h | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/include/acpi/pcc.h b/include/acpi/pcc.h
> index 17a940a..8caa79c 100644
> --- a/include/acpi/pcc.h
> +++ b/include/acpi/pcc.h
> @@ -21,7 +21,7 @@ extern struct mbox_chan *pcc_mbox_request_channel(struct mbox_client *cl,
> static inline struct mbox_chan *pcc_mbox_request_channel(struct mbox_client *cl,
> int subspace_id)
> {
> - return NULL;
> + return ERR_PTR(-ENODEV);
> }
> static inline void pcc_mbox_free_channel(struct mbox_chan *chan) { }
> #endif
>
Applied.
Thanks,
Rafael
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PATCH] mailbox: PCC: Fix return value of pcc_mbox_request_channel() Hoan Tran <hotran@apm.com> - 2016-10-15 01:30 +0200 Re: [PATCH] mailbox: PCC: Fix return value of pcc_mbox_request_channel() "Rafael J. Wysocki" <rjw@rjwysocki.net> - 2016-10-21 23:30 +0200
csiph-web