From nobody Mon Nov 25 12:37:03 2024 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id EA6861D3644 for ; Mon, 28 Oct 2024 07:34:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=193.142.43.55 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730100892; cv=none; b=tpmvdwsffzdhX3nq8XXKYCgwVxIUxLY+3CX4C9GRS1va0yEGWZVXJuP3AX01DbsC43bo0lX7Zp9iLOTMjo7L0YC5zWZu/vKhq1RkXI4XEcHZWCiqr6+1jlZN7NC9Juppc0nVknjR2tbOQEpnKWXvYncMWHfQUTdjTrRpbJuX9cM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730100892; c=relaxed/simple; bh=AyFqTh/LTXdnFtVjfZsqUZtU1Ntr6JSA0nB/tk5Lovw=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=UplzCvNBV0FoHt3zjgX4w5mfLp/p2nSBe9UGWFlfE2yaauIomskRmG/H7wA5t22mOB3dfW+yAley+XVXgmCnFvygw7WhW4Om0lZgAwv59MFEaOHZc54J6DRyCdksocnjCZkxp0B3ROAv8TeaadFYoEZzRqOH3o+ZE86UNu7M19I= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de; spf=pass smtp.mailfrom=linutronix.de; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=b3z9JEsN; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=MxFHg79Z; arc=none smtp.client-ip=193.142.43.55 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linutronix.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="b3z9JEsN"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="MxFHg79Z" From: Nam Cao DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1730100888; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=5fM64bpc0cXbY46rFUm7HVL20B9YCPcyUvXqkWIDluk=; b=b3z9JEsNl8p0Cnn4U5Pur9IjWd7HVUU4nB/We2YjA/aHythZx1TTGOu9sD0v6zikGapx3b MmTkcatUQ7Op0Aesy9TKbWHKvhdBuSKd586SmS9+bEM9ysEvIC2LNFIgWAy+ztKqxMtY2+ 3Z7PzmC48AtCEzc430aLeTaK6USo5pY0lQFu2/BbF6wd6OtQ4SVN9jQn2pWntrLvgXgDAs h5yGRNJU4zbWmVUhZKQ6WFPZIxjSRT124nWosI3F/3M+PQy01UQMQC3GsBbytDApSNVQTm YUOOffs7AzahQha2olmjWTC+zQ9ues56lWAjWt/qrYLko/Sg+4XuzJizsa1XiQ== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1730100888; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=5fM64bpc0cXbY46rFUm7HVL20B9YCPcyUvXqkWIDluk=; b=MxFHg79Z6Ge0F+8kd1x2lPFS1TM4G3MBAfAyGeh7ZzgusZbaXH8ES/h0BfdVhRG6xU6eBk Ncd7t6T7NODlMoDA== To: Anna-Maria Behnsen , Frederic Weisbecker , Thomas Gleixner , Andreas Hindborg , Alice Ryhl , Miguel Ojeda , Kees Cook , linux-kernel@vger.kernel.org Cc: Nam Cao , Jakub Kicinski , Paolo Abeni Subject: [PATCH 09/24] net: ethernet: cortina: Switch to use hrtimer_setup() Date: Mon, 28 Oct 2024 08:34:22 +0100 Message-Id: In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" There is a newly introduced hrtimer_setup() which will replace hrtimer_init(). This new function is similar to the old one, except that it also sanity-checks and initializes the timer's callback function. Switch to use this new function. Patch was created by using Coccinelle. Signed-off-by: Nam Cao --- Cc: Jakub Kicinski Cc: Paolo Abeni --- drivers/net/ethernet/cortina/gemini.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/net/ethernet/cortina/gemini.c b/drivers/net/ethernet/c= ortina/gemini.c index 73e1c71c5092..5347431a089f 100644 --- a/drivers/net/ethernet/cortina/gemini.c +++ b/drivers/net/ethernet/cortina/gemini.c @@ -1833,9 +1833,8 @@ static int gmac_open(struct net_device *netdev) gmac_enable_tx_rx(netdev); netif_tx_start_all_queues(netdev); =20 - hrtimer_init(&port->rx_coalesce_timer, CLOCK_MONOTONIC, - HRTIMER_MODE_REL); - port->rx_coalesce_timer.function =3D &gmac_coalesce_delay_expired; + hrtimer_setup(&port->rx_coalesce_timer, &gmac_coalesce_delay_expired, CLO= CK_MONOTONIC, + HRTIMER_MODE_REL); =20 netdev_dbg(netdev, "opened\n"); =20 --=20 2.39.5