From patchwork Wed Nov 9 09:26:46 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pavan Kondeti X-Patchwork-Id: 13037284 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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id E0A31C433FE for ; Wed, 9 Nov 2022 09:28:11 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 5DF606B0072; Wed, 9 Nov 2022 04:28:11 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 58F3A6B0073; Wed, 9 Nov 2022 04:28:11 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 457E96B0074; Wed, 9 Nov 2022 04:28:11 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0010.hostedemail.com [216.40.44.10]) by kanga.kvack.org (Postfix) with ESMTP id 36B7F6B0072 for ; Wed, 9 Nov 2022 04:28:11 -0500 (EST) Received: from smtpin26.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id 020DBC02C3 for ; Wed, 9 Nov 2022 09:28:10 +0000 (UTC) X-FDA: 80113377582.26.1BCFDC3 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) by imf23.hostedemail.com (Postfix) with ESMTP id 9F251140012 for ; Wed, 9 Nov 2022 09:28:02 +0000 (UTC) Received: from pps.filterd (m0279872.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 2A981qS5005483; Wed, 9 Nov 2022 09:26:55 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h=from : to : cc : subject : date : message-id : mime-version : content-type; s=qcppdkim1; bh=IGlfqAanlK48mImb41Tw+3F6UP5C64sbnIN3RocolP8=; b=fK3wkGjgTU1/q9Vajt0tN+tfevRtk+kpEsBVa2sPzlFlUHJisQ2kQIwWndZVdNHRwaeG ogP/2hHsovdeovZ60a2DQYP6M+8PGuxgWFtAL8ksEP3bJHV/5IGVnrA3WENmvFpmwXyk M51JziNq8qgQSZdMxF3SNvjnvTsG3gNQ1yLvRZE+XOJaq2Ypc2Y8G3qO/yxXNjVCoI9B hwTSOddWODCJRfGb/PoRPx53YA8V4gRxGY/e6Gg5rqDuXe5qx1ncdJSTwh+K+v1MhW3Y /+mJi3dkfenyyT0UBZ9yztDFF1EVqWdCWyMK4OHEPA2vl7krmCM4GlLMR2xM33VR2sXu gg== Received: from nalasppmta02.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3kr68ngh68-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 09 Nov 2022 09:26:55 +0000 Received: from nalasex01a.na.qualcomm.com (nalasex01a.na.qualcomm.com [10.47.209.196]) by NALASPPMTA02.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 2A99QsHa021939 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 9 Nov 2022 09:26:54 GMT Received: from quicinc.com (10.80.80.8) by nalasex01a.na.qualcomm.com (10.47.209.196) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.29; Wed, 9 Nov 2022 01:26:51 -0800 From: Pavankumar Kondeti To: Andrew Morton , Alexander Potapenko , Marco Elver , Dmitry Vyukov CC: Peter Zijlstra , , , , Pavankumar Kondeti Subject: [PATCH] mm/kfence: remove hung_task cruft Date: Wed, 9 Nov 2022 14:56:46 +0530 Message-ID: <1667986006-25420-1-git-send-email-quic_pkondeti@quicinc.com> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: nasanex01b.na.qualcomm.com (10.46.141.250) To nalasex01a.na.qualcomm.com (10.47.209.196) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-GUID: 64oPdNQofgGegYgIaFrSNehMaTYkmIqm X-Proofpoint-ORIG-GUID: 64oPdNQofgGegYgIaFrSNehMaTYkmIqm X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.219,Aquarius:18.0.895,Hydra:6.0.545,FMLib:17.11.122.1 definitions=2022-11-09_03,2022-11-08_01,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 impostorscore=0 phishscore=0 malwarescore=0 mlxlogscore=869 suspectscore=0 clxscore=1011 priorityscore=1501 lowpriorityscore=0 spamscore=0 bulkscore=0 adultscore=0 mlxscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2210170000 definitions=main-2211090072 ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1667986087; a=rsa-sha256; cv=none; b=Tf3nTzB9XbTEeItYKX4emDHBD8JJDnrElXbsZzbImyvmnRLspy5gsbCKhQf9xKAqs/UIDU WJi4c5snzpx9KElLTepfwERKjEZ+s8TE3nJRfbBNVAAhp+4PwNCB1a7gTtMKyAjyDalY2c y/iHnszfzU3ZzbIYiowBL5SCbbRJIbY= ARC-Authentication-Results: i=1; imf23.hostedemail.com; dkim=pass header.d=quicinc.com header.s=qcppdkim1 header.b=fK3wkGjg; dmarc=pass (policy=none) header.from=quicinc.com; spf=pass (imf23.hostedemail.com: domain of quic_pkondeti@quicinc.com designates 205.220.180.131 as permitted sender) smtp.mailfrom=quic_pkondeti@quicinc.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1667986087; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding:in-reply-to: references:dkim-signature; bh=IGlfqAanlK48mImb41Tw+3F6UP5C64sbnIN3RocolP8=; b=FE0TOToAJ1vdu8/hmfO+0KYBz4yFh5A0DSxS+6QmefoXNntRw088TIJsR5UpxsOs8sVEjJ uxLJFGVtxdbO5me8hyIf2qFIVC4I7hDPmHyAGm+iyTr0EvgsPgJ6bITbdxkAhGZ6zhIJVa OSQ4u0UIAxed9/NXVwGAW67AgvDI/0w= Authentication-Results: imf23.hostedemail.com; dkim=pass header.d=quicinc.com header.s=qcppdkim1 header.b=fK3wkGjg; dmarc=pass (policy=none) header.from=quicinc.com; spf=pass (imf23.hostedemail.com: domain of quic_pkondeti@quicinc.com designates 205.220.180.131 as permitted sender) smtp.mailfrom=quic_pkondeti@quicinc.com X-Rspam-User: X-Stat-Signature: bnh5iihjoj3xdhnj19tjr5b1az31qhie X-Rspamd-Queue-Id: 9F251140012 X-Rspamd-Server: rspam05 X-HE-Tag: 1667986082-267639 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: commit fdf756f71271 ("sched: Fix more TASK_state comparisons") makes hung_task not to monitor TASK_IDLE tasks. The special handling to workaround hung_task warnings is not required anymore. Signed-off-by: Pavankumar Kondeti Reviewed-by: Marco Elver --- mm/kfence/core.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/mm/kfence/core.c b/mm/kfence/core.c index 1417888..08f5bd6 100644 --- a/mm/kfence/core.c +++ b/mm/kfence/core.c @@ -26,7 +26,6 @@ #include #include #include -#include #include #include #include @@ -799,16 +798,7 @@ static void toggle_allocation_gate(struct work_struct *work) /* Enable static key, and await allocation to happen. */ static_branch_enable(&kfence_allocation_key); - if (sysctl_hung_task_timeout_secs) { - /* - * During low activity with no allocations we might wait a - * while; let's avoid the hung task warning. - */ - wait_event_idle_timeout(allocation_wait, atomic_read(&kfence_allocation_gate), - sysctl_hung_task_timeout_secs * HZ / 2); - } else { - wait_event_idle(allocation_wait, atomic_read(&kfence_allocation_gate)); - } + wait_event_idle(allocation_wait, atomic_read(&kfence_allocation_gate)); /* Disable static key and reset timer. */ static_branch_disable(&kfence_allocation_key);