From patchwork Tue Jun 14 12:08:53 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Carpenter X-Patchwork-Id: 12880994 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 381EFC43334 for ; Tue, 14 Jun 2022 12:09:17 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 590D010ECB4; Tue, 14 Jun 2022 12:09:16 +0000 (UTC) Received: from mx0a-00069f02.pphosted.com (mx0a-00069f02.pphosted.com [205.220.165.32]) by gabe.freedesktop.org (Postfix) with ESMTPS id 63AD810ECB4 for ; Tue, 14 Jun 2022 12:09:15 +0000 (UTC) Received: from pps.filterd (m0246627.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 25EBYWG9011677; Tue, 14 Jun 2022 12:09:08 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=date : from : to : cc : subject : message-id : content-type : mime-version; s=corp-2021-07-09; bh=ieURvTjibMbduP6XS3Cg5Rx9+Rquex7IiiU+78pyCoo=; b=XD/ZTT0Q4Y+hTJb8YTm/G9gYH+SuV29Ib8urgr5IsFBet6+4qsKJbqYYqLkQt4R/m+xT nSciCBOEZQrUt4lC0tQ3VA2TyP9jVfS3/l/0wEIXJG+nUR9zzbR5jUiZnu/TIkwizhG3 QwdylJLhUGCDFpT3y/Y8UkzcDJmfdnMSHPWIAZRCquRBENWJFUIWgP7P3gP/IFyCdg/Q /gZysp3WS2h6JExGdDCpR1S4Qx4vUcza8d1jhHVh1STJu3+LB+8Y9QwsC+2Frz5NOd+v 1G134gjO4bieJPmoXzexCu5+9AorgMvftcb4JCKZeqbTkmGAl7iHtGZ3/zecKGyDXepU QQ== Received: from phxpaimrmta02.imrmtpd1.prodappphxaev1.oraclevcn.com (phxpaimrmta02.appoci.oracle.com [147.154.114.232]) by mx0b-00069f02.pphosted.com (PPS) with ESMTPS id 3gmhn0dnyp-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 14 Jun 2022 12:09:07 +0000 Received: from pps.filterd (phxpaimrmta02.imrmtpd1.prodappphxaev1.oraclevcn.com [127.0.0.1]) by phxpaimrmta02.imrmtpd1.prodappphxaev1.oraclevcn.com (8.16.1.2/8.16.1.2) with SMTP id 25EC5jml010145; Tue, 14 Jun 2022 12:09:07 GMT Received: from nam12-mw2-obe.outbound.protection.outlook.com (mail-mw2nam12lp2040.outbound.protection.outlook.com [104.47.66.40]) by phxpaimrmta02.imrmtpd1.prodappphxaev1.oraclevcn.com with ESMTP id 3gpr7mtqv1-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 14 Jun 2022 12:09:07 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=EX3Cuqrf2/J/LyhUOJ/tazdCaNBJg9peTB+ZqPZZomzYwr+fsZiBQiWiKPjnbsXGNqJ2/n9URNK+mk/QgIWRNTIw2Yo0yoFGR1ZGJYxt2ton0xEhRiZcAUPCs0/PHT6osbr4u7sBoQAv9+gkv67C1Ju3fEXq0B2ex9ShuXptMEr+3DOku72alpEXwo1GO9DR+vQHbFreLKHtlZO16N00j1jmx75avu3U3MAg3+lJMtUbOh4Sw1a5Eq803NxxC4utPJ/eQYDMYtR+UWfgtpcxSDbrD/aUozWkFs8ybn6mWji3WUYMMYAXeAJeEweUeZ1BM4V4OZ92lI6KwlPbmCCK3w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=ieURvTjibMbduP6XS3Cg5Rx9+Rquex7IiiU+78pyCoo=; b=JQvUI2LhFOFusY6ZioChd+Jf3lB8SWkYSc6H2qcgFPS46DXxXz1bmb5HBJBuPlCy5Mwhqgs3Jd+pkWkEOZ+GQBLDib4P0eOTsDp66/vGArCfThn4NgSJMBHsfNo00Ut1/IjvqKQvmUI5iXHnKhrKKKVQuOeB36VsRiYIUo+ah6uOZDgREDIRfghU9G04W3tclV2W/OcQ9sZkPE/olNo/E3nAVPxG1Jkle/Ynh1rg3TrMpBo+2cBNOsrfoiHSE/fCrFJonlWOn/YLQ8wYU6+NnQJ1+CuFuorbNQ2PbzF315Ff7EbzvdHZWi0g+7ThjYZCL8GoEIGbVvd+rfL5It+iiw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ieURvTjibMbduP6XS3Cg5Rx9+Rquex7IiiU+78pyCoo=; b=yGx+Rsk7H2SN4Uk2fwOpLCJW/z6cMtqluQZfw7y0FrCDSgjSz2DBnpS8mFqNPK3q89cA/COx3mGyakZ/VbYKvbRTng02S62foIc3XnCWPRyBons/jm8wBjHBAZ6mJ8JTerdqcVwtsFQ+nGDWLSTmVPqtEa9fptNliUW5X2zb3ok= Received: from MWHPR1001MB2365.namprd10.prod.outlook.com (2603:10b6:301:2d::28) by DM5PR10MB1482.namprd10.prod.outlook.com (2603:10b6:3:c::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.15; Tue, 14 Jun 2022 12:09:05 +0000 Received: from MWHPR1001MB2365.namprd10.prod.outlook.com ([fe80::5020:9b82:5917:40b]) by MWHPR1001MB2365.namprd10.prod.outlook.com ([fe80::5020:9b82:5917:40b%6]) with mapi id 15.20.5332.020; Tue, 14 Jun 2022 12:09:05 +0000 Date: Tue, 14 Jun 2022 15:08:53 +0300 From: Dan Carpenter To: Paul Kocialkowski Subject: [PATCH] drm: logicvc: fix error code in logicvc_layer_init() Message-ID: Content-Disposition: inline X-Mailer: git-send-email haha only kidding X-ClientProxiedBy: ZR0P278CA0009.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:16::19) To MWHPR1001MB2365.namprd10.prod.outlook.com (2603:10b6:301:2d::28) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 2c2230b7-bda4-4056-d8f1-08da4dfead39 X-MS-TrafficTypeDiagnostic: DM5PR10MB1482:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 45a340xykyBYKM6hYuDr+eFN9MpcblypQnagQmLsqgTKdiZLbbOjU/zDudGcNxM2vllWM7xKspKI3NC56/SmlhmYxz7QgafcHGW0XHGdG+I23hac0KUzGJAD8/qF7QopJJaiE4zfu7RMdpFcpjHcf9fdOY98qMzLVAtI7Y0E+TzYr3quuKLA37kwXcmJIcRhFavKqYcxtVzgV4hR9VP9sjGh30ZbSl4yvrBnxvzC164k70jU4ku9VbtQOsLzpTQvfnPze0IM3C4pf12sy/+f+g5jZQZM4xGTFpYsyTpkg9DR02ylrIxzN+cYeBLiHGN4K1ErjmPdrWNS5pFiP69OVKRhx2NouiHpb8HK0NGyC7W2GJnruMDEaTjgnbAzXyhuh0YXHtpaH40JjslNt7B+fNywC8EtarqfcdnQgt5Fv1PBDdyvue8mT1dpwT7X8PjhQqU38tRYl3Ilb+IlfLyXll74XYHJ8rfyDc2znal6pPR5AzEejGAnqBjsOcCd/d7paRAAzOXhJ4m/b0PI+fvAlrlyLGwsCOQ22EjTyEbnPOJ1xjYLHNs0o+POJoWGD3RFmO1C/Y/LgR68dFiPouIFIlEbtVVmsk99Se/Zkhc1QYQ4wKOnOi643B1ddn0ueuYLsXK3Ys81XNphWKL2QAJmmKqrnP0ZzwAllkx3PkLGLw+S4EL3GyDjgu1EgbKn+xDd/4p52knuHiFIUqggOA0KVA== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:MWHPR1001MB2365.namprd10.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230016)(7916004)(366004)(9686003)(6512007)(52116002)(6486002)(26005)(6506007)(54906003)(6666004)(508600001)(33716001)(38350700002)(38100700002)(186003)(86362001)(5660300002)(4744005)(2906002)(66946007)(66556008)(8936002)(66476007)(316002)(8676002)(44832011)(6916009)(4326008); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 3XBi3rKzSGBHt6KEl1hnLQQcdpVHnJhy0XE6A1K0E/4YOGhEwwJfzm+E2qy6CG0JE6IuKfPSI+7h8oHchNGvG7IOTVCge9WoX/2FIZMxyhyi56wFo7zvM1CDzJJKNtAsR3vA0cwxURHyTDsI2C1euYYD8aDh3QYvD78J+MacQl7fvLW/81wpTAlonXbJHV3iCyJJdHBHP13CfXWRk7BHsNcqBBOEpvFP0FzLyAJVMnAMRsWYyfuJ+u4UB/M/VM0fK3dRrsX+uhSnMsrKc2ccP/SIlF4LdgIZFFlwnXbQf8MMsJ73GqcLqnNFoZWEZVdUmh1GXpF/W4lkem1uFvPwYXGmn//ipTJp7r0G72Bx/0K97x5nZqubnR1pI2HNLVFczno2/qpBWmgH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ZwastS+YNkCYZoweRfzZ0sA/ZtaAXCXKoHaj9YEWTF6/5cU+l/EP0dRNASl6PFhOLqDm7JvV12ujG2xWAW11cU4jCnYpIWg0Xx19rFLsKhlhTNkDR+QLl9IIfQRZSwBCtfZj3uCiXeE/Y07EmiyH78uyEzC8M94QK6JohSDYOL5Vx4NzEsjIy9yK1KgeS05zsqMPUDMWDA88oywNVjT1T5jGbtU2nY24EH5S9eTPdMFyPS7a6L468aETaxAjO4JotYMeG2ySwohQ7hTMA7QwqzZwqLAywOyP7vW0RqPdqMc= X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2c2230b7-bda4-4056-d8f1-08da4dfead39 X-MS-Exchange-CrossTenant-AuthSource: MWHPR1001MB2365.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Jun 2022 12:09:05.0877 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 8pJmEFRiBN+m7cbmaqW7F9EqWCbNXoC2AiCJtHDgNpGvcoBXdE6k71bm0dhq9tpDjjJcM5plzelk5L9FG4IBe71+du8yr3hDIWkEWHJEc60= X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR10MB1482 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.517, 18.0.874 definitions=2022-06-14_03:2022-06-13, 2022-06-14 signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 bulkscore=0 malwarescore=0 mlxscore=0 adultscore=0 suspectscore=0 mlxlogscore=912 spamscore=0 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2204290000 definitions=main-2206140049 X-Proofpoint-GUID: kSXP_Rrm6ahUIwTk6eKb760brabRGdhy X-Proofpoint-ORIG-GUID: kSXP_Rrm6ahUIwTk6eKb760brabRGdhy X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: David Airlie , dri-devel@lists.freedesktop.org, kernel-janitors@vger.kernel.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Return -EINVAL if logicvc_layer_formats_lookup() fails. Don't return success. Fixes: efeeaefe9be5 ("drm: Add support for the LogiCVC display controller") Signed-off-by: Dan Carpenter Acked-by: Paul Kocialkowski --- drivers/gpu/drm/logicvc/logicvc_layer.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/logicvc/logicvc_layer.c b/drivers/gpu/drm/logicvc/logicvc_layer.c index bae1c7f99569..9c94b67afbed 100644 --- a/drivers/gpu/drm/logicvc/logicvc_layer.c +++ b/drivers/gpu/drm/logicvc/logicvc_layer.c @@ -489,6 +489,7 @@ static int logicvc_layer_init(struct logicvc_drm *logicvc, if (!formats) { drm_err(drm_dev, "Failed to lookup formats for layer #%d\n", index); + ret = -EINVAL; goto error; }