Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752133Ab3FJIAO (ORCPT ); Mon, 10 Jun 2013 04:00:14 -0400 Received: from e06smtp17.uk.ibm.com ([195.75.94.113]:52968 "EHLO e06smtp17.uk.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751552Ab3FJIAM (ORCPT ); Mon, 10 Jun 2013 04:00:12 -0400 Date: Mon, 10 Jun 2013 10:00:00 +0200 From: Michael Holzheu To: Maxim Uvarov Cc: Vivek Goyal , Heiko Carstens , "kexec@lists.infradead.org" , Jan Willeke , linux-kernel@vger.kernel.org, HATAYAMA Daisuke , Martin Schwidefsky Subject: Re: [PATCH v5 3/5] vmcore: Introduce remap_oldmem_pfn_range() Message-ID: <20130610100000.23743ea1@holzheu> In-Reply-To: References: <1370624161-2298-1-git-send-email-holzheu@linux.vnet.ibm.com> <1370624161-2298-4-git-send-email-holzheu@linux.vnet.ibm.com> Organization: IBM X-Mailer: Claws Mail 3.8.0 (GTK+ 2.24.10; i686-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-TM-AS-MML: No X-Content-Scanned: Fidelis XPS MAILER x-cbid: 13061007-0542-0000-0000-0000057E6719 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 795 Lines: 30 On Sat, 8 Jun 2013 11:38:00 +0400 Maxim Uvarov wrote: [snip] > > +static int copy_to(void *target, void *src, size_t size, int > > userbuf) +{ > > + if (userbuf) { > > + if (copy_to_user(target, src, size)) > > + return -EFAULT; > > + return 0; > > + } else { > > + memcpy(target, src, size); > > + return 0; > > + } > > +} > > > > It is better to do return 0 in the end of function. Sure, I will change that. Thanks! Michael -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/