Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp2603638ybe; Thu, 12 Sep 2019 11:58:09 -0700 (PDT) X-Google-Smtp-Source: APXvYqxUwa9AhPAQ4XexdVeCrjiLFLtZYl6DS3v00wtuPMt5ZUt/fbHbRfToMkE6wvEBwSP0kJbz X-Received: by 2002:a17:906:3746:: with SMTP id e6mr37031414ejc.35.1568314689740; Thu, 12 Sep 2019 11:58:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568314689; cv=none; d=google.com; s=arc-20160816; b=Egw9J4xPojnByCkZ7lNnnhjNYPEtvVC1XsccOMWofbcAMZkxJ7CAPKzJFEdZCyJba0 1lkg/lNLHdP5d9AJ9e6RsVQhUHvwVw9MPjHo1/9Pd0gAdMlryZVQNbdHzXVfV3sU7jHC qbyGTps882Cbeb+ziLZ2JsWxerT+E4/qz5ecHJf3BwhtfsmnhztqILLXrycT9Tsgonxg ZPAnWG3dmv6FTf8LPZ1f0+xEFVYLyMMSkfIUOAnyfjp576GTI7DjUcJ3IiqhPrjf4c+4 3CEZZ1ud4HBhae6epHDGd02iB0TO69u67wYrCqQV4D4uPEnOCGmjd8UR/hN6hKfbfjIm dbhQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:date:subject:cc :to:from; bh=BSfnjRZ2SstEQMgS9ALJruOx50wdezAyl3Zc3WXWTjM=; b=IEvQHCQiXaR3gKvGigBcCUaHGoXhVlC4/AfdrlbhfslomQw8eSJKOSv8Zg5Rkuo8Zj NVGl7q2HBAgr/kQ0kz9CJRfy+5BcfeJVIYCLhJV77GBl+2mHcKWc9+nPsgC7cgJPF6SX TEhV9ipRhUaU0xwmXRatbS7UQQqrLW03kaea16w2MbBqJTPF7CMHZR4kJiU0HrOmdW7X zUgMWyMyH/CIxz1kH/8UmfJwYqs6Yzkcf2+mmfFBjrM+Aw5hEEQ0dB/Wa05/Gnf0xwHX cT1lkNe4MBERY18NHng46Fyn4h5nouj1QghrJd7hjy6y0KkpufatliAvtXE+PDRLFMQS ZZFw== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m26si13386238eji.61.2019.09.12.11.57.46; Thu, 12 Sep 2019 11:58:09 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730482AbfILRAf (ORCPT + 99 others); Thu, 12 Sep 2019 13:00:35 -0400 Received: from szxga04-in.huawei.com ([45.249.212.190]:2218 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729855AbfILQzn (ORCPT ); Thu, 12 Sep 2019 12:55:43 -0400 Received: from DGGEMS407-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id BD85C710C0A98E5A65C6; Fri, 13 Sep 2019 00:55:39 +0800 (CST) Received: from linux-ibm.site (10.175.102.37) by DGGEMS407-HUB.china.huawei.com (10.3.19.207) with Microsoft SMTP Server id 14.3.439.0; Fri, 13 Sep 2019 00:55:29 +0800 From: zhong jiang To: CC: , , Subject: [PATCH] drivers/misc: Remove unneeded variable in st_tty_open Date: Fri, 13 Sep 2019 00:52:27 +0800 Message-ID: <1568307147-43468-1-git-send-email-zhongjiang@huawei.com> X-Mailer: git-send-email 1.7.12.4 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.175.102.37] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org st_tty_open do not need local variable to store different value, Hence just remove it. Signed-off-by: zhong jiang --- drivers/misc/ti-st/st_core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/misc/ti-st/st_core.c b/drivers/misc/ti-st/st_core.c index 7d9e23a..2ae9948 100644 --- a/drivers/misc/ti-st/st_core.c +++ b/drivers/misc/ti-st/st_core.c @@ -708,7 +708,6 @@ long st_write(struct sk_buff *skb) */ static int st_tty_open(struct tty_struct *tty) { - int err = 0; struct st_data_s *st_gdata; pr_info("%s ", __func__); @@ -731,7 +730,8 @@ static int st_tty_open(struct tty_struct *tty) */ st_kim_complete(st_gdata->kim_data); pr_debug("done %s", __func__); - return err; + + return 0; } static void st_tty_close(struct tty_struct *tty) -- 1.7.12.4