Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751488AbbHQSWQ (ORCPT ); Mon, 17 Aug 2015 14:22:16 -0400 Received: from foss.arm.com ([217.140.101.70]:46393 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751181AbbHQSWP (ORCPT ); Mon, 17 Aug 2015 14:22:15 -0400 From: Javi Merino To: linux-pm@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Javi Merino Subject: [PATCH 0/2] Fixes for cpu cooling Date: Mon, 17 Aug 2015 19:21:41 +0100 Message-Id: <1439835703-16470-1-git-send-email-javi.merino@arm.com> X-Mailer: git-send-email 1.9.1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 790 Lines: 20 Commit c36cf0717631 ("thermal: cpu_cooling: implement the power cooling device API") introduced two bugs: a call to kcalloc() (that might sleep) under RCU and not freeing the allocation when it's no longer needed. This series fixes both issues. Javi Merino (2): thermal: cpu_cooling: don't call kcalloc() under rcu_read_lock thermal: cpu_cooling: free power table on error or when unregistering drivers/thermal/cpu_cooling.c | 52 ++++++++++++++++++++++++++----------------- 1 file changed, 31 insertions(+), 21 deletions(-) -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/