From patchwork Fri Apr 5 23:55:11 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Chan X-Patchwork-Id: 13619591 X-Patchwork-Delegate: kuba@kernel.org Received: from mail-pf1-f169.google.com (mail-pf1-f169.google.com [209.85.210.169]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7563C374D3 for ; Fri, 5 Apr 2024 23:55:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.210.169 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712361333; cv=none; b=QQarlS6XsQ3SNgylLjMTSt6ngoFsCvEsfl/kLucz/yWn1G8FNt1Vw8Sc92P6Xg944JC+epYsp3vwHUuI3zpfGqjiuCkALZGj2CE/t3gieysLvmUdaoz/oRTluPzG6lYY0uqG01vWWA5bs4wqgWn7EDEo80RW04c5IUlcyOvoZ94= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712361333; c=relaxed/simple; bh=7xPlnYSjrmpNj6g5vLJQTqeTr8k5/AjwUO3thQOm7QE=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version:Content-Type; b=pIxWf4kBhScmy/vqQSVkSBXNZD99cFJBfJAw+0cJuvwyfcXnhgF2WFtzm2WsmAQZUaCPIwHHeoff3dBJfm/+4PcJluCpOjM+L1Vf+Gopx1PeRfW/R8ZF/dGa7ziyyxKLBv8j2RyfdQR2lMF7G8wElvvjblT0UvJIg0InnfV/ZUE= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=broadcom.com; spf=fail smtp.mailfrom=broadcom.com; dkim=pass (1024-bit key) header.d=broadcom.com header.i=@broadcom.com header.b=FsG1zIns; arc=none smtp.client-ip=209.85.210.169 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=broadcom.com Authentication-Results: smtp.subspace.kernel.org; spf=fail smtp.mailfrom=broadcom.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=broadcom.com header.i=@broadcom.com header.b="FsG1zIns" Received: by mail-pf1-f169.google.com with SMTP id d2e1a72fcca58-6ecfeefe94cso878897b3a.0 for ; Fri, 05 Apr 2024 16:55:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; t=1712361330; x=1712966130; darn=vger.kernel.org; h=mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:from:to:cc:subject:date:message-id:reply-to; bh=2WCC3IJqhv4SmaSMsO3I3VSMes2xHhZ2xVHKQJWcwgE=; b=FsG1zInsuU1bG7wvuGDClSrtAEgoZPSXkISvFxv2Jpt6a9DUd+GHdIoO6jWoJAYReL zWrpMF++8valsrmenM7l0ic3mQvu/y4jbZGeh3a0G5xnfh8a1yJqvEWfCxQhfB4VWq4u XAgUzcyOekYb/mpm2pbckMnsiljkxEsoxImCQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712361330; x=1712966130; h=mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=2WCC3IJqhv4SmaSMsO3I3VSMes2xHhZ2xVHKQJWcwgE=; b=MTyL7xhEOlCybxrqUqxkLb0xjNtwSNrLG50LaU3qMzc2KKI6CkpudhWTfaTPBd1yyA kLnS7pf+2/PfecwLckiwvN47p/VE53k5Y0fpQ5wF43RDrdgRTo+cUr2OuP6bPvB0cZn5 rnVlMzBz8FmGFYWnCVNqXFQdoADdUsliQLb+Uclro9QWOuqPFHSHcI7Z6AD44kTlHWs/ oTzvhC9O+6xTE7d5glhygLQG/TD8qKGs3XYbLvBzx7/bOcL84s/Cibm6oVj4lHx+RnHB lI8xpZbYFRDapCYSDqLs2lpTAAwDKnawSA3TEySM048f1StaRa590sjOhpJV5xE9Avv1 fW4w== X-Gm-Message-State: AOJu0YwdvIElSWaPir+d/jbxLgnD9J4SDYxn4CWB05EHBxhhqix6mTS2 eat3BujKU5yP9Hp1gaM6eitL8TkVZtXbbeUizbMU9NrOe27sL9r5DZdXd4o9Pw== X-Google-Smtp-Source: AGHT+IHmcheZ6GpqlQcuBe4tjBorOKcpy9N46GkWMRznIDYD/lSgTuO9wjGsorS4Y19P39ubAeqV9Q== X-Received: by 2002:a05:6a00:1490:b0:6ec:fc97:81a with SMTP id v16-20020a056a00149000b006ecfc97081amr4021368pfu.3.1712361329788; Fri, 05 Apr 2024 16:55:29 -0700 (PDT) Received: from lvnvda5233.lvn.broadcom.net ([192.19.161.250]) by smtp.gmail.com with ESMTPSA id it24-20020a056a00459800b006ea81423c65sm2162078pfb.148.2024.04.05.16.55.28 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Fri, 05 Apr 2024 16:55:28 -0700 (PDT) From: Michael Chan To: davem@davemloft.net Cc: netdev@vger.kernel.org, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, pavan.chebbi@broadcom.com, andrew.gospodarek@broadcom.com, Vikas Gupta Subject: [PATCH net 1/3] bnxt_en: Fix possible memory leak in bnxt_rdma_aux_device_init() Date: Fri, 5 Apr 2024 16:55:11 -0700 Message-Id: <20240405235513.64668-2-michael.chan@broadcom.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20240405235513.64668-1-michael.chan@broadcom.com> References: <20240405235513.64668-1-michael.chan@broadcom.com> Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Patchwork-Delegate: kuba@kernel.org From: Vikas Gupta If ulp = kzalloc() fails, the allocated edev will leak because it is not properly assigned and the cleanup path will not be able to free it. Fix it by assigning it properly immediately after allocation. Fixes: 303432211324 ("bnxt_en: Remove runtime interrupt vector allocation") Reviewed-by: Andy Gospodarek Signed-off-by: Vikas Gupta Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c b/drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c index 93f9bd55020f..a5f9c9090a6b 100644 --- a/drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c +++ b/drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c @@ -392,12 +392,13 @@ void bnxt_rdma_aux_device_init(struct bnxt *bp) if (!edev) goto aux_dev_uninit; + aux_priv->edev = edev; + ulp = kzalloc(sizeof(*ulp), GFP_KERNEL); if (!ulp) goto aux_dev_uninit; edev->ulp_tbl = ulp; - aux_priv->edev = edev; bp->edev = edev; bnxt_set_edev_info(edev, bp); From patchwork Fri Apr 5 23:55:12 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Chan X-Patchwork-Id: 13619592 X-Patchwork-Delegate: kuba@kernel.org Received: from mail-pf1-f175.google.com (mail-pf1-f175.google.com [209.85.210.175]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8D36D339A8 for ; Fri, 5 Apr 2024 23:55:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.210.175 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712361333; cv=none; b=PY0oG2LiCOvjH8hFDa1rYzVvVx+LuAsJp2RBHsBLoijZzd2diJLKIJb6cxX2l1DaMkd8FIOHB9PzUPu6Bn9yKq51cVS92Nh4RjNUF2lxOtjB0FqsslfiwJp7WXiu5AQ4MqDxKA3YcMbj/f2xmQ9h8Hu2BpCkoe2y7/qR7zbJJyA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712361333; c=relaxed/simple; bh=9gWKmcCsWbVaDwV9IeuExjh4W1rfrPqRztKFYw16kEs=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version:Content-Type; b=Upk0/OzGX2UIAK3gUGP6Ewq+Dc8ZKNDOe6YqyT9I+1V/TVYXoB5Y46jeF2HwVppCAm2M9aVVaO9xw4ZUDX9i8pvLFQLNBJQ0awPceQNJB2+8qzSXOlGWYU6pevn7WBKQHfMR/7X9kdCUZsdoy7fTTXM+FgLsWQYJGbwSDH3Yfsw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=broadcom.com; spf=fail smtp.mailfrom=broadcom.com; dkim=pass (1024-bit key) header.d=broadcom.com header.i=@broadcom.com header.b=PnT2MWJM; arc=none smtp.client-ip=209.85.210.175 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=broadcom.com Authentication-Results: smtp.subspace.kernel.org; spf=fail smtp.mailfrom=broadcom.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=broadcom.com header.i=@broadcom.com header.b="PnT2MWJM" Received: by mail-pf1-f175.google.com with SMTP id d2e1a72fcca58-6ecff9df447so1324791b3a.1 for ; Fri, 05 Apr 2024 16:55:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; t=1712361332; x=1712966132; darn=vger.kernel.org; h=mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:from:to:cc:subject:date:message-id:reply-to; bh=6lubQUxIR+Kl2VFu8D/MJscgtN17uLwa5eizPrrHYeA=; b=PnT2MWJMGFn0FgWsN3veFiTrNhZNTMySsRigeY1Fkbn/tdbe/ODMwA+2DmngnaVLlB JiYhpnidZROd+e8zYt1jvRAlLbFzwIVj+6DC5YgXZVr1taYrwbG45ij7mQDLSiF6nn/E unxb1eTb+LNyvuIuqriKDDfZN3tTnQh1CCwWY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712361332; x=1712966132; h=mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=6lubQUxIR+Kl2VFu8D/MJscgtN17uLwa5eizPrrHYeA=; b=gJzCA2FFqaKTjLIAPs2Xku9w27Akv2l/c1m7TNLhyMfxLjGs7rbbIRgLHTEAma7y/H ZJiv8Dd/Or1KAp2JAqnEN6dlUaRENRBDgMRiUeOBof2LzQHWnYzjQyWHnzxqOYN2QoBt E4GkQL8MnuLFn8J8ii06XIK0/gH4d+xkESgR/STAnDmhrgBZUHsAw9NI2nKaCmavI/yE A8dIANvX03kK6jvYWBKhVpOc6djLofn4Wtb/wE8nLKSih80KV/XEX5bqrP3bCU8GWBDg wM0HlIQFsOdEOomNcEW6uLvJGFiHRxlpRYMC9lqgA1s4rabgqbFztU1WMzw2r9Y4xb+p //fg== X-Gm-Message-State: AOJu0YwQs81YSvfVw1rWCKezKWb0PVEqAXGmvgsN4crW0FJfICPgOmHa M+wMn+K9DX41Aeg4816wJ322NNA1hG37XmfASDT7bgTbQyKNWoHHvknPqV/U5w== X-Google-Smtp-Source: AGHT+IGRpFLdlMwtPvwzhr2cEdwr/kKUGqzhWY9vqhH3hOCQZblskTiWLBYIJV4rczEqL9O7nE4rYA== X-Received: by 2002:a05:6a00:93a3:b0:6ea:d0f3:a152 with SMTP id ka35-20020a056a0093a300b006ead0f3a152mr3404589pfb.26.1712361331223; Fri, 05 Apr 2024 16:55:31 -0700 (PDT) Received: from lvnvda5233.lvn.broadcom.net ([192.19.161.250]) by smtp.gmail.com with ESMTPSA id it24-20020a056a00459800b006ea81423c65sm2162078pfb.148.2024.04.05.16.55.30 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Fri, 05 Apr 2024 16:55:30 -0700 (PDT) From: Michael Chan To: davem@davemloft.net Cc: netdev@vger.kernel.org, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, pavan.chebbi@broadcom.com, andrew.gospodarek@broadcom.com, Vikas Gupta Subject: [PATCH net 2/3] bnxt_en: Fix error recovery for RoCE ulp client Date: Fri, 5 Apr 2024 16:55:12 -0700 Message-Id: <20240405235513.64668-3-michael.chan@broadcom.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20240405235513.64668-1-michael.chan@broadcom.com> References: <20240405235513.64668-1-michael.chan@broadcom.com> Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Patchwork-Delegate: kuba@kernel.org From: Vikas Gupta Since runtime MSIXs vector allocation/free has been removed, the L2 driver needs to repopulate the MSIX entries for the ulp client as the irq table may change during the recovery process. Fixes: 303432211324 ("bnxt_en: Remove runtime interrupt vector allocation") Reviewed-by: Andy Gospodarek Signed-off-by: Vikas Gupta Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c b/drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c index a5f9c9090a6b..195c02dc0683 100644 --- a/drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c +++ b/drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c @@ -210,6 +210,9 @@ void bnxt_ulp_start(struct bnxt *bp, int err) if (err) return; + if (edev->ulp_tbl->msix_requested) + bnxt_fill_msix_vecs(bp, edev->msix_entries); + if (aux_priv) { struct auxiliary_device *adev; From patchwork Fri Apr 5 23:55:13 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Chan X-Patchwork-Id: 13619593 X-Patchwork-Delegate: kuba@kernel.org Received: from mail-oa1-f42.google.com (mail-oa1-f42.google.com [209.85.160.42]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B6247376F5 for ; Fri, 5 Apr 2024 23:55:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.160.42 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712361335; cv=none; b=MXj9MRGQZB4jJrvfMBJ73sVIE9KvPFOQVSqecX6IhMGcI04Q2Hf4V4Oi0XNS5EdkbOb6ppjTDNullIkXl40hu4NOP8WO8QEq4envW2fgEyhR89YRmw3cTO3wIK1gm4OFcArqv13kHeRVBQOrV2FNIvvHi/XStM92rUydcxHmd8c= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712361335; c=relaxed/simple; bh=tMLDuYtychh33OOhY9BHQHX16boKULM8p0yu6v8K5O8=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version:Content-Type; b=WbD5ZpRfXFw2OJXLe80Fo1cyA6PiUKhbthPoMH2+rew6amLOCkxWRFElfBB0uGNaO7RwtaFzEje7fveSbq9CsjLI1iZAUWDgS6cVg5hqA3X4CSAebezUeOXVx3ulkHG0vWq9jZgRXzQmM/AQZfxOM2bFp4T5VOTMUE1rINE1r1w= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=broadcom.com; spf=fail smtp.mailfrom=broadcom.com; dkim=pass (1024-bit key) header.d=broadcom.com header.i=@broadcom.com header.b=LbLdVrAh; arc=none smtp.client-ip=209.85.160.42 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=broadcom.com Authentication-Results: smtp.subspace.kernel.org; spf=fail smtp.mailfrom=broadcom.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=broadcom.com header.i=@broadcom.com header.b="LbLdVrAh" Received: by mail-oa1-f42.google.com with SMTP id 586e51a60fabf-22ea24c9215so1487541fac.0 for ; Fri, 05 Apr 2024 16:55:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; t=1712361333; x=1712966133; darn=vger.kernel.org; h=mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:from:to:cc:subject:date:message-id:reply-to; bh=+PN+auHSkOKZUcIL1blqDd2MqE91KF9mTXcFFEvChwQ=; b=LbLdVrAh2wLrk4vbD7XXHS8HbXGEg7LJ58dOpskudj6Z/jzKEbAQPgfxQDRmQLRdRo 2hek1nUGHXXAAsHHWYEMzn79UsdZ0sY9S+FxbbSfw+PVe22nEMJnqFpGyln+dtko2+u8 BzntSJJOa1Oy1rHRsM2Or1J21h629FjNto14s= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712361333; x=1712966133; h=mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=+PN+auHSkOKZUcIL1blqDd2MqE91KF9mTXcFFEvChwQ=; b=vRxpFFnwV0aTGNtHGgUFFjSDsOleJfhU89VaZfag6yk0W0+w3i2t7kUeQ+wJj0lR0p b6DxarswLCLaGQ5djuPkmlfYS4OLzaM6E2yxrisU1VqPOKrPs0TfwhpJ/KsvHz7okk2o 4tPmkVbaeL3a9R3z3rOBhzunwr7lJdiUQlwyRzHMrmv9qW+bErxSOX6AS78DVa8MlPoa qbobL3qWMoTrfmK4xSD+iyQe8qj3l8z+3rqcx16+6FR4rgQgEissg6PhgFYoXx3awUGD VdhQiXtbWdQY5BkkWU40bn4ByXg2o/3+cL2cVikd5iBoZIYWmHhNu9YQ6hLMjayoxdZq XVjg== X-Gm-Message-State: AOJu0YxkWR8u/r5bGLQLau/v8cxO8cr46SvIeCVS/d7Od8q3pcGmSma6 bAyKQ8smcZPzXxPfsxOIhg5IIWGwxAybILidrUG0HF0+TMaGig4C/ky5/tuYix0OwwK6Gs5tsTA = X-Google-Smtp-Source: AGHT+IHdUxKMn7mPnUdiH3boaEybH8WKkE9+sccxXuoISHV3/0qB41+/DNHuQVihiLYuytYKU+x89w== X-Received: by 2002:a05:6870:1609:b0:22e:9aec:e8fe with SMTP id b9-20020a056870160900b0022e9aece8femr2951964oae.47.1712361332617; Fri, 05 Apr 2024 16:55:32 -0700 (PDT) Received: from lvnvda5233.lvn.broadcom.net ([192.19.161.250]) by smtp.gmail.com with ESMTPSA id it24-20020a056a00459800b006ea81423c65sm2162078pfb.148.2024.04.05.16.55.31 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Fri, 05 Apr 2024 16:55:32 -0700 (PDT) From: Michael Chan To: davem@davemloft.net Cc: netdev@vger.kernel.org, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, pavan.chebbi@broadcom.com, andrew.gospodarek@broadcom.com, Kalesh AP Subject: [PATCH net 3/3] bnxt_en: Reset PTP tx_avail after possible firmware reset Date: Fri, 5 Apr 2024 16:55:13 -0700 Message-Id: <20240405235513.64668-4-michael.chan@broadcom.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20240405235513.64668-1-michael.chan@broadcom.com> References: <20240405235513.64668-1-michael.chan@broadcom.com> Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Patchwork-Delegate: kuba@kernel.org From: Pavan Chebbi It is possible that during error recovery and firmware reset, there is a pending TX PTP packet waiting for the timestamp. We need to reset this condition so that after recovery, the tx_avail count for PTP is reset back to the initial value. Otherwise, we may not accept any PTP TX timestamps after recovery. Fixes: 118612d519d8 ("bnxt_en: Add PTP clock APIs, ioctls, and ethtool methods") Reviewed-by: Kalesh AP Signed-off-by: Pavan Chebbi Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c index 493b724848c8..57e61f963167 100644 --- a/drivers/net/ethernet/broadcom/bnxt/bnxt.c +++ b/drivers/net/ethernet/broadcom/bnxt/bnxt.c @@ -11758,6 +11758,8 @@ static int __bnxt_open_nic(struct bnxt *bp, bool irq_re_init, bool link_re_init) /* VF-reps may need to be re-opened after the PF is re-opened */ if (BNXT_PF(bp)) bnxt_vf_reps_open(bp); + if (bp->ptp_cfg) + atomic_set(&bp->ptp_cfg->tx_avail, BNXT_MAX_TX_TS); bnxt_ptp_init_rtc(bp, true); bnxt_ptp_cfg_tstamp_filters(bp); bnxt_cfg_usr_fltrs(bp);