Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp1426821pxa; Thu, 20 Aug 2020 11:00:00 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzSc/GQ+huqCIMWvl+jYa3yqkwNGLMVzgMGqsS4rKxsC0O+RT0RgkTlhrH5owdRXZueP3Yz X-Received: by 2002:a17:906:af51:: with SMTP id ly17mr4312522ejb.81.1597946400280; Thu, 20 Aug 2020 11:00:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597946400; cv=none; d=google.com; s=arc-20160816; b=LWKUKgTTAieg43+uvjlQOITI0YZDzJ0jKxP6Emjn3odnvELphYWg6VQqLioWenGE8S ILOOHx6/IoGtPBEId51COCYg65DN1MJU45N17mjRSnhi291+MH2iPvPVWKhPq1ZCliJW 1r0MC9D/3Tn9/TwjOMVj3LAfIDr+Rg76n4ZLQ0mYZCSq4MitG9PJA8fryuX/zEvsRv+4 HJDI8v6pvz/EkuVV0DX4V6gECX3E+XyT44lzdySSvSmVeIR1fABaT4Z5YkQ4WJsXnpMn ChrJO7kbGsHVpCRrXmO6WJqTG6YCin4KlrVXWfASgfFl6KVoh9hj8XEQuMk1+Hfv+h9l 2nRw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:to:from:dkim-signature; bh=zFwgKY8M1YvMdF6A1MZQr5OX450yZVwCd9DoRqj8Oac=; b=oemgR3224WrC5v9KWXZ7xDOzo6cwGf0EK7QGjclQ8mkDAm1O2T7qLMKt1MdJvJk29+ N2WDiJxCMtom2fHN0Qi6TK8zoCudIn20kKNEiGB87vc7j7usuGSLYbNZhFAz3O18yeOC i+b8nAgCntC3BwXGxJEMu5YT9CEMv3mJoU9g0z1ZrWEZAn4uyDqY5/55ulN6K23xtb9a 6cdLyTjNlnzQADRuRgp5vA/H0pzKRQ2xZAteLzH7e/QvKe04DSNsoPEnEz++BwOYMqZz QzjG8vSAXUQVVFEFwO5uzPMWSiJDcImdSGk2nhV6LVflmXmH45kRoe8ZR/7nmgfyPexK VUNw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="gEdI/Vor"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g22si1809550ejw.97.2020.08.20.10.59.35; Thu, 20 Aug 2020 11:00:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="gEdI/Vor"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726309AbgHTR6s (ORCPT + 99 others); Thu, 20 Aug 2020 13:58:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51078 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725819AbgHTR6q (ORCPT ); Thu, 20 Aug 2020 13:58:46 -0400 Received: from mail-wr1-x441.google.com (mail-wr1-x441.google.com [IPv6:2a00:1450:4864:20::441]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 99B02C061385 for ; Thu, 20 Aug 2020 10:58:46 -0700 (PDT) Received: by mail-wr1-x441.google.com with SMTP id a14so2952414wra.5 for ; Thu, 20 Aug 2020 10:58:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=zFwgKY8M1YvMdF6A1MZQr5OX450yZVwCd9DoRqj8Oac=; b=gEdI/VorowmVYUmYIAgIJvT3GOEKZl+dMBWPHxFGafXrGNuusg1aHNcprr/9GpKUfb iAwi3wzEXEL5V+isGkdNfHkBwsZB87GNq52EY8vm1ICS84jMS+66QIttaB13wrHGyXTi vGPDVdiHXnESt3QYl3SQ3XOhoj7yd4EFtQkXSeUJmYlINRtnjSIWrnX4hiat3SbG6JYL V4TRAydcp5SQazAhY1kBahWw9dC3Y+QcW3cOlC/4iAr7w6rU2Pu51mgg6gRpHN8hdxJv 7i3UVNDVp7tGOiXbW0lYqqqujYbpuwGLUyQ8dklG0mEfklFVpGjg7tDWzEcB0eWCtUYp MqGQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=zFwgKY8M1YvMdF6A1MZQr5OX450yZVwCd9DoRqj8Oac=; b=pSDSbcoPfBg7XmFgRgN4JotjkwtsENmxHXcEq6lYEwYTUEK7zuYhYVVyAoODui9+h0 iQiarqUBzwXSplEf+4xyc2GybWgZSZx4Vnfde0aJ3CzQZ4IfwwD4mrh/SkSkqhfR0GPd CKeI99vo9P+8VpoyvjjokN3xQ99H48RdYd9L2dbDnI8PiVSq4JJIcF15tQz4ZeLk1WuT txIX/3lJGw2OGR2dQd3mC5o1vcqihL80YjXIrCb+2hyytt62WJa/0j0a2XyrYF2G0Fev EX2K1dbP/4F9GbJmskfkuPKx8SSYXgklJdtbd1vGjFB6vaWen0JtqMyBH9S4rcMvG131 gtgQ== X-Gm-Message-State: AOAM530NZLXjs86wByaal5t8GgkV/a6COzHrsChfjIcTnAHbUgB3KsCI 3jhkZdJ0LCdTEyRuJDPvX6c= X-Received: by 2002:a5d:4910:: with SMTP id x16mr4183128wrq.131.1597946325161; Thu, 20 Aug 2020 10:58:45 -0700 (PDT) Received: from localhost.localdomain (cpc83661-brig20-2-0-cust443.3-3.cable.virginm.net. [82.28.105.188]) by smtp.gmail.com with ESMTPSA id g8sm5513496wme.13.2020.08.20.10.58.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 20 Aug 2020 10:58:44 -0700 (PDT) From: Alex Dewar To: Alex Deucher , =?UTF-8?q?Christian=20K=C3=B6nig?= , David Airlie , Daniel Vetter , Evan Quan , Nirmoy Das , Alex Dewar , amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: [PATCH] drm/amd/pm: Remove unnecessary cast Date: Thu, 20 Aug 2020 18:58:06 +0100 Message-Id: <20200820175809.841479-1-alex.dewar90@gmail.com> X-Mailer: git-send-email 2.28.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org In init_powerplay_table_information() the value returned from kmalloc() is cast unnecessarily. Remove cast. Issue identified with Coccinelle. Signed-off-by: Alex Dewar --- drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega12_processpptables.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega12_processpptables.c b/drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega12_processpptables.c index 195d8539fbb4..740e2fc7a034 100644 --- a/drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega12_processpptables.c +++ b/drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega12_processpptables.c @@ -252,7 +252,7 @@ static int init_powerplay_table_information( phm_copy_clock_limits_array(hwmgr, &pptable_information->power_saving_clock_max, powerplay_table->PowerSavingClockMax, ATOM_VEGA12_PPCLOCK_COUNT); phm_copy_clock_limits_array(hwmgr, &pptable_information->power_saving_clock_min, powerplay_table->PowerSavingClockMin, ATOM_VEGA12_PPCLOCK_COUNT); - pptable_information->smc_pptable = (PPTable_t *)kmalloc(sizeof(PPTable_t), GFP_KERNEL); + pptable_information->smc_pptable = kmalloc(sizeof(PPTable_t), GFP_KERNEL); if (pptable_information->smc_pptable == NULL) return -ENOMEM; -- 2.28.0