[PATCH] tty: serial: cpm_uart: Fix behaviour for non existing GPIOs

2020-06-06 Thread Christophe Leroy
devm_gpiod_get_index() doesn't return NULL but -ENOENT when the requested GPIO doesn't exist, leading to the following messages: [2.742468] gpiod_direction_input: invalid GPIO (errorpointer) [2.748147] can't set direction for gpio #2: -2 [2.753081] gpiod_direction_input: invalid GPIO

Re: [PATCH v10 4/6] powerpc/papr_scm: Improve error logging and handling papr_scm_ndctl()

2020-06-06 Thread Vaibhav Jain
Hi Ira and Dan, Thanks for reviewing this patch. Have updated the patch based on your feedback to upadate cmd_rc only when the nd_cmd was handled and return '0' in that case. Other errors in case the nd_cmd was unrecognized or invalid result in error returned from this functions as you suggested.

Re: [PATCH v10 6/6] powerpc/papr_scm: Implement support for PAPR_PDSM_HEALTH

2020-06-06 Thread Vaibhav Jain
Ira Weiny writes: > On Fri, Jun 05, 2020 at 05:11:36AM +0530, Vaibhav Jain wrote: >> This patch implements support for PDSM request 'PAPR_PDSM_HEALTH' >> that returns a newly introduced 'struct nd_papr_pdsm_health' instance >> containing dimm health information back to user space in response to >

Re: [PATCH v10 6/6] powerpc/papr_scm: Implement support for PAPR_PDSM_HEALTH

2020-06-06 Thread Segher Boessenkool
On Sat, Jun 06, 2020 at 06:04:11PM +0530, Vaibhav Jain wrote: > >> + /* update health struct with various flags derived from health bitmap */ > >> + health = (struct nd_papr_pdsm_health) { > >> + .dimm_unarmed = p->health_bitmap & PAPR_PMEM_UNARMED_MASK, > >> + .dimm_bad_shutdow