From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from elvis.franken.de (elvis.franken.de [193.175.24.41]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 486BB1DF269; Tue, 21 Oct 2025 19:45:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=193.175.24.41 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1761075941; cv=none; b=sJtUDxWI4+63fzKh5swHgdOVDq8GmSAIfM5b8XgxllpaY/UewJcqc5Lm01aa6Eu1e2LoSKz0N8ZzlrAPYdqJid7LRWMTryrBkZyHta7+PSE8FcQDD97EASejuNsy8UpiZuurCf8ayby2aOhHhAnUGk8ObtZX7l75ur4xXpoa4Ps= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1761075941; c=relaxed/simple; bh=G1hbEtKrRI38BN8uRKmMEJMlIFVWwmAGY2J90k/Z0LY=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=PXg5uWhe7y2FtdgPyKU3Q/SQkOMODbwBTTS9t0XWmqUXPf6hHUjL2VBNigdws5plAmAuTeCF5WqjGM1f4xiNnxyYuVBhvoo/PO6GupH5vlkj+EYqfnYYx2wjau3EISubiFEZXSpJkOBbO/xjOhaldEbZcwH6tFHCmZvpeFYOabo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=alpha.franken.de; spf=pass smtp.mailfrom=alpha.franken.de; arc=none smtp.client-ip=193.175.24.41 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=alpha.franken.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=alpha.franken.de Received: from uucp by elvis.franken.de with local-rmail (Exim 3.36 #1) id 1vBIIT-0000NK-00; Tue, 21 Oct 2025 21:45:29 +0200 Received: by alpha.franken.de (Postfix, from userid 1000) id 90D3AC06A7; Tue, 21 Oct 2025 21:45:16 +0200 (CEST) Date: Tue, 21 Oct 2025 21:45:16 +0200 From: Thomas Bogendoerfer To: "Maciej W. Rozycki" Cc: Bjorn Helgaas , Ilpo =?iso-8859-1?Q?J=E4rvinen?= , Bjorn Helgaas , linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 2/2] MIPS: Malta: Fix PCI southbridge legacy resource reservations Message-ID: References: Precedence: bulk X-Mailing-List: linux-mips@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: On Tue, Oct 21, 2025 at 08:38:29PM +0100, Maciej W. Rozycki wrote: > Covering the PCI southbridge legacy port I/O range with a northbridge > resource reservation prevents MIPS Malta platform code from claiming its > standard legacy resources. This is because request_resource() calls > cause a clash with the previous reservation and consequently fail. > > Change to using insert_resource() so as to prevent the clash, switching > the legacy reservations from: > > 00000000-00ffffff : MSC PCI I/O > 00000020-00000021 : pic1 > 00000070-00000077 : rtc0 > 000000a0-000000a1 : pic2 > [...] > > to: > > 00000000-00ffffff : MSC PCI I/O > 00000000-0000001f : dma1 > 00000020-00000021 : pic1 > 00000040-0000005f : timer > 00000060-0000006f : keyboard > 00000070-00000077 : rtc0 > 00000080-0000008f : dma page reg > 000000a0-000000a1 : pic2 > 000000c0-000000df : dma2 > [...] > > Signed-off-by: Maciej W. Rozycki > Fixes: ae81aad5c2e1 ("MIPS: PCI: Use pci_enable_resources()") > Cc: stable@vger.kernel.org # v6.18+ > --- > arch/mips/mti-malta/malta-setup.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > linux-mips-malta-setup-insert-resource.diff > Index: linux-macro/arch/mips/mti-malta/malta-setup.c > =================================================================== > --- linux-macro.orig/arch/mips/mti-malta/malta-setup.c > +++ linux-macro/arch/mips/mti-malta/malta-setup.c > @@ -213,7 +213,7 @@ void __init plat_mem_setup(void) > > /* Request I/O space for devices used on the Malta board. */ > for (i = 0; i < ARRAY_SIZE(standard_io_resources); i++) > - request_resource(&ioport_resource, standard_io_resources+i); > + insert_resource(&ioport_resource, standard_io_resources + i); > > /* > * Enable DMA channel 4 (cascade channel) in the PIIX4 south bridge. Acked-by: Thomas Bogendoerfer -- Crap can work. Given enough thrust pigs will fly, but it's not necessarily a good idea. [ RFC1925, 2.3 ]