From patchwork Wed Oct 19 08:22:26 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 4542 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4ac7:0:0:0:0:0 with SMTP id y7csp204158wrs; Wed, 19 Oct 2022 01:45:15 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7fUjhqDLoiFfvx5E9Lb/NBoH2SlnjcDkFN7vSRryXqLHM2O5P6I7jQ2Kgy/URacxFu0eMo X-Received: by 2002:a05:6a00:1a92:b0:565:d5c0:f627 with SMTP id e18-20020a056a001a9200b00565d5c0f627mr7623416pfv.10.1666169115024; Wed, 19 Oct 2022 01:45:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666169115; cv=none; d=google.com; s=arc-20160816; b=dC/pC9XWlOBo+2isuWFAtCjZY9RSkLhFVZWrAnTwnWLXPKbnvdiAPdw7SazQkU4fNq MjOFGpIk7rfWw5+YiSen/RavdMW8ay4q4H9kOZrirTFpx4sl2+MraAn1N22cv10GIdQc HuruqDnXmk4fVvuSQ2DHdVa7N3w+YCOoKYD60QT37SmZbAqa3eJiz5LPc6WEw4wsdINs Q/N7qja8FuxDSzf3RsIqjHxbAmdMx8lXvWxpzREhjngPKY+vk149koQNcZ0QCaMVuH2C UWfrRSQHimcmL9mAil3K4wl1R5nNPJkFqXrJ3MvYzNQM8PS1fx1jQGIm9uuCb8OE6CVF d4iw== 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=hBOXftv2TRYcUUsb8yOfh9Dw6hTrr1Ks6JvwCRYYDtY=; b=A2L+tvEWfrKpdsAwUPFMgXTQ4J51Ns98I06Lt8ENUWFUTbnnFzdYnXUunUkBRj3hi2 c7kfizSsR0GF1UUblA6UcBPsc2B6xS6qN08rCblaipLsi0DqMoxMQG0OMTKlw1J9uaLb LftUwdah3Lyfop/g8vXtbskAhEhHPCOZH9X7NeVMwEuSsPBCRVoVt4/oEdLnmsVCgqRn WvJ90/xVxikYL8xleTH6U5TzpzlIT9MefloIiK3cXbz9MABuyoZbxeLiuvnB7j1HS/L1 zmYUzdKIxuf5wkEeFSaBTJs/MKu7YdDLPIxkeT9R7e/ZrYBnYqEzC6umZgvF4GPebM5y 0d/A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=fmn6jq2A; 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 w7-20020a170902e88700b0017a0d1d072dsi18812374plg.336.2022.10.19.01.45.00; Wed, 19 Oct 2022 01:45:15 -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=fmn6jq2A; 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 S231247AbiJSIon (ORCPT + 99 others); Wed, 19 Oct 2022 04:44:43 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42556 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231124AbiJSInj (ORCPT ); Wed, 19 Oct 2022 04:43:39 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 23BCA5789B; Wed, 19 Oct 2022 01:41:00 -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 ECC3CB822D1; Wed, 19 Oct 2022 08:40:09 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2CB61C433C1; Wed, 19 Oct 2022 08:40:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666168808; bh=FP0+Py/xiye3Lrwe1PTtluLDiVfZV2Fz/lWJUEeXaKY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=fmn6jq2A+XoRka7PbxJlU23AYEF1oknkna+E6WLZ+K1th0EypeBP/TYgHIrBJWA88 u2cw14Czj1fIpK8lGT1Tq/yPApQOC/gLkj/xmFuvx7fKvAhrM6ZmaUavl4N6zcB8qY zWDQ+BwCf13m0K+UXyUW9BBGmzrPUZktsXJm/RsM= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Helge Deller Subject: [PATCH 6.0 059/862] parisc: fbdev/stifb: Align graphics memory size to 4MB Date: Wed, 19 Oct 2022 10:22:26 +0200 Message-Id: <20221019083252.585903812@linuxfoundation.org> X-Mailer: git-send-email 2.38.0 In-Reply-To: <20221019083249.951566199@linuxfoundation.org> References: <20221019083249.951566199@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 X-Spam-Status: No, score=-7.4 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?1747104945575831008?= X-GMAIL-MSGID: =?utf-8?q?1747104945575831008?= 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 @@ -1298,7 +1298,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;