Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp2302821pxb; Fri, 5 Feb 2021 14:24:24 -0800 (PST) X-Google-Smtp-Source: ABdhPJxi8CVXNfTsuG5undT/M0hooz46CDyRLZLxGoGawiXZaNGIlNC5spd9H9Yji3M04WVD2j7t X-Received: by 2002:a17:907:98f3:: with SMTP id ke19mr5976749ejc.290.1612563864127; Fri, 05 Feb 2021 14:24:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1612563864; cv=none; d=google.com; s=arc-20160816; b=NWGcwh8gpSDlP1GGQ3oLLjCxEKDda684MYT22zJTvMFuDjVZjJOCelWxAgZkzhBdhP h7dLcCCfRwIrQifwh6mPYf0VHbtT0TnqtaE0FCuBYU+u4qcnvYdpFtUOlts9BlKxYnNo cYXoO3TbEt+21Os6RLM/C6Gf9McpIsisTGtgPy648pT3OAI1mgh/gxDLgPWpUM4KdHQT FR+YFCe4VvTKUt3t3CbnNPAMm0jWwtnSjY0yw0P9GEQFLRD7g3M/E5vrAP7+by6BW5Oj eEsb/uAn6Qa20roYV/kmJ7eJpfYZgCwPoK90hfcxEUEzCPttvj8rzu925VSli5mZ87IO o0og== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:user-agent:references:in-reply-to :subject:cc:to:from:message-id:date; bh=qkyFgm2dKcE0BE2tt1vbZjQ9hJELDVs4nlLDq78IOno=; b=IlKpHDmtrVDFLoTIJ3S72epiCTGxuUDACRJSLulY8ILK3hQ9CeYlanZEC9u8jWk3+9 qvlZJGyVVihRlwJeDVUpysYUxkK9uozFEfkfFnasErnUGawaGKV4nGJdfpjqU+tLJGee oalPJLB6aeh+Q7oyb1JtlBtY6egD5jXxdl+R3OHRkV946KmCzDwiEUQcygiYSvYbIWdr 1E1F65f97e4QsXEyqkNK+4q/rvhOvM3Br3l18IytS8NuQ4pr75qGIBjmkmbjJPlUNVun 2mU4bvlyh3aBA37mJ2jzJ9IW7xoSiGcg+ypPLyAg60qu2Fqi8LDWyHvRE7nQl7gzkzX1 /3kg== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id s10si6090769ejr.714.2021.02.05.14.23.59; Fri, 05 Feb 2021 14:24:24 -0800 (PST) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233258AbhBEWVH (ORCPT + 99 others); Fri, 5 Feb 2021 17:21:07 -0500 Received: from mx2.suse.de ([195.135.220.15]:48170 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232864AbhBEO4T (ORCPT ); Fri, 5 Feb 2021 09:56:19 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id C147CB131; Fri, 5 Feb 2021 14:19:56 +0000 (UTC) Date: Fri, 05 Feb 2021 15:19:56 +0100 Message-ID: From: Takashi Iwai To: Hans Verkuil Cc: Andrew Lunn , Mauro Carvalho Chehab , linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, "Matwey V. Kornilov" , Robert Foss Subject: Re: [PATCH] media: pwc: Fix the URB buffer allocation In-Reply-To: <88c960d2-40b1-ab6c-c17b-863c803a54b0@xs4all.nl> References: <20210121202855.17400-1-tiwai@suse.de> <7afd0612-de36-60b1-6650-6f8de24a7145@xs4all.nl> <88c960d2-40b1-ab6c-c17b-863c803a54b0@xs4all.nl> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.8 Emacs/25.3 (x86_64-suse-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 05 Feb 2021 15:05:00 +0100, Hans Verkuil wrote: > > On 05/02/2021 14:53, Andrew Lunn wrote: > > On Fri, Feb 05, 2021 at 02:42:23PM +0100, Takashi Iwai wrote: > >> On Fri, 05 Feb 2021 14:13:02 +0100, > >> Andrew Lunn wrote: > >>> > >>> Hi Takashi > >>> > >>>> Indeed, looks so. In most cases, this doesn't matter since both point > >>>> to the same device object. In some cases like xhci-plat HCD, they > >>>> differ. And sysdev might be a better choice from the consistency > >>>> POV. > >>>> > >>>> But this brought an interesting question, too. eg. USB chipidea > >>>> HCD uses platform devices for both controller and sysdev, and I > >>>> couldn't find any DMA mask setup. So, no matter what to use, the uwc > >>>> driver would be broken on this... Maybe it's just not covered. > >>> > >>> Did you do a git bisect to see what actually broke it? "1161db6776bd: > >>> media: usb: pwc: Don't use coherent DMA buffers for ISO transfer" > >>> introduced the code, not the regression. If we understand the > >>> regression, that might give us the answer about chipidea. > >> > >> It's the recent DMA core change, the commit f959dcd6ddfd ("dma-direct: > >> Fix potential NULL pointer dereference"). But basically it's a right > >> fix, and the driver hitting this "regression" has been already broken > >> but casually worked without setting a proper DMA mask. > > > > So for the chipidea, it also just 'casually worked'. But now it > > probably does not. But that is a separate chipidea issue. None of my > > ARM systems use the chipidea IP core, so i cannot test anything. > > Since few people use the pwc driver anymore, and certainly not on non-intel > devices, I am happy with Matwey's patch as is merged in our media tree for > 5.12. > > I'll mark Takashi's patch as Obsolete in patchwork as well. > > I might have an SBC with a chipidea, if so, I'll give it a quick spin. Fair enough. Thanks! Takashi