Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp245992iob; Mon, 2 May 2022 18:23:52 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwEilA2ghGkXS9uroPOPIkPEOGiS99yUGu/gUc03I4aKZpU2j3SQ6wuqK2b6PhRttbg+KFo X-Received: by 2002:a65:42cc:0:b0:3a9:f71f:33f9 with SMTP id l12-20020a6542cc000000b003a9f71f33f9mr11839195pgp.391.1651541032503; Mon, 02 May 2022 18:23:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1651541032; cv=none; d=google.com; s=arc-20160816; b=FvvEvCCf209lb3Eu2BT9DIS67JMFDsIwWn2mh5I1BgigaUynqUx4Pj0rYHOuWLkpj7 sYeYgucGeSy41iA+uzgZ7/Pe96azIB2M81I37sluqfUuuUmpPJWpjLu41mOYeR9X+4Kv IvVSzRQlKRoRymQ7GffrzONDREEznNe1ggFlGNsmV62rNcO4LfQ788EOfsxsSJwiQhIg BX9Tlt8rX+isiMOlMvHiFS8vzhWzykAMSBp2fy0v6A8I58mfAa1HIuR0lujbNJ4ZaouT z7sDdu6c27Yopn+daDN3r3esu4Xs7NctVHPQjTeKAsVE8OyNpDEsvB4ieEczgqb2Xd4X XfKQ== 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 :references:in-reply-to:message-id:date:subject:cc:to:from; bh=nIvi6IOvv5xjOBCLllQujso0QujLTbO0unjA7MK78WQ=; b=aaKl459SZ8oZHyo6k3VqJIXkVxSvfT3LfcD4bbMqY4y78UV8BL3/Qh0pweNEPBZl8q wwUTVQLewh1gn/EhoOl5XuHIzUIiV0GN5B5Wdfuj5G7wFzZqCsApCfWTVHk771Zwf0YH KKcPlvmVLcPvV76bP3EQ88SH/CZyzSuKy6V4fR/WCgtGR/gXNiDD2AJxAa7N1tjc99Fu FzIB6eHj2z4xNYTTewYh4qU2/ES49/ILyPOeGoZiIC/5hsvGbrQjGTmsf7z4C6wMiL/Q 3Hji7CfPENVdRa8pbSoLGi845rOPHVYQZThg+/6ygkI/MOnutQQDz1gLXjKy57ZNbAYO KNDw== ARC-Authentication-Results: i=1; mx.google.com; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id e11-20020a170902f1cb00b0015d53c6c340si13935400plc.473.2022.05.02.18.23.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 May 2022 18:23:52 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id D78D32E08C; Mon, 2 May 2022 18:03:01 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238636AbiEBW1x (ORCPT + 99 others); Mon, 2 May 2022 18:27:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59008 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230161AbiEBW1q (ORCPT ); Mon, 2 May 2022 18:27:46 -0400 Received: from gloria.sntech.de (gloria.sntech.de [185.11.138.130]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 64A1FB1EA for ; Mon, 2 May 2022 15:24:14 -0700 (PDT) Received: from ip5b412258.dynamic.kabel-deutschland.de ([91.65.34.88] helo=phil.lan) by gloria.sntech.de with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nleSg-0005bu-0w; Tue, 03 May 2022 00:24:10 +0200 From: Heiko Stuebner To: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, dri-devel@lists.freedesktop.org, Yang Yingliang , linux-rockchip@lists.infradead.org Cc: Heiko Stuebner , markyao0591@gmail.com, hjc@rock-chips.com, daniel@ffwll.ch Subject: Re: [PATCH] drm/rockchip: vop: fix possible null-ptr-deref in vop_bind() Date: Tue, 3 May 2022 00:24:06 +0200 Message-Id: <165153020898.255051.10275204034959482615.b4-ty@sntech.de> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220422032854.2995175-1-yangyingliang@huawei.com> References: <20220422032854.2995175-1-yangyingliang@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RDNS_NONE, SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 On Fri, 22 Apr 2022 11:28:54 +0800, Yang Yingliang wrote: > It will cause null-ptr-deref in resource_size(), if platform_get_resource() > returns NULL, move calling resource_size() after devm_ioremap_resource() that > will check 'res' to avoid null-ptr-deref. Applied, thanks! [1/1] drm/rockchip: vop: fix possible null-ptr-deref in vop_bind() commit: f8c242908ad15bbd604d3bcb54961b7d454c43f8 Best regards, -- Heiko Stuebner