From patchwork Mon Oct 24 11:29:29 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 8896 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp433809wru; Mon, 24 Oct 2022 05:50:32 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5FlV4gIgpwqxldl+IWisQCTPJJyHT7d4B6FKF2JH0AnByphGV2Ap3dtaY5uHZdAdHXf8xA X-Received: by 2002:a05:6402:254f:b0:45d:3044:d679 with SMTP id l15-20020a056402254f00b0045d3044d679mr31427639edb.137.1666615832707; Mon, 24 Oct 2022 05:50:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666615832; cv=none; d=google.com; s=arc-20160816; b=og3ReNgYrHfvcCQpSmoHcY9zbGl8zkzQUATa8W2o4v3QSPB9Hsn1uLCHJvfT6PEQ+j 2hikr938LfYdyIU3ylqLcjVLi3eQhnBEatfXGFX8qfNm4uR1GCkBW+JV1YKUt7Zo+zPU 6PA5YXbVDDdd8slV4Ox94ry39RU9YgSdosCT9HziNEQHyEoIGzD1/Yd/1icun26/FDGt Y/JA0UPbICXADr/0mnFNi4rHFrE2c+7AWGZ++46vZBweauLivbqyGANmMq3Eogp7EWAD LKtBfDc9phpaSkU/S5kF1VKpqafEj3KhN/XNHu+YXoFS+owGXzAS9eBZckExapF6dObX k26g== 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=0iXjiI1uzDUFY4xmp74E6j77SdFazKA7znoCBQisjxM=; b=IDv+asb7RwA3ZIpQlXwj18zOzKp2PubRJAtL8yqGcSuayM3ZKF9X7ZGALUhVM6Nsrj pqmGwnNyH4omaxBYjYhZ/O+vSY3vsNxvc80K/jm9pQprc5+5gJofhljwvN5PO5xU1+Kc QpYSPrJ7p29AavNpZgkCmKeuB/zi++ojt/K5+i3qzsUtkJSxL+Xi3Y2u7KeAH5bNirS7 unArFAQK4cY7gQDe9wZWc+XH9k3jmtyOzF19OCt76dN6NoG4hUzuqoaGErkOXcpELYFj 1xlgq2d8eymu0xfk/UHHwzOaWPWUzWLcItZLR2SIRFpUMVgkuBJ+5KzATGbu9NJ590M3 eb9A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=OopmayLJ; 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 cw20-20020a170906479400b0078db3ae83d0si26624529ejc.3.2022.10.24.05.50.05; Mon, 24 Oct 2022 05:50:32 -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=OopmayLJ; 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 S234542AbiJXMtF (ORCPT + 99 others); Mon, 24 Oct 2022 08:49:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56314 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234393AbiJXMon (ORCPT ); Mon, 24 Oct 2022 08:44:43 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3C0397D1C6; Mon, 24 Oct 2022 05:09:16 -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 dfw.source.kernel.org (Postfix) with ESMTPS id 84A3E612EA; Mon, 24 Oct 2022 11:57:05 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 97771C433D6; Mon, 24 Oct 2022 11:57:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666612624; bh=Ys3ka49cccFJzfsTCTuZ+erQPYHY5yRX3BygybRzjkA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=OopmayLJxkz1ILjvZWqXTVXqPwuQM7i3VpxceGJhiMyoNqx6A3/I4QwaA/kACqxcd WNTRIBuDdctvG1PK5Q5q/FZtJuTTEf1knngBc+2TXewDlPx+kivu9KTCCdjdOLMse7 3NaHwTCMabz0TrJFzmlanytxc4mDDv5GPdX8GICM= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Helge Deller Subject: [PATCH 4.19 050/229] parisc: fbdev/stifb: Align graphics memory size to 4MB Date: Mon, 24 Oct 2022 13:29:29 +0200 Message-Id: <20221024113000.699526719@linuxfoundation.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221024112959.085534368@linuxfoundation.org> References: <20221024112959.085534368@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?1747573363347861149?= X-GMAIL-MSGID: =?utf-8?q?1747573363347861149?= 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 @@ -1257,7 +1257,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;