Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp1177512pxa; Sat, 22 Aug 2020 14:26:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx1FVqhxtjCVLc4b19dMHFFmXPm7RTLCNM1YMtN/NGplUEJ4TtALzEHuhjWTIGcNFEYcryP X-Received: by 2002:a17:906:7108:: with SMTP id x8mr8528703ejj.447.1598131571505; Sat, 22 Aug 2020 14:26:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1598131571; cv=none; d=google.com; s=arc-20160816; b=CwouZffWoWZFh1hqg/rx9zNqrQn8HHlU1+bx02OFbI9/QczaWEy0Em7dOua0yYvjHI vYMgSqL4lF3KhxpaCUox6n/DVUCcB5NhbiaHCtARze/CtKfiyAKsGvgAOiMZYFqDvhBE gG4jHslGYv9wbgPEEBw1YP2TkrDH3Heo3AzkJd6CsUX9WUhh+3Nlw9U7KpUT7hinAd0+ HjPgxgfVejM2mfYVe3XseGWAsW/9AOaOnj895dFm8mrTZoUHgbjpNWocWQyrVFYm/icV 4sc4mIKCEY9d+ljz7y9lsNCNv0PpE2UB/sk6tgIwB2whChKxjv81IBn/HAX7D+GKyTLf B5Mw== 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 :in-reply-to:references:mime-version:dkim-signature; bh=7HQaixpV1W6ja8XORGv/OFO3Xqa6umvUnjXwcLD9RpM=; b=KGm6Te73Qk/fBqyhyLPyO6t+zHZ+eThYeVig0yfmSFUueX8pbOx1vEq1vO4zWbwt0+ LV1HlRNPHKj7w2VSWKYqkJj6BL0lvOqYPTx0LPeX5FR+kLXW0eqnPuWVWmxsev4yPpJh rRs8eOi5KML+rQ4DygpKNUN6kxEsRY9EDLCXCfeHYdVWcOYuU9O1uGCpjQvC2Q483EBu cB8dkGhOqs/8FekLZ3I7K+a9IlJiyURc5DVgssLzqcD4kmm4c3qwldMv9rdECwvud6kN jYAFlDZwWqg4MN4N/8issFjd8VozPytXJplh2FDkFk9pxrcwnvBcdG8DcaQaySHri/+3 WR6Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@broadcom.com header.s=google header.b=bysO8gE1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=broadcom.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id n4si3666439edo.294.2020.08.22.14.25.47; Sat, 22 Aug 2020 14:26:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@broadcom.com header.s=google header.b=bysO8gE1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=broadcom.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728150AbgHVUrd (ORCPT + 99 others); Sat, 22 Aug 2020 16:47:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43198 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726036AbgHVUrc (ORCPT ); Sat, 22 Aug 2020 16:47:32 -0400 Received: from mail-ej1-x62d.google.com (mail-ej1-x62d.google.com [IPv6:2a00:1450:4864:20::62d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3230FC061573 for ; Sat, 22 Aug 2020 13:47:32 -0700 (PDT) Received: by mail-ej1-x62d.google.com with SMTP id d11so6809336ejt.13 for ; Sat, 22 Aug 2020 13:47:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=7HQaixpV1W6ja8XORGv/OFO3Xqa6umvUnjXwcLD9RpM=; b=bysO8gE1mzCl5ZuDnGZNQ43PkG4IHOdcM9jmDetVVRwg1JQGgOVCRZBuksRWj8ZbqF J9+1Ipg3Bg7Si2dhiY6kVrA+iKRSdod9kxh1syhQqWBsIMCE+zrVgqpMxSvWUMHLfZj2 qoobEYKpdDQhpK1UrUA4KJuq7Lpi9o7Nxg+VQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=7HQaixpV1W6ja8XORGv/OFO3Xqa6umvUnjXwcLD9RpM=; b=mBX28x8HLXDpfNMHvywo6ZiG+f45Z316UPU576llGnt/ozScRu7htKrPmn3L4UqxhH i2wHrHzBR53gAZf/oTgo7Rqwtgc9mUIFOZSZe3EzBxococLEnh2veBy03vX5MVH70wj+ lQUXPdAQofOaqd6nMrjERpJAdI7CD3PhTAWGDw3u+9D4r86NVP4MDTPazvJT5g5RvMy6 bnd78vvEQ6f1uVckTItVvZ4nUD5PSWLMPovpwdUw/UlgbclL1SKl6esP4wWhu7HcuFAS LYNA9Y6xX3ZtqPia3NiFt5lRO9MqqM/DSFrSUkFmk4MKvoYQrdD+ikkgbkib6zbCitHh RfHg== X-Gm-Message-State: AOAM5312wxVSI3LYET4Gw5cVU/a46wJMP5x5thRYHpx5dxvpLouKBJjt IQMEqZu8XWqNvsA4IAkC/yRUxdMHoiH17jbbxSJzQg== X-Received: by 2002:a17:906:d92:: with SMTP id m18mr9063590eji.428.1598129250618; Sat, 22 Aug 2020 13:47:30 -0700 (PDT) MIME-Version: 1.0 References: <20200821165221.32267-1-mmayer@broadcom.com> <20200822115636.GA19975@kozik-lap> <20200822164619.GA24669@kozik-lap> <81b2ad54-d4ef-cf98-886c-61c79e4cac62@gmail.com> In-Reply-To: <81b2ad54-d4ef-cf98-886c-61c79e4cac62@gmail.com> From: Markus Mayer Date: Sat, 22 Aug 2020 13:47:19 -0700 Message-ID: Subject: Re: [PATCH v2] memory: brcmstb_dpfe: fix array index out of bounds To: Florian Fainelli Cc: Krzysztof Kozlowski , Colin Ian King , BCM Kernel Feedback , Linux ARM Kernel , Linux Kernel 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 On Sat, 22 Aug 2020 at 13:21, Florian Fainelli wrote: > > On 8/22/2020 1:14 PM, Markus Mayer wrote: > > On Sat, 22 Aug 2020 at 09:46, Krzysztof Kozlowski wrote: > >> > >> On Sat, Aug 22, 2020 at 09:40:59AM -0700, Markus Mayer wrote: > >>> On Sat, 22 Aug 2020 at 04:56, Krzysztof Kozlowski wrote: > >>>> > >>>> On Fri, Aug 21, 2020 at 09:52:21AM -0700, Markus Mayer wrote: > >>>>> We would overrun the error_text array if we hit a TIMEOUT condition, > >>>>> because we were using the error code "ETIMEDOUT" (which is 110) as an > >>>>> array index. > >>>>> > >>>>> We fix the problem by correcting the array index and by providing a > >>>>> function to retrieve error messages rather than accessing the array > >>>>> directly. The function includes a bounds check that prevents the array > >>>>> from being overrun. > >>>>> > >>>>> This patch was prepared in response to > >>>>> https://lkml.org/lkml/2020/8/18/505. > >>>>> > >>>>> Signed-off-by: Markus Mayer > >>>> > >>>> Your Signed-off-by does not match From field. Please run > >>>> scripts/checkpatch on every patch you send. > >>>> > >>>> I fixed it up, assuming markus.mayer@broadcom.com is the valid email > >>>> address. > >>> > >>> No. I have always been using mmayer@broadcom.com since it is shorter. > >>> That's also what's in the MAINTAINERS file. Please change it back. I > >>> accidentally used the long form for one of my e-mail replies which is > >>> where the confusion must have originated. > >> > >> I'll drop the patch then. You need to resend with SoB matching email. > > > > Oh, I am starting to see what's happening here. This is new and > > apparently due to some changes with the mail server setup on our end. > > > > I have this in my patch file: > > > > $ head 0001-memory-brcmstb_dpfe-fix-array-index-out-of-bounds.patch > > From 6b424772d4c84fa56474b2522d0d3ed6b2b2b360 Mon Sep 17 00:00:00 2001 > > From: Markus Mayer > > Date: Fri, 21 Aug 2020 08:56:52 -0700 > > > > Sending patches like this used to work. Clearly our SMTP server has > > now taken it upon itself to rewrite the sender e-mail address. I > > wasn't expecting that. Let me look into it. Sorry for the hassle. It > > was not intentional. > > Yes, if you used to use the SMTP relay server which did not require > authentication for internal hosts, and now you use smtp.gmail.com with > your broadcom.com username, the SMTP server will rewrite the From: to > match the username used to authenticate with the server. Actually, it was the other way around. Connecting to smtp.gmail.com does allow the "From:" header to be customized. The envelope sender, i.e. the "From " line at the very beginning of the e-mail, might still get rewritten, but that's okay since the "From:" header is left alone. The internal SMTP server, however, which does not require authentication, unexpectedly rewrites the "From:" header in the middle of the e-mail header. Got it set up now in a way that should work. At least it did in my test. I'll send out v3 of the patch momentarily, and then we'll know for sure. Regards, -Markus