From patchwork Thu Sep 21 17:04:26 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Allen X-Patchwork-Id: 817132 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67; helo=vger.kernel.org; envelope-from=netdev-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="QQWKqL8V"; dkim-atps=neutral Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 3xykNg2FL6z9s3T for ; Fri, 22 Sep 2017 03:38:27 +1000 (AEST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751899AbdIURGQ (ORCPT ); Thu, 21 Sep 2017 13:06:16 -0400 Received: from mail-pg0-f66.google.com ([74.125.83.66]:36791 "EHLO mail-pg0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751787AbdIURGN (ORCPT ); Thu, 21 Sep 2017 13:06:13 -0400 Received: by mail-pg0-f66.google.com with SMTP id d8so3741557pgt.3; Thu, 21 Sep 2017 10:06:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=Y12Te/MOTC7TNqBll2t5kvv6nOvVAWpaZQYuDtEtHU8=; b=QQWKqL8VGJUt2TCxm3DOUvDsRZs0e8EYldAsU7qjrE8WoR47GrTYE7ZUa1c/WWS2wy wx9dVA1A1RVsQmztUPceAy4IOrR8Nb1swWkOTHFDJPvZfXxtDNwMlmAOzb3faZxnpn9n y2Mtp8AqFh4MywzLSd6plAmexBI3zYI3j7TJC4a2tIz14VZHO6I1hE36ejTL9io/nEaV r9gI/4oxBZ3WfoNbMOfQkhdVlkf1uNmvCuI6XSKl8NvLBBxh83QECNH1QzMQWffaA0cK 4npRDtC93wsojQwptkK6n3AFPFsxAXGCspTq48C7TgJzCU0XHozDh8KAvkszvRrGPu6E ilzw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=Y12Te/MOTC7TNqBll2t5kvv6nOvVAWpaZQYuDtEtHU8=; b=YOIcLtdwvYMUVSW4vHPNnoHJLDkmm8vIt3nwcscc390894i5KTPwCtqZTQiK6O7pFR dW5pV2bcUjrM2touz3J9vFCuF2Cg9Csk/x12R/Pr3XKQA//LVX+b0pTZWc6fJ/4nwC5r xP02NlWpQ/eJL75JoJnGFI5dmxdGGXjv25vtBSjQid85kSzcYp90G24rcZSMc1AF9/MF RyutpVz2Tu9OdFSucZjJ3ciPdJ0Oi+MLtki77KT6iybMV87KiVtJRb8nC0KZABenrH7O /n2fiU5/NRIOH9S9B5tQbUyvUOq0sJKyoXNjuPBMcHUJPke0+q3wfHm66y15gfJDkYZP +gUA== X-Gm-Message-State: AHPjjUhgsrWhniNqM+tQiGJT2nVIiLR9cnP5Owo1MrDZg7+wbhxZa/Zk vY/csmRk5oQvKfUg+5z9kOlV6GM9G7c= X-Google-Smtp-Source: AOwi7QDjciPEU8rFCglPQpiF8qUn09D7U5E7x8jDOOWHHa9Fzf76Kn5yRqLXRvnTxKNHiBIZTmmxVw== X-Received: by 10.84.217.138 with SMTP id p10mr6288984pli.400.1506013572852; Thu, 21 Sep 2017 10:06:12 -0700 (PDT) Received: from localhost.localdomain ([103.42.74.194]) by smtp.gmail.com with ESMTPSA id p12sm3174090pgn.90.2017.09.21.10.06.06 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 21 Sep 2017 10:06:11 -0700 (PDT) From: Allen Pais To: netdev@vger.kernel.org Cc: linux-kernel@vger.kernel.org, m.grzeschik@pengutronix.de, dmitry.tarnyagin@lockless.no, wg@grandegger.com, mkl@pengutronix.de, mark.einon@gmail.com, linux@armlinux.org.uk, pcnet32@frontier.com, f.fainelli@gmail.com, bcm-kernel-feedback-list@broadcom.com, venza@brownhat.org, ajk@comnets.uni-bremen.de, jes@trained-monkey.org, romieu@fr.zoreil.com, khc@pm.waw.pl, simon@thekelleys.org.uk, davem@davemloft.net, linux-can@vger.kernel.org, adi-buildroot-devel@lists.sourceforge.net, Allen Pais Subject: [PATCH 05/64] drivers : net: niu: use setup_timer() helper. Date: Thu, 21 Sep 2017 22:34:26 +0530 Message-Id: <1506013525-29291-6-git-send-email-allen.lkml@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1506013525-29291-1-git-send-email-allen.lkml@gmail.com> References: <1506013525-29291-1-git-send-email-allen.lkml@gmail.com> Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Use setup_timer function instead of initializing timer with the function and data fields. Signed-off-by: Allen Pais --- drivers/net/ethernet/sun/niu.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/net/ethernet/sun/niu.c b/drivers/net/ethernet/sun/niu.c index 6a4e8e1..bde19b3 100644 --- a/drivers/net/ethernet/sun/niu.c +++ b/drivers/net/ethernet/sun/niu.c @@ -6123,10 +6123,8 @@ static int niu_open(struct net_device *dev) err = niu_init_hw(np); if (!err) { - init_timer(&np->timer); + setup_timer(&np->timer, niu_timer, (unsigned long)np); np->timer.expires = jiffies + HZ; - np->timer.data = (unsigned long) np; - np->timer.function = niu_timer; err = niu_enable_interrupts(np, 1); if (err)