Received: by 10.192.165.156 with SMTP id m28csp551442imm; Fri, 13 Apr 2018 03:57:55 -0700 (PDT) X-Google-Smtp-Source: AIpwx4/3/llNpni9Nbsg9aw9dP9bAHh6G0TSOkCSKDW/Uu0jPs5ZJvPkXxE5nRHcE1cdQer1h4QK X-Received: by 10.98.170.13 with SMTP id e13mr11041868pff.137.1523617075018; Fri, 13 Apr 2018 03:57:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1523617074; cv=none; d=google.com; s=arc-20160816; b=rFbygc6R0VQJdbc2m71vk1rhizCRkZZ5QwcS7NSXFCd0YMU6nmMg5wJ5fAqge0ovb7 TNvoeICcCfrU4fDwr0fjv1STTu8YZKlBFNppLyYxMRnOTpAC/IKhQEzVq7PlmTuaLTxx rqnIk9JCJgSTOnwz8PWl6mxadH82rgBUJOo6qq8/KxYoTeRNnCY3NcJBtyR9pAovJAS7 +wQg1tg/60YxLw+6j3+7c6aM0hdMiRpmrpxstZjEQT2zfEHpaPB0vhezgKQU2/ptE+iD 78qDb4jaIsCrSRGp52C20bwrD2YxuFjcDjQbV8Nty2+MeowYisoH5Wb1lCBMgxyTh+pX y8lA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature :arc-authentication-results; bh=MBGdp3d1Qmla4txmCuXYkGKHAdt/O0defUF9F1/yTnk=; b=G+5RFL80cOfDR7FLLXQ9D1RqBXViaF+kOUMAd1tK5HpuEfOK34qL9QbO4G0oFXAzaR kwspKLrcIJ2FEnCXujL96pHDCEL6x11503g9kb7NJ8YiRS22P/eLDyHNpYt5gp+VYEcW gT/g3+BjhK2QnB4EHY6akZWj/YHNGdH0dkZV5zIXV/nVE32accraJp3No2+ZWu+ALs6u 5gduj+6TAnIU6l88M4lWKFEKJvtxeyeix4TXSrXT2sqsEeN+lDzozCb6KCEQ+u3HHLq2 Nfw5QJ3rvCaxgWVEuQyr21stY/Re5nASNAd33o2vk3y08f2poNvMcG3mjDRTT01csio2 2z8Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=Q2obSrnQ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f3-v6si5298248plr.453.2018.04.13.03.57.41; Fri, 13 Apr 2018 03:57:54 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=Q2obSrnQ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754273AbeDMKkZ (ORCPT + 99 others); Fri, 13 Apr 2018 06:40:25 -0400 Received: from mail-qk0-f193.google.com ([209.85.220.193]:46419 "EHLO mail-qk0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750973AbeDMKkX (ORCPT ); Fri, 13 Apr 2018 06:40:23 -0400 Received: by mail-qk0-f193.google.com with SMTP id l16so7561063qke.13; Fri, 13 Apr 2018 03:40:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=MBGdp3d1Qmla4txmCuXYkGKHAdt/O0defUF9F1/yTnk=; b=Q2obSrnQmknEF2mdb9rCa0aeJupaGGoO/CXcFtf2AX3IFDGr3H3EJSTwEl5f2SxQ9D WiIi+BS2L32/yoj7GR+z8BZf/FiVtwDsSVGTT4IX/U95UCbDz2c0QSC0/4pCCEC50HsJ KbyQ+UGTxBiTFwKAp7kbtKfiq6ta5kPOUQlRQqqrj/9//VNcpUZIsgIcrY8ur5jjcgW0 zkKWcBqi/CSluseT1PPtZMOKZtoUvvMxDpRMeN7RIYtyiu2jzB/iSziOEXCK47Q+y8jx sG9t1FiJOaD8UNCgG5Hcj5fU3XaV258f6idoZ8M2lqL0UdKutyyGZKm4SMzRS/57idnT PAug== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=MBGdp3d1Qmla4txmCuXYkGKHAdt/O0defUF9F1/yTnk=; b=uWkljsq1tEn21POcYnz1fZ7rAKE6eIDM4zBzcz7pYrtBVMwBJbdCsxyYQDlze3Zhvm xhN9nwKO0lAqtTc07FSsf7HQE5bMGAcqJNpdRxU7cRDn4NJlv9UpefWrNR1nrfSwi7KC lof0UXlRWLPpssWLpKYMxSh+xAxmbByV/8WZs3zMAZYeiyj0vR1DlVp50fQSsBD6Oh+v 9IWf0mGUTMbKbraVtgXHyp6OlGUKicST6sCvkgTuJIVcwIVuedpmzoUyIYXkgGp2NxNF vF8gNYMreyef3szVTZqmzSpN2WUKmCTAl7U8fCJMTgeSkubUKzvhFz77x3HwXTDKlUDu Jh+Q== X-Gm-Message-State: ALQs6tCS8MiuvZ/bjjLcdZ/vU3AELzPnOX//JO57r8jgu0eOx0FWeQZP 6DnPe6dS1IInoZ9li2wu9sDFny8Cg58P5SibbNo= X-Received: by 10.55.24.214 with SMTP id 83mr3949181qky.267.1523616022787; Fri, 13 Apr 2018 03:40:22 -0700 (PDT) MIME-Version: 1.0 Received: by 10.200.0.1 with HTTP; Fri, 13 Apr 2018 03:40:22 -0700 (PDT) In-Reply-To: <20180413100921.GM6014@localhost> References: <1523457879-9869-1-git-send-email-pierre-yves.mordret@st.com> <1523457879-9869-3-git-send-email-pierre-yves.mordret@st.com> <20180413040233.GJ6014@localhost> <20180413100921.GM6014@localhost> From: Geert Uytterhoeven Date: Fri, 13 Apr 2018 12:40:22 +0200 X-Google-Sender-Auth: K9ybf_V3aCjsuT18i6TVMV1EWuQ Message-ID: Subject: Re: [PATCH v2 2/2] dmaengine: stm32-mdma: Fix incomplete Hw descriptors allocator To: Vinod Koul Cc: Pierre-Yves MORDRET , Alexandre Torgue , Linux Kernel Mailing List , dmaengine@vger.kernel.org, Maxime Coquelin , "M'boumba Cedric Madianga" , Dan Williams , Linux ARM Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Vinod, On Fri, Apr 13, 2018 at 12:09 PM, Vinod Koul wrote: > On Fri, Apr 13, 2018 at 10:39:48AM +0200, Geert Uytterhoeven wrote: >> On Fri, Apr 13, 2018 at 6:02 AM, Vinod Koul wrote: >> > On Wed, Apr 11, 2018 at 04:44:39PM +0200, Pierre-Yves MORDRET wrote: >> > >> >> struct stm32_mdma_desc { >> >> struct virt_dma_desc vdesc; >> >> u32 ccr; >> >> - struct stm32_mdma_hwdesc *hwdesc; >> >> - dma_addr_t hwdesc_phys; >> >> bool cyclic; >> >> u32 count; >> >> + struct stm32_mdma_desc_node node[]; >> > >> > some ppl use node[0] for this but i think either is fine.. >> >> node[] is the correct one, node[0] may hide future bugs, cfr. commit >> a158531f3c92467d ("gpio: 74x164: Fix crash during .remove()") > > Yeah but it this case it is the last element. But yes it helps to avoid such > mistakes in future.. It was the last element in 74x164, too. Unless someone changed that. Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds