From patchwork Wed Jan 7 03:39:33 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chunyan Zhang X-Patchwork-Id: 42801 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ee0-f72.google.com (mail-ee0-f72.google.com [74.125.83.72]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 040F82062F for ; Wed, 7 Jan 2015 03:41:03 +0000 (UTC) Received: by mail-ee0-f72.google.com with SMTP id e53sf1057235eek.3 for ; Tue, 06 Jan 2015 19:41:02 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=8QiLy3EEgnJBWSIW+6QT+S2FBlo9Ke6vNvFaw335FFQ=; b=Kh+OxavmeR9PrbSzmU99HAlBKdsswy5ovwLZBnrpocCR9dwS5vJKuL5/ggkTy0PoFD QAjzo7vLNVwvwjvnnRemqQe5NM5wFyPQGeGCr7lYEJDJJhLGe4Ctxm65ortLNHSnGxXK 7z5Ntyqapl3Q6xpz7sgiVW9bji9aVCinf3T0wGXheStZSpxTZqZp9Lb29dyJftco/8wp woqThlpttBMqZjFzSQeIAvqSRpO8NRrHC4ajiNhUu5M+6UHaQkdXzuefsj69pHCJWgWh MsUvHhG227UJEdbFJvOU9y7goPVC6Ql5DCukCVh5FweLPJg/Ik2RkuRp+2l3J1RGh704 10qw== X-Gm-Message-State: ALoCoQlYeil7pHM8GVlDOjSL7mkoZhIfuPtO98jP+tLl1gCcbA6B67k1xxqm7dT0r9SvanryQEC2 X-Received: by 10.112.171.74 with SMTP id as10mr10429lbc.8.1420602062150; Tue, 06 Jan 2015 19:41:02 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.5.166 with SMTP id t6ls97443lat.38.gmail; Tue, 06 Jan 2015 19:41:01 -0800 (PST) X-Received: by 10.112.162.4 with SMTP id xw4mr738938lbb.89.1420602061976; Tue, 06 Jan 2015 19:41:01 -0800 (PST) Received: from mail-la0-f44.google.com (mail-la0-f44.google.com. [209.85.215.44]) by mx.google.com with ESMTPS id u9si444911lbw.113.2015.01.06.19.41.01 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 06 Jan 2015 19:41:01 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.44 as permitted sender) client-ip=209.85.215.44; Received: by mail-la0-f44.google.com with SMTP id gd6so1257800lab.3 for ; Tue, 06 Jan 2015 19:41:01 -0800 (PST) X-Received: by 10.112.30.71 with SMTP id q7mr788844lbh.41.1420602061879; Tue, 06 Jan 2015 19:41:01 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.9.200 with SMTP id c8csp1355603lbb; Tue, 6 Jan 2015 19:41:00 -0800 (PST) X-Received: by 10.68.236.67 with SMTP id us3mr1117196pbc.121.1420602059935; Tue, 06 Jan 2015 19:40:59 -0800 (PST) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c12si783138pdk.10.2015.01.06.19.40.59; Tue, 06 Jan 2015 19:40:59 -0800 (PST) Received-SPF: none (google.com: linux-kernel-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757040AbbAGDkx (ORCPT + 27 others); Tue, 6 Jan 2015 22:40:53 -0500 Received: from mail-pd0-f181.google.com ([209.85.192.181]:51308 "EHLO mail-pd0-f181.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755794AbbAGDku (ORCPT ); Tue, 6 Jan 2015 22:40:50 -0500 Received: by mail-pd0-f181.google.com with SMTP id v10so1879744pde.12 for ; Tue, 06 Jan 2015 19:40:49 -0800 (PST) X-Received: by 10.66.136.137 with SMTP id qa9mr1114310pab.129.1420602049733; Tue, 06 Jan 2015 19:40:49 -0800 (PST) Received: from chunyanzhangubtpc.spreadtrum.com ([203.160.240.81]) by mx.google.com with ESMTPSA id pf10sm261320pbc.82.2015.01.06.19.40.46 (version=TLSv1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 06 Jan 2015 19:40:48 -0800 (PST) From: Chunyan Zhang To: samuel@sortiz.org Cc: arnd@linaro.org, zhang.lyra@gmail.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/6] driver/net/irda: Removed all unused timeval variables Date: Wed, 7 Jan 2015 11:39:33 +0800 Message-Id: <1420601978-15866-2-git-send-email-zhang.chunyan@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1420601978-15866-1-git-send-email-zhang.chunyan@linaro.org> References: <1420601978-15866-1-git-send-email-zhang.chunyan@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: zhang.chunyan@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.44 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , In the file au1k_ir.c & via-ircc.h, there were two unused definitions of the timeval type members, so I removed them entirely in this patch. In other three files, the same problem is the rx_time member is only ever written, never read, so removed it entirely. Signed-off-by: Chunyan Zhang --- drivers/net/irda/au1k_ir.c | 3 --- drivers/net/irda/kingsun-sir.c | 3 --- drivers/net/irda/ks959-sir.c | 3 --- drivers/net/irda/mcs7780.c | 2 -- drivers/net/irda/mcs7780.h | 1 - drivers/net/irda/via-ircc.h | 4 ---- 6 files changed, 16 deletions(-) diff --git a/drivers/net/irda/au1k_ir.c b/drivers/net/irda/au1k_ir.c index e151205..44e4f38 100644 --- a/drivers/net/irda/au1k_ir.c +++ b/drivers/net/irda/au1k_ir.c @@ -24,7 +24,6 @@ #include #include #include -#include #include #include @@ -163,8 +162,6 @@ struct au1k_private { iobuff_t rx_buff; struct net_device *netdev; - struct timeval stamp; - struct timeval now; struct qos_info qos; struct irlap_cb *irlap; diff --git a/drivers/net/irda/kingsun-sir.c b/drivers/net/irda/kingsun-sir.c index e638893..fb5d162 100644 --- a/drivers/net/irda/kingsun-sir.c +++ b/drivers/net/irda/kingsun-sir.c @@ -114,7 +114,6 @@ struct kingsun_cb { (usually 8) */ iobuff_t rx_buff; /* receive unwrap state machine */ - struct timeval rx_time; spinlock_t lock; int receiving; @@ -235,7 +234,6 @@ static void kingsun_rcv_irq(struct urb *urb) &kingsun->netdev->stats, &kingsun->rx_buff, bytes[i]); } - do_gettimeofday(&kingsun->rx_time); kingsun->receiving = (kingsun->rx_buff.state != OUTSIDE_FRAME) ? 1 : 0; @@ -273,7 +271,6 @@ static int kingsun_net_open(struct net_device *netdev) skb_reserve(kingsun->rx_buff.skb, 1); kingsun->rx_buff.head = kingsun->rx_buff.skb->data; - do_gettimeofday(&kingsun->rx_time); kingsun->rx_urb = usb_alloc_urb(0, GFP_KERNEL); if (!kingsun->rx_urb) diff --git a/drivers/net/irda/ks959-sir.c b/drivers/net/irda/ks959-sir.c index e6b3804..8e6e0ed 100644 --- a/drivers/net/irda/ks959-sir.c +++ b/drivers/net/irda/ks959-sir.c @@ -187,7 +187,6 @@ struct ks959_cb { __u8 *rx_buf; __u8 rx_variable_xormask; iobuff_t rx_unwrap_buff; - struct timeval rx_time; struct usb_ctrlrequest *speed_setuprequest; struct urb *speed_urb; @@ -476,7 +475,6 @@ static void ks959_rcv_irq(struct urb *urb) bytes[i]); } } - do_gettimeofday(&kingsun->rx_time); kingsun->receiving = (kingsun->rx_unwrap_buff.state != OUTSIDE_FRAME) ? 1 : 0; } @@ -514,7 +512,6 @@ static int ks959_net_open(struct net_device *netdev) skb_reserve(kingsun->rx_unwrap_buff.skb, 1); kingsun->rx_unwrap_buff.head = kingsun->rx_unwrap_buff.skb->data; - do_gettimeofday(&kingsun->rx_time); kingsun->rx_urb = usb_alloc_urb(0, GFP_KERNEL); if (!kingsun->rx_urb) diff --git a/drivers/net/irda/mcs7780.c b/drivers/net/irda/mcs7780.c index e4d678f..bca6a1e 100644 --- a/drivers/net/irda/mcs7780.c +++ b/drivers/net/irda/mcs7780.c @@ -722,7 +722,6 @@ static int mcs_net_open(struct net_device *netdev) skb_reserve(mcs->rx_buff.skb, 1); mcs->rx_buff.head = mcs->rx_buff.skb->data; - do_gettimeofday(&mcs->rx_time); /* * Now that everything should be initialized properly, @@ -799,7 +798,6 @@ static void mcs_receive_irq(struct urb *urb) mcs_unwrap_fir(mcs, urb->transfer_buffer, urb->actual_length); } - do_gettimeofday(&mcs->rx_time); } ret = usb_submit_urb(urb, GFP_ATOMIC); diff --git a/drivers/net/irda/mcs7780.h b/drivers/net/irda/mcs7780.h index b10689b..a6e8f7d 100644 --- a/drivers/net/irda/mcs7780.h +++ b/drivers/net/irda/mcs7780.h @@ -116,7 +116,6 @@ struct mcs_cb { __u8 *fifo_status; iobuff_t rx_buff; /* receive unwrap state machine */ - struct timeval rx_time; spinlock_t lock; int receiving; diff --git a/drivers/net/irda/via-ircc.h b/drivers/net/irda/via-ircc.h index 7ce820e..ac15255 100644 --- a/drivers/net/irda/via-ircc.h +++ b/drivers/net/irda/via-ircc.h @@ -29,7 +29,6 @@ this program; if not, see . ********************************************************************/ #ifndef via_IRCC_H #define via_IRCC_H -#include #include #include #include @@ -106,9 +105,6 @@ struct via_ircc_cb { __u8 ier; /* Interrupt enable register */ - struct timeval stamp; - struct timeval now; - spinlock_t lock; /* For serializing operations */ __u32 flags; /* Interface flags */