From patchwork Mon Oct 24 11:29:38 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 10058 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp623300wru; Mon, 24 Oct 2022 12:47:43 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4kc6hS8AesNyyMa1c5XtzVm9i6jH6gCutDB1fM/O4PJzh5wvY+cO+G4QYitJ3z32z5kwEm X-Received: by 2002:a17:906:9bed:b0:7a6:a68b:9697 with SMTP id de45-20020a1709069bed00b007a6a68b9697mr6967036ejc.218.1666640863475; Mon, 24 Oct 2022 12:47:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666640863; cv=none; d=google.com; s=arc-20160816; b=b81NeJ2OwcaA6FqtZRdHHhcXwH6FEqdX5zLSR7eVy4X6mr1a4ddo++h836YR3owSRM tfbGE+PQF9a6zc5xLJsHVrumANaooGxZJSxyKMIZFfu9lIvkB8YBfsKKuwMydqj1CPxL 6GYmPtS5PtYl89oRT8GqZOMIU/m2qy7AIkkSNdiZBgbIG7PkrMHPdDaKlv8wBVX+O895 OBlSaU1JsxNpZUwOf3irkDGpjNn5LbFSjk1wd2w3yxboDkDlbU/7utbA9QwzD19ZexbT 1sdAIQ6oY5bQD+DgMH6OZ0F6XicsO1tclyCFN6TNmlnKdfocS0+o1+bfO6jFDWH5kZ16 yecg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=5EJe+lboq02oe+GqHveqSKGIFzLy9JxZM70cdopWoP8=; b=DbsWEBsaZM3PHUG5bK90gfcbLqGDnXvd39tSW+t8ifD6tmg2BLcDh+/h0T/qFO/RbS 8piM9myviB0jOmDvbgMKHumNdDhLdk3oecsxOfJnCY7Gc4pHVnlgug5Z2DgTh5/r2zj+ 45FGJGGp38sL4B706+X4qVVnDtavysTr7g9OPuVQP/FvbltNcEp4aqeRPAPl5uRMGa24 U6rWOSs8QS4/gEr/l5hWcPV6OhtNI21p/JJ9tKia+IWcp3lJRCxsyG/7cikVpdjVoxuq uDp9kxS+629V3GNmnaPLFFWf1ujN4KrNYdq7vOoSen56MOHSgZcpcO+uLkcdNMJmNKlo fAJw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=g67APvKJ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id nb15-20020a1709071c8f00b007a6c5a23a48si116843ejc.551.2022.10.24.12.47.18; Mon, 24 Oct 2022 12:47:43 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=g67APvKJ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232542AbiJXTpQ (ORCPT + 99 others); Mon, 24 Oct 2022 15:45:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38016 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233453AbiJXTmo (ORCPT ); Mon, 24 Oct 2022 15:42:44 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D1489D4A07; Mon, 24 Oct 2022 11:11:51 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 05F7BB8119F; Mon, 24 Oct 2022 11:48:02 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 635BBC433C1; Mon, 24 Oct 2022 11:48:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666612080; bh=CDq8FveJgeZh1rfJgeX4HZ9et2u3iDuKrkjXt/oPHxk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=g67APvKJW91OrTdMcAA6EdvNuSlTEO40nUSjthxk+vIuS6oV3qcMT4nlOPkcSP4Xu erX6SuR4e5Hv4c+SakNLXBc40xfHMNU+M4LESvzgXj0vDhRHkEMc5a9lYyU/qq5TG7 p+toWcAWpODNALjMVnpqGoPin2hGWKt5BIKocIuY= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Helge Deller Subject: [PATCH 4.14 061/210] parisc: fbdev/stifb: Align graphics memory size to 4MB Date: Mon, 24 Oct 2022 13:29:38 +0200 Message-Id: <20221024112959.009822666@linuxfoundation.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221024112956.797777597@linuxfoundation.org> References: <20221024112956.797777597@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 X-Spam-Status: No, score=-7.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1747599609963208203?= X-GMAIL-MSGID: =?utf-8?q?1747599609963208203?= From: Helge Deller commit aca7c13d3bee81a968337a5515411409ae9d095d upstream. Independend of the current graphics resolution, adjust the reported graphics card memory size to the next 4MB boundary. This fixes the fbtest program which expects a naturally aligned size. Signed-off-by: Helge Deller Cc: Signed-off-by: Greg Kroah-Hartman --- drivers/video/fbdev/stifb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/video/fbdev/stifb.c +++ b/drivers/video/fbdev/stifb.c @@ -1259,7 +1259,7 @@ static int __init stifb_init_fb(struct s /* limit fbsize to max visible screen size */ if (fix->smem_len > yres*fix->line_length) - fix->smem_len = yres*fix->line_length; + fix->smem_len = ALIGN(yres*fix->line_length, 4*1024*1024); fix->accel = FB_ACCEL_NONE;