Received: by 10.192.165.148 with SMTP id m20csp1524576imm; Thu, 3 May 2018 00:26:46 -0700 (PDT) X-Google-Smtp-Source: AB8JxZoRbuXQ0q5w+uH3vjRtOnK8X6O5EtyNQnaAa+QAMd+M1JOb5tf/flCcnEmn/Mm3FPQzv0nn X-Received: by 10.98.162.30 with SMTP id m30mr6131525pff.251.1525332406468; Thu, 03 May 2018 00:26:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525332406; cv=none; d=google.com; s=arc-20160816; b=ZJVXAVm2EjXlF/Rq+uiuMrYmCHox9QDHO1c5Mt4PqObo6AugZpesfGIJCgWu4dI1xU gmVT/nCPjxjqIs6U7gRK7b/l23NIYfFD3dTZNiPX9hmtzwzN+Jex20u4v2RlO6WH1p0/ qxt2niMbWRnxvYAr0QLYF9SY9hA3KmnsREG/pRjf2Ln7+QhcjcWdUncKzv5MUNjk4Gcc Auz08HfXzEeJs8rNd95qzxcDjr9ie7KeoMWrbsCf3CxQYe/kh640S3ScFhXVbtzEHLYU aU8yi8WcTM0VFYBSo8Iz0x97baYovD227jWq8LR8R4KEyhxEg1p5tz+Gk7cvpoDW0xsY HqFg== 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=mXvJSTr1PdGcmZHAMBAZcpX9lJBE06h8LFbW/j9wRi0=; b=Jf1rD6IrCSzgNzvoHFQm6KrgBd6PugxgoAV253KNIj4Yw/heZ1B4hs07HHSS4daBIB yIosP7yZxTbcdJmGRcEHxtZuUnbW3p0zVmw87vdDJgR7icu6LV2WhTZPA3Iw/TKK4MDM B7HjKo7Wd9e55KuW9WxLQ83H6GmKYi5n0PiUbZVdka2hzLBPDtOOHZBbqpOM/skKKzz/ T6voPSv4h6xSYxu7wdspQaWF2EQ58fBgHjH/RqxQlrzeBLQa1O0QcQD/LrGfMuM7wxL9 MM9LnhxNC3wKDCTai4KByUI2gyGRGOKTJbYcKpLNqw2YaK56T7BNQm/lHAGor8BCzcRc jXHQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=r3LMTk+G; 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 z8-v6si10769179pgs.302.2018.05.03.00.26.32; Thu, 03 May 2018 00:26:46 -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=r3LMTk+G; 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 S1751412AbeECH0B (ORCPT + 99 others); Thu, 3 May 2018 03:26:01 -0400 Received: from mail-ua0-f195.google.com ([209.85.217.195]:41267 "EHLO mail-ua0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750939AbeECHZ5 (ORCPT ); Thu, 3 May 2018 03:25:57 -0400 Received: by mail-ua0-f195.google.com with SMTP id a3so11180201uad.8; Thu, 03 May 2018 00:25:57 -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=mXvJSTr1PdGcmZHAMBAZcpX9lJBE06h8LFbW/j9wRi0=; b=r3LMTk+GGUf/qEy78IIFpVqjBHYvWm5Ei0yngHgYAvfyXCI1bEuEDaxO9v7d47Pa/x Fvz7ss1Qh6QPZyWoB1XQ1Q9ST1wNtxPhXeN7kB7Lx5PdBcAEPkVVjFxgtf+atlZbjK2D ov/NoBRY/sHYN7fmBOKo90kEOU8xcHJuQMiUhoCcCaWE+DvRNKSOhP/b5Lq5WGE9uh4H kGP56L6E7Enj8qwAQI+d7exRS0Uj5bIZOCQN1t9ixCWYj1Uo7tHCHFSzzUMBuXsoEPKc KwZiE/NOgbrWPFqdPLF3DNv+5bGT5e7D5uko16wRnxp2udufkSWK1MdjRWn3mphr20mr d43g== 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=mXvJSTr1PdGcmZHAMBAZcpX9lJBE06h8LFbW/j9wRi0=; b=TguQMj8TDAj5ke28Womsf1inDi5/e0fqWjKbEjPALLDcefn31kc1tFnPE8ufHJWD35 /Ogi3qHtLSbtPF8B/GWZssoqwvmDcBwOzp+gBPYm8/O+pYPLtuVqP+2htGWnxEul5+fl gjNADrNvWishcpu0a7b2ccSN5HMSx1ZPRhiLyP4jeln/DJLci9SUVsmAXIu3hAii9GMY H2RvsIHPDkrSmdQBQU6zXx/9LD39O59vI8pu47z2oyWONVk/5WpgjyJwMMauSioDh4LD BYO4ZmHgpuSRV2Z/dODGxAU3AINB523CWcMN8v6L3tCMH9+4goRXi1SOo6zqzmklym1N T7zg== X-Gm-Message-State: ALQs6tBWlA2afBTCk/Y9/YlCBKW2Cy20xBRKelilFZ90vre44v1kFxRz P3EnQDOnDcek62DRRu1NUgUYHNyjXBEhYmH91qErzLgr X-Received: by 10.176.36.147 with SMTP id i19mr20957539uan.180.1525332356931; Thu, 03 May 2018 00:25:56 -0700 (PDT) MIME-Version: 1.0 Received: by 10.103.122.10 with HTTP; Thu, 3 May 2018 00:25:56 -0700 (PDT) In-Reply-To: References: From: Geert Uytterhoeven Date: Thu, 3 May 2018 09:25:56 +0200 X-Google-Sender-Auth: wYVP_4XNH2wNi7K_IEGoU-ln_AQ Message-ID: Subject: Re: [PATCH net] macmace: Set platform device coherent_dma_mask To: Finn Thain Cc: "David S. Miller" , linux-m68k , netdev , Linux Kernel Mailing List 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 Finn, On Thu, May 3, 2018 at 6:23 AM, Finn Thain wrote: > Set the device's coherent_dma_mask to avoid a WARNING splat. > Please see commit 205e1b7f51e4 ("dma-mapping: warn when there is > no coherent_dma_mask"). > > Cc: linux-m68k@lists.linux-m68k.org > Tested-by: Stan Johnson > Signed-off-by: Finn Thain Thanks for your patch! > --- a/drivers/net/ethernet/apple/macmace.c > +++ b/drivers/net/ethernet/apple/macmace.c > @@ -203,6 +203,10 @@ static int mace_probe(struct platform_device *pdev) > unsigned char checksum = 0; > int err; > > + err = dma_coerce_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(32)); > + if (err) > + return err; > + > dev = alloc_etherdev(PRIV_BYTES); > if (!dev) > return -ENOMEM; Shouldn't this be handled in the platform code that instantiates the device, i.e. in arch/m68k/mac/config.c:mac_platform_init()? Cfr. commit f61e64310b75733d ("m68k: set dma and coherent masks for platform FEC ethernets"). 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