Received: by 10.223.185.116 with SMTP id b49csp1076209wrg; Wed, 21 Feb 2018 11:40:46 -0800 (PST) X-Google-Smtp-Source: AH8x227eYSBr7EKtgOvYXAqS3hH/p7LjhLktSCT+HIVgrWGIzcz+XdLgcRq0dPd+xntkzvahj64a X-Received: by 10.98.17.147 with SMTP id 19mr4295512pfr.160.1519242046584; Wed, 21 Feb 2018 11:40:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519242046; cv=none; d=google.com; s=arc-20160816; b=V1IapO1UCpCV0kVabarO+/F7SpIIuqMQ+6IztLSr9UlFn8FJDhWBsUa2krceIPxf96 kv/VvDw+Zvq0oIQbML8FMlk24m6hEhIiOn/NLIMYqhND0OcShW+oX0WAnHXq1pEtnmoo fXj+Q+Qt56NlD2V9raXPpdBJLWnyXi6RVzUlS/JutxYcNcb5egDuGkHhI+wEPi7M5VrT ribmicGb8+ljDqrCqs0jvslYTrVduB4qvRAifAgXg1dRJQc8iCTj3gAjhlocTuYj4zz4 ccE4qEWIF8DldSqV8ZwcjtIApsEufWZ2ZPdkRBa+H92zDDI5pA9PlvDiyBsNm3XEsKMA 8sVw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dmarc-filter :dkim-signature:dkim-signature:arc-authentication-results; bh=FGszm6QlURA0scO5iteY6OmytGyb0PtTd14lfQGrwdM=; b=zwvT8I2GeZjzws6VbPZCOp9xBcVMQ5NkN4lpNZglr0OKy0DhZ7bN9i/4L7CJCsBNw2 0h5NFeEf5dz+ihSeOkz50EFf5lJuY0EyFCqYOUsR92IrqLYnjL/Wzh8VXKvxmGCRi1Op mM6KpKUdHbfQShcMf6/C9yewaT8j09vSB9yjwOYH34ZpjYg4QP1Fva8jxdLbgydwnC44 OXkJJHwiRPHsWVlOCnnNLqCyMYVP7uwA+++OTZkvF8x7lSLhuzZYaY6m0SCy1JlnYKQ7 X+2iXbj6CODuN0oC4phi6/6nA91Woo8eAjriY17f9J/0IV5D1P75r0JBGHsrnjjeCk1a QK2Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=UyP6HlVw; dkim=pass header.i=@codeaurora.org header.s=default header.b=ZQUiupi2; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e87si280996pfj.381.2018.02.21.11.40.30; Wed, 21 Feb 2018 11:40:46 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=UyP6HlVw; dkim=pass header.i=@codeaurora.org header.s=default header.b=ZQUiupi2; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751795AbeBUTjv (ORCPT + 99 others); Wed, 21 Feb 2018 14:39:51 -0500 Received: from smtp.codeaurora.org ([198.145.29.96]:53450 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751698AbeBUTjq (ORCPT ); Wed, 21 Feb 2018 14:39:46 -0500 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 28B0D609EF; Wed, 21 Feb 2018 19:39:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1519241986; bh=b18kK7cIfWqoOICP7MLUYhIbicLl7QAyfJuSKew6Ip4=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=UyP6HlVwIpPMRtjoJ153xR0NELhJWGXX/I83D6HbFjql6c6G1gETCGBwOAMgSWhhJ JS9uTfTR6l2J5CLdsXkcPW2KVFiYDEwhg6/5WgIw5ae73hY9h2z/wkNwh5F3PVcVgY DqTwSfxiQshFBRvfypY14JZrQB6Iucg65J7PJuD0= X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on pdx-caf-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.8 required=2.0 tests=ALL_TRUSTED,BAYES_00, DKIM_SIGNED,T_DKIM_INVALID autolearn=no autolearn_force=no version=3.4.0 Received: from [192.168.142.6] (i-global254.qualcomm.com [199.106.103.254]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: clew@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 7AE626019F; Wed, 21 Feb 2018 19:39:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1519241985; bh=b18kK7cIfWqoOICP7MLUYhIbicLl7QAyfJuSKew6Ip4=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=ZQUiupi2nakQ9mnL76pWdZ2CJP40LTunXvvla5LRgTNQJ3qI0TMc5qlysJIMb7nBM XP0DiSAwfvc5kAMi77GAiJKW6fjldabpzhCtQT32YyvDnkGwGVM+NI66A2QNYMk1O2 m509p28vIGEVdYznln4fjpPFYQhuimlUhPxrvEDU= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 7AE626019F 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=clew@codeaurora.org Subject: Re: [PATCH] rpmsg: glink: Use spinlock in tx path To: Bjorn Andersson , Ohad Ben-Cohen , Arun Kumar Neelakantam , Srini Kandagatla Cc: linux-remoteproc@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org References: <20180213190404.25026-1-bjorn.andersson@linaro.org> From: Chris Lew Message-ID: Date: Wed, 21 Feb 2018 11:39:45 -0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <20180213190404.25026-1-bjorn.andersson@linaro.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hey Bjorn, Minor issue with the glink patch. Thanks, Chris On 2/13/2018 11:04 AM, Bjorn Andersson wrote: [..] > @@ -288,15 +288,14 @@ static int qcom_glink_tx(struct qcom_glink *glink, > const void *data, size_t dlen, bool wait) > { > unsigned int tlen = hlen + dlen; > + unsigned long flags; > int ret; > > /* Reject packets that are too big */ > if (tlen >= glink->tx_pipe->length) > return -EINVAL; > > - ret = mutex_lock_interruptible(&glink->tx_lock); > - if (ret) > - return ret; > + spin_lock_irqsave(&glink->tx_lock, flags); > qcom_glink_tx will return an uninitialized ret value with removal of mutex_lock_interruptible. -- Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project