From nobody Thu Feb 12 23:05:22 2026 Received: from cantor.telenet-ops.be (cantor.telenet-ops.be [195.130.132.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E982759B71 for ; Fri, 3 Jan 2025 08:58:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=195.130.132.48 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1735894732; cv=none; b=IwVhMEtER0uuIES9ShrahGi53ww4xQVBmvPk5Ac33IrTWUhn8CgSgqGomCcwgnD2VzHMPf3U5nDAuyDsG3CdxXuenef/GgRmtynB51+dCqVFY7iQY2ppg7vi5xQDDrdajrDgI9nrZE96YigojlyRgXkfKkwRq3b2lc0VVyBx+KM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1735894732; c=relaxed/simple; bh=dn7zhgTJ3YzyxyCL7W4j/U7H5Q8WM3p6Invtk9IOMok=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=XVZvoUFzTwcA7Eh8p0y6tSoDpb7T7XtYeMiFTrG5PQ0MG1PaPznbhGa04SHqg92d1tXO7fBGeUSe9vPQsGRzFMKW+txxAY3lgSfkVU1/wcxYG0OBNEWKbtyk79JIPBMtvBYgsJitN6KYYIyI04pKVA5FpppAJ1xtrpHZ40P8ayQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=glider.be; spf=none smtp.mailfrom=linux-m68k.org; arc=none smtp.client-ip=195.130.132.48 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=glider.be Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=linux-m68k.org Received: from baptiste.telenet-ops.be (baptiste.telenet-ops.be [IPv6:2a02:1800:120:4::f00:13]) by cantor.telenet-ops.be (Postfix) with ESMTPS id 4YPckf4jvdz4x50d for ; Fri, 03 Jan 2025 09:51:38 +0100 (CET) Received: from ramsan.of.borg ([IPv6:2a02:1810:ac12:ed80:f66e:bd3:be87:168a]) by baptiste.telenet-ops.be with cmsmtp id wYrW2D0070t5JgF01YrW6B; Fri, 03 Jan 2025 09:51:31 +0100 Received: from rox.of.borg ([192.168.97.57]) by ramsan.of.borg with esmtp (Exim 4.97) (envelope-from ) id 1tTdOy-00000001dmc-20mH; Fri, 03 Jan 2025 09:51:30 +0100 Received: from geert by rox.of.borg with local (Exim 4.97) (envelope-from ) id 1tTdP0-0000000CaCA-1Cum; Fri, 03 Jan 2025 09:51:30 +0100 From: Geert Uytterhoeven To: Christoph Hellwig , Philipp Hortmann , Geoff Levand , Jens Axboe Cc: linuxppc-dev@lists.ozlabs.org, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, Geert Uytterhoeven Subject: [PATCH] ps3disk: Do not use dev->bounce_size before it is set Date: Fri, 3 Jan 2025 09:51:25 +0100 Message-ID: <06988f959ea6885b8bd7fb3b9059dd54bc6bbad7.1735894216.git.geert+renesas@glider.be> X-Mailer: git-send-email 2.43.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" dev->bounce_size is only initialized after it is used to set the queue limits. Fix this by using BOUNCE_SIZE instead. Fixes: a7f18b74dbe17162 ("ps3disk: pass queue_limits to blk_mq_alloc_disk") Reported-by: Philipp Hortmann Closes: https://lore.kernel.org/39256db9-3d73-4e86-a49b-300dfd670212@gmail.= com Signed-off-by: Geert Uytterhoeven Reviewed-by: Christoph Hellwig --- Guessed based on the reported bad commit ID. Compile-tested only. --- drivers/block/ps3disk.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/block/ps3disk.c b/drivers/block/ps3disk.c index 68fed46c463e5aa9..dc9e4a14b8854587 100644 --- a/drivers/block/ps3disk.c +++ b/drivers/block/ps3disk.c @@ -384,9 +384,9 @@ static int ps3disk_probe(struct ps3_system_bus_device *= _dev) unsigned int devidx; struct queue_limits lim =3D { .logical_block_size =3D dev->blk_size, - .max_hw_sectors =3D dev->bounce_size >> 9, + .max_hw_sectors =3D BOUNCE_SIZE >> 9, .max_segments =3D -1, - .max_segment_size =3D dev->bounce_size, + .max_segment_size =3D BOUNCE_SIZE, .dma_alignment =3D dev->blk_size - 1, .features =3D BLK_FEAT_WRITE_CACHE | BLK_FEAT_ROTATIONAL, --=20 2.43.0