Received: by 2002:a05:6a10:1a4d:0:0:0:0 with SMTP id nk13csp1629525pxb; Wed, 9 Feb 2022 00:34:05 -0800 (PST) X-Google-Smtp-Source: ABdhPJwBNRTrsaLXFsVl/e9kycNkrbArAYYNHZKa7w3dAEYTdOMkaWI++BWsDi+qJUSi29TQMTfg X-Received: by 2002:a17:90a:7c02:: with SMTP id v2mr2189166pjf.81.1644395644840; Wed, 09 Feb 2022 00:34:04 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1644395644; cv=none; d=google.com; s=arc-20160816; b=uOJSn9e9ylBm68+sM9uu7TYR5p2guVQYwCGeaMsH0DYdvPvsYAxgFRnDG9XzxjoUrh APJvO+eX9ghGB8eFs7bz6m5JPNbUYArLOxwOoItZMyYI7ckRmH2+OkQz0aq+sM9boa5n XYIu12dWNWdSC9Vxl4z6iXr2qMB0dX84Jfeds+YK/ESOP+zlZuqIt2eK3wJk/4mwPcZw UJKJ1kfWf4iDZ/3WsYrGWUsylZtXaiFcU3dl23ox9wQ9t1jjcMEDJ95ZUBnoAHcp3qHT koHPaT4Mf28SXcALrZ1KM3O2yRhnA2bz0fb3LDKNh637UNue/2qkgCOdsYj3sXmR9JfA PJEA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from :dkim-signature; bh=B0beRUcpy6mm/IC1BcwaxatHK/JKj1WU47oyT+N03mg=; b=RRtv8YSNAScfH8EcwoTeLvoJX2zxyfcxbcCcjNkZ2vEsNucHuaqafjlS/VyntnqYuM dut9iKhzsbG6jAOuQ5nNbZOBwo8kwB+lCM8GsVpecMH/Z8IwqKAgRZRTPoVNFsCe1KZ+ 9AhWUSjZnoYBlmtnhHlXTmkGyUoYounklVZyw/eUqLrJ7xjcuimqHDtMgIxgLthmWVh3 HgUi/AnW8vZwqqZvq3xO3MCqZ3C7YPJrYQdOtK4rBaPAAS4frwjBgkpVOSsy8WBYsgU8 9AaGVxyuBaTrJ33DSxUsb4YdlJ6NIg5an9+LahCXN/I4v+j+joRaIniDrPQv9K7ociJ4 YafQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcdkim header.b=PmOrBH44; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id t6si16041129pfj.19.2022.02.09.00.34.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Feb 2022 00:34:04 -0800 (PST) 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; dkim=pass header.i=@quicinc.com header.s=qcdkim header.b=PmOrBH44; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 480ACC043182; Wed, 9 Feb 2022 00:33:57 -0800 (PST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1388113AbiBHWcW (ORCPT + 99 others); Tue, 8 Feb 2022 17:32:22 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43554 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1386225AbiBHTop (ORCPT ); Tue, 8 Feb 2022 14:44:45 -0500 Received: from alexa-out-sd-01.qualcomm.com (alexa-out-sd-01.qualcomm.com [199.106.114.38]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BE714C0613CB; Tue, 8 Feb 2022 11:44:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; i=@quicinc.com; q=dns/txt; s=qcdkim; t=1644349484; x=1675885484; h=from:to:cc:subject:date:message-id:mime-version; bh=B0beRUcpy6mm/IC1BcwaxatHK/JKj1WU47oyT+N03mg=; b=PmOrBH44twkgttlFTrbNznHsN82tq/QyRPYBRGwKespy+V1TQ7XMOuuQ d39cTRA8h5t8m34AxiK2mz7FTOLeM7Ais3fD73M80b6wnWbjL43yAliuQ JJhLBoU46nnjAhA5TmZmfMyqCiaMVtvzKgY1XnbTtsL9u8kxe6k/hiQjd w=; Received: from unknown (HELO ironmsg02-sd.qualcomm.com) ([10.53.140.142]) by alexa-out-sd-01.qualcomm.com with ESMTP; 08 Feb 2022 11:44:44 -0800 X-QCInternal: smtphost Received: from nasanex01c.na.qualcomm.com ([10.47.97.222]) by ironmsg02-sd.qualcomm.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 08 Feb 2022 11:44:43 -0800 Received: from nalasex01a.na.qualcomm.com (10.47.209.196) by nasanex01c.na.qualcomm.com (10.47.97.222) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.922.19; Tue, 8 Feb 2022 11:44:43 -0800 Received: from abhinavk-linux.qualcomm.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.922.19; Tue, 8 Feb 2022 11:44:42 -0800 From: Abhinav Kumar To: , CC: Abhinav Kumar , , , , , , , , , , , , , Subject: [PATCH] devcoredump: increase the device delete timeout to 10 mins Date: Tue, 8 Feb 2022 11:44:32 -0800 Message-ID: <1644349472-31077-1-git-send-email-quic_abhinavk@quicinc.com> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 Content-Type: text/plain 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-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,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 There are cases where depending on the size of the devcoredump and the speed at which the usermode reads the dump, it can take longer than the current 5 mins timeout. This can lead to incomplete dumps as the device is deleted once the timeout expires. One example is below where it took 6 mins for the devcoredump to be completely read. 04:22:24.668 23916 23994 I HWDeviceDRM::DumpDebugData: Opening /sys/class/devcoredump/devcd6/data 04:28:35.377 23916 23994 W HWDeviceDRM::DumpDebugData: Freeing devcoredump node Increase the timeout to 10 mins to accommodate system delays and large coredump sizes. Signed-off-by: Abhinav Kumar --- drivers/base/devcoredump.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/base/devcoredump.c b/drivers/base/devcoredump.c index f4d794d..6b83ae5 100644 --- a/drivers/base/devcoredump.c +++ b/drivers/base/devcoredump.c @@ -18,8 +18,8 @@ static struct class devcd_class; /* global disable flag, for security purposes */ static bool devcd_disabled; -/* if data isn't read by userspace after 5 minutes then delete it */ -#define DEVCD_TIMEOUT (HZ * 60 * 5) +/* if data isn't read by userspace after 10 minutes then delete it */ +#define DEVCD_TIMEOUT (HZ * 60 * 10) struct devcd_entry { struct device devcd_dev; -- 2.7.4