From mboxrd@z Thu Jan 1 00:00:00 1970 From: SF Markus Elfring Date: Sun, 29 Oct 2017 11:50:37 +0000 Subject: Re: [PATCH] ravb: Use common error handling code in ravb_probe() Message-Id: <3b700d27-2da5-b7d0-13f0-e55a7df4a24d@users.sourceforge.net> List-Id: References: <2839c3c2-0116-7549-6ff4-a49eb0a52298@users.sourceforge.net> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Geert Uytterhoeven , "netdev@vger.kernel.org" , Linux-Renesas Cc: Dan Carpenter , "David S. Miller" , Eugeniu Rosca , Kazuya Mizuguchi , Masaru Nagai , =?UTF-8?Q?Niklas_S=c3=b6derlund?= , Sergei Shtylyov , Simon Horman , Yuval Shaia , LKML , "kernel-janitors@vger.kernel.org" >> @@ -2069,10 +2069,9 @@ static int ravb_probe(struct platform_device *pdev) >> irq = platform_get_irq_byname(pdev, "ch22"); >> else >> irq = platform_get_irq(pdev, 0); >> - if (irq < 0) { >> - error = irq; >> - goto out_release; >> - } >> + if (irq < 0) >> + goto failure_indication; > > IMHO, it's really confusing that "irq" contains the error code, not "error". > Especially when jumping to a meaningless label named "failure_indication" > ("irq_failure" would be more intuitive). Thanks for your constructive feedback. > So I prefer the original code, regardless of the label name. Can another attempt make sense to concentrate the setting of a variable at the end of this function with more pleasing identifiers? Regards, Markus