From patchwork Thu Aug 24 07:21:31 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sricharan Ramabadhran X-Patchwork-Id: 9919281 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 2D37860353 for ; Thu, 24 Aug 2017 07:26:57 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1E25E2885B for ; Thu, 24 Aug 2017 07:26:57 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 116C528A48; Thu, 24 Aug 2017 07:26:57 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 87E2B2885B for ; Thu, 24 Aug 2017 07:26:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=ZbMLdIpc2VC/yxt6zLglji2bZ+JMVY2/Q+60XN7uDYE=; b=STjd4/XQKY0kkvzaouVFTV7MKY EqIBfdEyvK2HZDiMwMuXWCfUyAKywQOYqEKnbUhf/JMt5mIktaZKVvXzBOvr8QUJcfX/fWHh2cofE 4SqCdhqkNYpI+tW1DRF+A+CTfwYOzBRcT0VhE4bjlW+oooV2tLDRpyU6eeuN0bdFw+Ov+VV5QRq93 WbbnzJGYqfQyjAQpbvvcuOiEXGNb1swG+dZ2bPEFb+YrOpPK4jQxUAWwAduXH+8nbiwFEETSjbm4u LMZHOCFxVm5YhVSBvpO3jvLrGN05yaeQdmsQteUUnqgIwJh+LfASUAogRl0sXR7+T+i/k0QnLkafg 99fEIDwQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1dkmXN-0004lN-Gr; Thu, 24 Aug 2017 07:26:45 +0000 Received: from smtp.codeaurora.org ([198.145.29.96]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1dkmTS-0008E2-MU for linux-arm-kernel@lists.infradead.org; Thu, 24 Aug 2017 07:22:44 +0000 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 8CF996073E; Thu, 24 Aug 2017 07:22:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1503559345; bh=BaSnwC8YE2ucEARmtimxcQzOcnBXK1CpijaBmcSuenw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=e3iV57lbzICGFsFBDwAG/FZCCbygqKZD8pnDYCE46L90wvaVR/9LBFbYiA+VIxupb A3Dj5S6kSN2KbfU3l2rEcy5se6uSIbZF1bxhtvN5nwuFUFYZ5M7Y6TSn7WvUBlZDkV X3y6/xe9TPkVrQXJRdJai2EhDrH+H3f+Ft48pgHI= Received: from srichara-linux.qualcomm.com (blr-c-bdr-fw-01_globalnat_allzones-outside.qualcomm.com [103.229.19.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: sricharan@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 6A33160722; Thu, 24 Aug 2017 07:22:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1503559342; bh=BaSnwC8YE2ucEARmtimxcQzOcnBXK1CpijaBmcSuenw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=OV26Oy5E9yLyDw3s8qBdvK3unsr2UpLgCBF5WOLRN3LdfnDfZlRATR4DAxd4+a1yb HrwRr6+MVdKcQ29AY5NGfiXVLmaEjNXnqLGk+tRJx0CwtWVj2AjEFtrzIS3C9P2fNw 6l2nNLsMXONKlyr9o9HFkpPV0DfwX8TsqRAVpYDQ= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 6A33160722 Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=sricharan@codeaurora.org From: Sricharan R To: ohad@wizery.com, bjorn.andersson@linaro.org, linux-remoteproc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH v2 09/20] rpmsg: glink: Fix default case while handling received commands Date: Thu, 24 Aug 2017 12:51:31 +0530 Message-Id: <1503559302-3744-10-git-send-email-sricharan@codeaurora.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1503559302-3744-1-git-send-email-sricharan@codeaurora.org> References: <1503559302-3744-1-git-send-email-sricharan@codeaurora.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170824_002242_912612_CB3936EB X-CRM114-Status: GOOD ( 10.58 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: sricharan@codeaurora.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Currently if we receive a command that we still do not support, then its simply discarded. While doing so, the RX FIFO pointer also needs to be incremented. Fixing this. Signed-off-by: Sricharan R Acked-by: Arun Kumar Neelakantam --- drivers/rpmsg/qcom_glink_native.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/rpmsg/qcom_glink_native.c b/drivers/rpmsg/qcom_glink_native.c index 50a8008..9a58925 100644 --- a/drivers/rpmsg/qcom_glink_native.c +++ b/drivers/rpmsg/qcom_glink_native.c @@ -541,6 +541,7 @@ static irqreturn_t qcom_glink_native_intr(int irq, void *data) ret = 0; break; default: + qcom_glink_rx_advance(glink, ALIGN(sizeof(msg), 8)); dev_err(glink->dev, "unhandled rx cmd: %d\n", cmd); ret = -EINVAL; break;