Received: by 2002:a05:7412:b130:b0:e2:908c:2ebd with SMTP id az48csp2027476rdb; Sun, 19 Nov 2023 22:36:10 -0800 (PST) X-Google-Smtp-Source: AGHT+IGGRcZ6Nc4A2pZpHfSwE3Pn3icyHxb2LjrRYGp0VLXP73QT37cX3F1NURnWlyufz0smVIA/ X-Received: by 2002:a05:6359:c8c:b0:16d:be89:88d6 with SMTP id go12-20020a0563590c8c00b0016dbe8988d6mr4351377rwb.21.1700462170210; Sun, 19 Nov 2023 22:36:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700462170; cv=none; d=google.com; s=arc-20160816; b=ja1WN2kvAuLFdsK/sj1Zx/6Rr6SbezaSBWdmPOeyoQiS0D1t/3+Z8wFUBbaevKW3QF JMMF7P2aGMXWiCzUW3EeAqNgQKKNWIQn8aRI06TEIw+JODoxKQuLkgRw+L+hahZBG9WD wU70vfoatagfd7kWiENftt8m35Nt84uoMHbElp8Pc3iFC3A9Fzxt5jaAmtyjYwy6PHWd OmDgIA0PDx+1Pa1ZLBhYuo/WlKweXGGKRuNhbi/E+/xBHIXhJbOqpUdPUKu7a0OW8Wsg vWGFGN9GQS9zdzzWp7woYqfIFYY/pagI1hmd/2NKaDY/j9QldnitbwdlT8V3Q+6keN15 GyTQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=D5WmKHJFvxp5MEqkfEjkHwA3uy953aAUbqh6hRAe3Mg=; fh=lQXg1L4fitM7ZPeZ8Era5aOyAXdZbuMQl+B6NKuaTqc=; b=KV9vnc7Pv1jcgTd+hHj5veBGPsTJGo3uVLYSOZtyZrMzBdv1Dus1iM9+pPxETDAxze 6q0m8i3srTl7gcknP7wu9imBNS4eYM6XpDS7cAELeFDta3TDwGnh+QlD/dmpsyjAAfTo uRK0sRPeX/W5rd0G0WxKsAN5Ggvkc16z3jQwR57lzGgT+SjbPnjY5QipB/Q19dLIcuLt 2gOVMlr6j74jNKQucMGmJpZ+WboPqIcJWcqL67N5vus8+rxAm33littmrtIsENQ5xzl4 B7Uo4/BU7cFUzEZk4DfEhAQSlqBr6HdOGaMGPmvPBYsY0QTvS7imYULyfg3YhRHE9r7X YbVg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=ntnX2OEm; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 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 agentk.vger.email (agentk.vger.email. [2620:137:e000::3:2]) by mx.google.com with ESMTPS id g23-20020a63fa57000000b005bdd8af5a15si7369847pgk.668.2023.11.19.22.36.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 19 Nov 2023 22:36:10 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) client-ip=2620:137:e000::3:2; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=ntnX2OEm; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 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 out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id 412D8807C851; Sun, 19 Nov 2023 22:35:30 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231934AbjKTGfY (ORCPT + 99 others); Mon, 20 Nov 2023 01:35:24 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45900 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229483AbjKTGfX (ORCPT ); Mon, 20 Nov 2023 01:35:23 -0500 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B6971D7; Sun, 19 Nov 2023 22:35:19 -0800 (PST) Received: from pps.filterd (m0279866.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 3AK55xDL024798; Mon, 20 Nov 2023 06:35:10 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h=message-id : date : mime-version : subject : to : cc : references : from : in-reply-to : content-type : content-transfer-encoding; s=qcppdkim1; bh=D5WmKHJFvxp5MEqkfEjkHwA3uy953aAUbqh6hRAe3Mg=; b=ntnX2OEmo/9BDaPJoLtMMen0fue/MTtUcmJXDBhGi+qzHM8wfP+oeWtrptbWHCRDws7h abLAlhVexFTBLmK8ApA1qO8uf+BGXEVShEzvH4+T/gjHRd5aqTE8t7yHjuSFlWuwEW7p dbuwSofgoSHgiOlniAUl5Yi6fdqpq9yV3E42SYT3JDW9bOg1gKO6cKiKVRHYQoIob+sv DucR7mb6PQsGzQFdNerTZnriqwfYar9WDA3l23mSHGoNG++do8tPLVchoXjtV/bA1wU+ /r6SEqxSqoj0mt5wxWFszBKqmmll4gzPMzD9VH7tavwu6DjgFYLzjqXEKSWT2xHHElpU GQ== Received: from nasanppmta02.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3uepjhk2hq-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 20 Nov 2023 06:35:10 +0000 Received: from nasanex01a.na.qualcomm.com (nasanex01a.na.qualcomm.com [10.52.223.231]) by NASANPPMTA02.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 3AK6Z9Z1005200 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 20 Nov 2023 06:35:09 GMT Received: from [10.216.31.13] (10.80.80.8) by nasanex01a.na.qualcomm.com (10.52.223.231) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.40; Sun, 19 Nov 2023 22:35:03 -0800 Message-ID: <4bf6e5c2-56ef-717b-88a8-db05b07a33ff@quicinc.com> Date: Mon, 20 Nov 2023 12:04:59 +0530 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.9.1 Subject: Re: [RFC PATCH 4/5] spi: qpic: Add support for qpic spi nand driver Content-Language: en-US To: Mark Brown CC: , , , , , , , , , , , , , , , References: <20231031120307.1600689-1-quic_mdalam@quicinc.com> <20231031120307.1600689-5-quic_mdalam@quicinc.com> <2b9e943a-198e-7999-b898-e7b2498a9ffa@quicinc.com> From: Md Sadre Alam In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: nasanex01b.na.qualcomm.com (10.46.141.250) To nasanex01a.na.qualcomm.com (10.52.223.231) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-ORIG-GUID: LNUnRR6UDD_bNfMDIGg3J71Zz2tsbqs0 X-Proofpoint-GUID: LNUnRR6UDD_bNfMDIGg3J71Zz2tsbqs0 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.987,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2023-11-20_04,2023-11-17_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 bulkscore=0 mlxlogscore=626 clxscore=1015 suspectscore=0 impostorscore=0 adultscore=0 lowpriorityscore=0 spamscore=0 malwarescore=0 mlxscore=0 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2311060000 definitions=main-2311200041 X-Spam-Status: No, score=-4.6 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (agentk.vger.email [0.0.0.0]); Sun, 19 Nov 2023 22:35:30 -0800 (PST) On 11/3/2023 6:17 PM, Mark Brown wrote: > On Fri, Nov 03, 2023 at 04:50:54PM +0530, Md Sadre Alam wrote: >> On 10/31/2023 7:53 PM, Mark Brown wrote: >>> On Tue, Oct 31, 2023 at 05:33:06PM +0530, Md Sadre Alam wrote: > >>>> + ret = submit_descs(snandc); >>>> + if (ret) >>>> + dev_err(snandc->dev, "failure in sbumitting spiinit descriptor\n"); >>>> + >>>> + free_descs(snandc); > >>> This seems to be doing a bit more than I would expect an init function >>> to, and it's very surprising to see the descriptors freed immediately >>> after something called a submit (which suggests that the descriptors are >>> still in flight). > >> Our controller supports only bam mode , that means for writing/reading even >> single register we have to use bam. >> submit_descs() is synchronous so I/O is complete when it returns. >> Hence freeing the descriptor after it. > > That seems like the BAM API is very confusing and error prone. Sorry for late reply Yeah, By HW itself its complex due to security reason. We are trying to write a BAM common API interface for all the driver which will use BAM.