From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755737AbbFUQSJ (ORCPT ); Sun, 21 Jun 2015 12:18:09 -0400 Received: from shards.monkeyblade.net ([149.20.54.216]:46361 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751928AbbFUQSC (ORCPT ); Sun, 21 Jun 2015 12:18:02 -0400 Date: Sun, 21 Jun 2015 09:29:48 -0700 (PDT) Message-Id: <20150621.092948.394430183523491972.davem@davemloft.net> To: Alexey.Brodkin@synopsys.com Cc: netdev@vger.kernel.org, peppe.cavallaro@st.com, arc-linux-dev@synopsys.com, linux-kernel@vger.kernel.org, stable@vger.kernel.org Subject: Re: [PATCH] stmmac: explicitly zero des0 & des1 on init From: David Miller In-Reply-To: <1434476441-18241-1-git-send-email-abrodkin@synopsys.com> References: <1434476441-18241-1-git-send-email-abrodkin@synopsys.com> X-Mailer: Mew version 6.4 on Emacs 23.4 / Mule 6.0 (HANACHIRUSATO) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Sun, 21 Jun 2015 09:18:02 -0700 (PDT) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Alexey Brodkin Date: Tue, 16 Jun 2015 20:40:41 +0300 > Current implementtion of descriptor init procedure only takes care about > ownership flag. While it is perfectly possible to have underlying memory > filled with garbage on boot or driver installation. > > And randomly set flags in non-zeroed des0 and des1 fields may lead to > unpredictable behavior of the GMAC DMA block. > > Solution to this problem is as simple as explicit zeroing of both des0 > and des1 fields of all buffer descriptors. > > Signed-off-by: Alexey Brodkin If you need the memory zero initialized, use dma_zalloc_coherent(). -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in Please read the FAQ at http://www.tux.org/lkml/