Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp2585249yba; Mon, 6 May 2019 08:21:23 -0700 (PDT) X-Google-Smtp-Source: APXvYqx+9W6QDG6C//Jecaszn6iGqig0Q476+I/bzbiHOmwj6gOaSdpW/VUVgCWdlOPigbSB/8lE X-Received: by 2002:a62:56d9:: with SMTP id h86mr24582961pfj.195.1557156083103; Mon, 06 May 2019 08:21:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1557156083; cv=none; d=google.com; s=arc-20160816; b=YQDiOj1X6WhRC182KKQRrxnSHA7PevUv1Ff4Sw73/eTgBIADXcG3blWaR/kj4EwZUH Y1JLHMR2AWTV7Nw2XZbN2HshOY1JDcQ+xLJVQtVr13KUQClcTqG/HTROydNcfY+34CzI Pzs98f6jsav5d1o/eg44wuGsAPa99mj9b+3879CoP0/VRnCjlWSB14xQfNBG26XoUZmO 0qp5A70b33TzL+n2PnBLk6wCAw3RFfPqGysRV3BdaDWjQgg2iZbFhK8tqr/mt39UfK7T jirO3vTvr7iF1LL9kUK0W5Ai60E2D1XD95G30/KsXM/FO1mg4kRGAINDbG9YOWhwCce0 wzbg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:message-id :in-reply-to:date:references:subject:cc:to:from:dkim-signature; bh=tIIjXVsYUQfztV2HMDyykqPnej8ujRojeO25gbPLAx8=; b=o4kLp8ukQvs0JFFCKeiuQE64JEjdAo7dyC+AkqRcrEPb6QAurG6Hl4zWaH1cfuPzBd /Iqk357WqqIrdTHRxUAOJIr4bMqY5eZFCEgbGVgPujrZ1qrIW9eFTch96X+RGWHYBTk7 gN5q6Ol1OV6B1oRSMcFXqP4Dgy0I8g5ZwYuPHIH18p6jF1C5a96r1f4SpK6TxaR9CT3p CJkwQNDQdZFMmfAb9HVkMYWABv/ybd6d3C9IIOCLteotoFqkwDW/F+BDVIkTKGdqA6Ij mIEhrKZP+QfRBt0Ty2rGCVmYXZZkJ1O9RRmoOo+/b/3FpByGDujRSfZ3PQAX8yZr0u6e nwjA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@haabendal.dk header.s=20140924 header.b=sb528pFj; 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 q137si14632234pgq.58.2019.05.06.08.21.06; Mon, 06 May 2019 08:21:23 -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=pass header.i=@haabendal.dk header.s=20140924 header.b=sb528pFj; 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 S1726622AbfEFPTc (ORCPT + 99 others); Mon, 6 May 2019 11:19:32 -0400 Received: from mailrelay1-1.pub.mailoutpod1-cph3.one.com ([46.30.210.182]:33422 "EHLO mailrelay1-1.pub.mailoutpod1-cph3.one.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726340AbfEFPTb (ORCPT ); Mon, 6 May 2019 11:19:31 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=haabendal.dk; s=20140924; h=content-type:mime-version:message-id:in-reply-to:date:references:subject:cc: to:from:from; bh=tIIjXVsYUQfztV2HMDyykqPnej8ujRojeO25gbPLAx8=; b=sb528pFjnouTzc+J3eVPhDX7vdvgMDXk7BFMuSZKambgzakehkG2af6Eb6srR1N1yDwoC8KtZnvPQ FU0t8xwGzqIPbM+AC+LEjkp16i0sMn26is3+Dp4i+K8hz36uub3HsQdSayvF5pfuL9hum9evDt4e76 82cUEXBMxPHLOmcY= X-HalOne-Cookie: 97b3711e6a3e173542b3f9ed2cff811ff8f0d11a X-HalOne-ID: 56a34210-7012-11e9-be4a-d0431ea8a283 Received: from localhost (unknown [193.163.1.7]) by mailrelay1.pub.mailoutpod1-cph3.one.com (Halon) with ESMTPSA id 56a34210-7012-11e9-be4a-d0431ea8a283; Mon, 06 May 2019 15:19:27 +0000 (UTC) From: Esben Haabendal To: "Enrico Weigelt\, metux IT consult" Cc: linux-serial@vger.kernel.org, Greg Kroah-Hartman , Jiri Slaby , Andy Shevchenko , Darwin Dingel , Jisheng Zhang , Sebastian Andrzej Siewior , He Zhe , Marek Vasut , Douglas Anderson , Paul Burton , linux-kernel@vger.kernel.org Subject: Re: [PATCH] serial: 8250: Add support for using platform_device resources References: <20190430140416.4707-1-esben@geanix.com> Date: Mon, 06 May 2019 17:19:27 +0200 In-Reply-To: (Enrico Weigelt's message of "Thu, 2 May 2019 21:41:01 +0200") Message-ID: <87imunobk0.fsf@haabendal.dk> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org "Enrico Weigelt, metux IT consult" writes: > On 30.04.19 16:04, Esben Haabendal wrote: >> Allow getting memory resource (mapbase or iobase) as well as irq from >> platform_device resources. >> >> The UPF_DEV_RESOURCES flag must be set for devices where platform_device >> resources are to be used. When not set, driver behaves as before. >> >> This allows use of the serial8250 driver together with devices with >> resources added by platform_device_add_resources(), such as mfd child >> devices added with mfd_add_devices(). > > I like the idea (actually, quite the direction I'd like to go), but > unfortunately it's more compilicated than that. > > Some drivers don't use these fields, eg. 8250 determines the mapsize > based on several factors, at the time of the mapping is done. That's > one of the things my patches shall clean up. Could you take a quick look at my patch again. The patch only changes the probe method in the serial8250_isa_driver in 8250_core.c file. So other drivers are not affected by this change. And with the addition of the new UPF_DEV_RESOURCES flag, no existing platforms should be affected either. The patch merely makes it possible to start using plain "serial8250" driver (serial8250_isa_driver) with standard platform resources, fx. as implemented by mfd-core. /Esben