Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp5215327imm; Tue, 12 Jun 2018 04:35:36 -0700 (PDT) X-Google-Smtp-Source: ADUXVKI4Q073xXBhm2RKbLNW66MyzXz2XLga8KGRGG9uuzihMh5ZqZhphBHvx15Y/qcLj+udO8wz X-Received: by 2002:a17:902:b683:: with SMTP id c3-v6mr2165pls.158.1528803335985; Tue, 12 Jun 2018 04:35:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1528803335; cv=none; d=google.com; s=arc-20160816; b=x2HvNhl0X+LiF9o05zKYrigipi32zpn3PC6WmLPcpdp7T/Tq0vp9Yzo6Q/Y/WF+EGX u/k0a8a+wUMk/a7R0WN/jrIMGFkGXK8koLvxxMlETvtmorhpkgM/30fFFGfzHAAsUx2B f4Au2E0gV6BIsIai+Xf+pTB6G4quFDmvwc33FBksj80AXc0VG8CUjs2cTQGhhlrg/rsf mv3PROwvGbgicL41IeJNhfBqqTBkL5nE+YlEiXAi21G5Opo3Qgy5JASbOpmjyFKGy70m gaN4Dzk1Ah55ymRuZ00yQYOKVDc+tQXGExqDiCu3CXJDavP8Pu6gYCPea3UwQ7N5A0MU lQUg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:arc-authentication-results; bh=RpPrh9cbJv9CqKMPtNVmT36hYkP9sYHqq7wfEvwMPCg=; b=BqM4bjVB6pIu9RAtjnGiH+oeOs+xQnn11tt9ZLTHMlplypBDCcTFKkPa2P2O7mS1z+ o79NNq/SJkZ+Ow94gDnVGNDcasVL9byMgVumz2xu/2Mqx3mTBKQfGXA5NlwVanGrOgTQ 07npq4/B3iBORX41FqP6M7bZ+BkjtLTzqCHPLpG21ey2xfXt9NBZyvdb+rmcBTkZg/PC MEt8Zr4n/+KfDxJBIJw47A5uC4gkY9grtlp6gKmj7w/j+lonYbA+kImPQL/cw9RsOHhc XvRIC+nQRAhKQDfJmgQFIDAUGLwcC63tAgYY/tCD6Nor9QjkEN+3e+i7ufTgCZ1sCgy6 264g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2017-10-26 header.b=mo4RvXbe; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d10-v6si578076pgf.515.2018.06.12.04.35.21; Tue, 12 Jun 2018 04:35:35 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2017-10-26 header.b=mo4RvXbe; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932811AbeFLLet (ORCPT + 99 others); Tue, 12 Jun 2018 07:34:49 -0400 Received: from aserp2120.oracle.com ([141.146.126.78]:57178 "EHLO aserp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932286AbeFLLer (ORCPT ); Tue, 12 Jun 2018 07:34:47 -0400 Received: from pps.filterd (aserp2120.oracle.com [127.0.0.1]) by aserp2120.oracle.com (8.16.0.22/8.16.0.22) with SMTP id w5CBLnjp050224; Tue, 12 Jun 2018 11:34:38 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=date : from : to : cc : subject : message-id : references : mime-version : content-type : in-reply-to; s=corp-2017-10-26; bh=RpPrh9cbJv9CqKMPtNVmT36hYkP9sYHqq7wfEvwMPCg=; b=mo4RvXbeLz0JvbuQarvGyENBFHu3NfMm5zZ64b2KHkfAobLpNePX+/IVXBnDOL+EqwNz waLzE7tDFObNGcU0uaQFHjBbyS3WxTmOE6kyg4a/+GabV4KKfTTN3EFz42kCGrClL86o Q3dhVfwaMv+nMqoVrZCgFmST7btb4p7ZY0k67Z5OxLVyI1gJrlH/Brec6Sxmkyfd4zj5 DuBbeh0TF1BPG1Ib+C2dwr1fk5deKHv/G9sKp9/dLBlCeTbV+CTrj/5kQsuOHay6HaOS HIn2oBok9a+bNFredMjDkY1o2TESCfuhpRrYTnKv6sSmmIUiQX599upacpAFXhzYRUOY 8w== Received: from aserv0022.oracle.com (aserv0022.oracle.com [141.146.126.234]) by aserp2120.oracle.com with ESMTP id 2jgecxgtcr-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 12 Jun 2018 11:34:38 +0000 Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by aserv0022.oracle.com (8.14.4/8.14.4) with ESMTP id w5CBYbej030045 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 12 Jun 2018 11:34:37 GMT Received: from abhmp0015.oracle.com (abhmp0015.oracle.com [141.146.116.21]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id w5CBYarY027120; Tue, 12 Jun 2018 11:34:36 GMT Received: from mwanda (/197.157.0.30) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Tue, 12 Jun 2018 04:34:36 -0700 Date: Tue, 12 Jun 2018 14:34:22 +0300 From: Dan Carpenter To: Zhouyang Jia Cc: Florian Schilhabel , devel@driverdev.osuosl.org, Greg Kroah-Hartman , linux-kernel@vger.kernel.org, Colin Ian King , Larry Finger Subject: Re: [PATCH] staging: rtl8712: add error handling for register_netdev Message-ID: <20180612113422.tkta6ynquy6lfy7s@mwanda> References: <1528773525-37564-1-git-send-email-jiazhouyang09@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1528773525-37564-1-git-send-email-jiazhouyang09@gmail.com> User-Agent: NeoMutt/20170609 (1.8.3) X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=8921 signatures=668702 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=562 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1805220000 definitions=main-1806120134 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jun 12, 2018 at 11:18:43AM +0800, Zhouyang Jia wrote: > When register_netdev fails, the lack of error-handling code may > cause unexpected results. > > This patch adds error-handling code after calling register_netdev. > It doesn't add any error handling. It just adds an error message. The error handling does look sort of messed up, but this isn't a useful patch. regards, dan carpenter