Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp1625808pxk; Fri, 18 Sep 2020 19:04:08 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxUlYyR9B8szRLs//EmDjxPs0bEwHDkNXjf3rQzsrYA9bjOQPKGQeC0HjCGXaGHJaAo0/ki X-Received: by 2002:a17:906:a101:: with SMTP id t1mr38146058ejy.203.1600481048319; Fri, 18 Sep 2020 19:04:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600481048; cv=none; d=google.com; s=arc-20160816; b=cS27q1PTK/Yut/AztmvfZDsE3VJYCVWvG5I1GepWuDBIP2wL1bK/GIvGIFrhbbuSZ/ oV99YBkExmkKy960pcqOhsbtuUbAfUPV+N/A3PD4/g8fwgBYsjYfrRFAag7vBYQaPun+ fAUZqvptCprPuIKZ2hTThuc1uuKSUMRMmrjp2rOaclGgicm702iSPEw3pdu5ry1D3peH RYc4oyBCpWo/hBbAC4EyeGW8dk57uWKmpPWpvuDw0oGtrHCKwwN42T/SQDE4tds17O5u 8FS0AhT1ZjoosCuDnc/wQd2/EM2E73S2VBAzehuHS13fK5jn4lS4b3xbBkuVNwJXDQKy I1bw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:subject:cc:to:from:dmarc-filter :sender:dkim-signature; bh=BURDtrM4/JhTY390gcc6/L/mWWU1YCPB+gfT4j3BWUs=; b=VTCmrjbkblsw8cYBe4j4EswUVnj8jsFSFY8JZ7r/Gf1Vds1ynqV0TSm/PkFedQQDUm tBs5eQf2eHfhAihqu3k/t804ddVKllKz9i/h5ZflGqdl1F6aJnmOobqMJYiHzjMJpbJ1 VgysvDKCCDJclkhGHte7iGADO0IIeft1eoUkjBFwI8d3cBmBFZeWEDuUdiqskUewh5KK ulCQM0SAh3tlbcS9jFZ/nas3Q28ptdZvGxRoaEo0SKmI9rFazCcR4kZF4NebxAPkA41w FKSZtqpa4lVpTEgovB/cpda7OhIwBRJ3W24NBIT4KgVoSL7CZ9Sf3RlPIQ2Ic3XO26g+ NA2Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mg.codeaurora.org header.s=smtp header.b=H+pHxCcW; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id de17si3577737edb.89.2020.09.18.19.03.45; Fri, 18 Sep 2020 19:04:08 -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=@mg.codeaurora.org header.s=smtp header.b=H+pHxCcW; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726332AbgISCCq (ORCPT + 99 others); Fri, 18 Sep 2020 22:02:46 -0400 Received: from so254-54.mailgun.net ([198.61.254.54]:32247 "EHLO so254-54.mailgun.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726308AbgISCCp (ORCPT ); Fri, 18 Sep 2020 22:02:45 -0400 DKIM-Signature: a=rsa-sha256; v=1; c=relaxed/relaxed; d=mg.codeaurora.org; q=dns/txt; s=smtp; t=1600480964; h=Message-Id: Date: Subject: Cc: To: From: Sender; bh=BURDtrM4/JhTY390gcc6/L/mWWU1YCPB+gfT4j3BWUs=; b=H+pHxCcWpoifhp+xNvnR0/syDm28rU3l+CogB5KymezTDzJEGvmmQFABdseMYFwgBdWBiJ05 mU1HAR+KlOwKt6NSEOjakYR7dhQQKchiuUv6yM7RPwB/CO+IlxtpJFxLb3DmWpZo3q5MItDv G8duNezWcjtYROd2biW105//FEk= X-Mailgun-Sending-Ip: 198.61.254.54 X-Mailgun-Sid: WyI0MWYwYSIsICJsaW51eC1rZXJuZWxAdmdlci5rZXJuZWwub3JnIiwgImJlOWU0YSJd Received: from smtp.codeaurora.org (ec2-35-166-182-171.us-west-2.compute.amazonaws.com [35.166.182.171]) by smtp-out-n01.prod.us-west-2.postgun.com with SMTP id 5f6566c436c8ce93e8ab2058 (version=TLS1.2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256); Sat, 19 Sep 2020 02:02:44 GMT Sender: bbhatt=codeaurora.org@mg.codeaurora.org Received: by smtp.codeaurora.org (Postfix, from userid 1001) id EE024C43382; Sat, 19 Sep 2020 02:02:43 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-caf-mail-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=ALL_TRUSTED,BAYES_00,SPF_FAIL autolearn=no autolearn_force=no version=3.4.0 Received: from malabar-linux.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: bbhatt) by smtp.codeaurora.org (Postfix) with ESMTPSA id 19B96C433CB; Sat, 19 Sep 2020 02:02:43 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 19B96C433CB Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; spf=fail smtp.mailfrom=bbhatt@codeaurora.org From: Bhaumik Bhatt To: manivannan.sadhasivam@linaro.org Cc: linux-arm-msm@vger.kernel.org, hemantk@codeaurora.org, jhugo@codeaurora.org, linux-kernel@vger.kernel.org, Bhaumik Bhatt Subject: [PATCH v1 00/10] Bug fixes and improvements for MHI power operations Date: Fri, 18 Sep 2020 19:02:25 -0700 Message-Id: <1600480955-16827-1-git-send-email-bbhatt@codeaurora.org> X-Mailer: git-send-email 2.7.4 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Bug fixes and improvements for MHI powerup and shutdown handling. Firmware load function names are updated to accurately reflect their purpose. Closed certain design gaps where the host (MHI bus) would allow clients to operate after a power down or error detection. Move to an error state sooner based on different scenarios. These patches were tested on arm64 and X86_64 architectures. Bhaumik Bhatt (10): bus: mhi: core: Use appropriate names for firmware load functions bus: mhi: core: Move to using high priority workqueue bus: mhi: core: Skip device wake in error or shutdown states bus: mhi: core: Use the IRQF_ONESHOT flag for the BHI interrupt line bus: mhi: core: Disable IRQs when powering down bus: mhi: core: Improve shutdown handling after link down detection bus: mhi: core: Move to SYS_ERROR regardless of RDDM capability bus: mhi: core: Move to an error state on any firmware load failure bus: mhi: core: Move to an error state on mission mode failure bus: mhi: core: Mark device inactive soon after host issues a shutdown drivers/bus/mhi/core/boot.c | 59 ++++++++++++++++++++++----------------- drivers/bus/mhi/core/init.c | 10 ++++++- drivers/bus/mhi/core/internal.h | 1 + drivers/bus/mhi/core/main.c | 28 +++++++++++++------ drivers/bus/mhi/core/pm.c | 62 ++++++++++++++++++++++++++++------------- include/linux/mhi.h | 2 ++ 6 files changed, 108 insertions(+), 54 deletions(-) -- The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project