Received: by 2002:a05:6358:111d:b0:dc:6189:e246 with SMTP id f29csp1747408rwi; Mon, 31 Oct 2022 22:19:45 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4JemVAHfwVKeEcKHPc2qcZKV9OPZLYZTvzS95zmFWlXPY1bY/x/A4L8sRKZvZDZUEyG9m4 X-Received: by 2002:a17:907:8a09:b0:7ad:adff:ddf6 with SMTP id sc9-20020a1709078a0900b007adadffddf6mr16798128ejc.320.1667279984867; Mon, 31 Oct 2022 22:19:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1667279984; cv=none; d=google.com; s=arc-20160816; b=eMXCQ7VIskRncS48xqaRPYBtzZoP5xx+QFuKLUChCiivJ+5TU7sE3s3IZsoJ9WhuLJ qJSiWVaQYV19W0DwnnYtWrVRX8T373FnSwDYLSG2DSRYOdd4hiCp1UG9lKFd+nlvmH3C pfvsctfJo5k33MinKqhIG+ABzVPVdlklYANvhMZ07jZ7Z1vAe/XxYzvjOxUGv5fZiG51 J1n1CXc16s5wZXluE1aVzLun2K2Sz1hy9ZF6qnOLDbDrHCNsHRhHksgsVftCLtlbOI3T /9D0qmowOm9uJ7m7CTRD+slDypsP/OeJXeVObGeDUSpBOxJsLWXG0dxKuM5IQr68auwS CMIw== 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=QZki3yNhJNdqEk75OblUwTCwWovi47EOx4A6q7xKq8s=; b=u9ahMaSFlDfy4RhWbA30b5+xwGCMuRGw5kt8z0WTt+FsbYlGUwbnyLGEUMdyfv+ibv I3LODNyv5OypI4QhoJT7goOagyB+P16PI3Q6Qi7LvIWuFV4JDlMR6jlDLp8R93LUWeMh 4oiJhjg2aDHcZZ6/eH2Q6fiZWFw0/Lcp3KYcEqrbu2gu9tVyU8lPDKXjrWYEnubxMa7S 3yZNIcnWX01adBJG91q7VBNyqQ3hEQHUdLG5N66ti//rgV3l4YHL0sYdpBUX/Vz/gMVp 3s7PDULNxdmq5Wz4h1DpXS3926X6ZB1cDwhLXnrKX9u7RiJ8Ml4qMzksn5nrdchIa6bZ dFHQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=AdieALIA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h11-20020a056402280b00b00461ed1fe6ffsi13938909ede.85.2022.10.31.22.19.17; Mon, 31 Oct 2022 22:19:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=AdieALIA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229824AbiKAFLV (ORCPT + 99 others); Tue, 1 Nov 2022 01:11:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40396 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229452AbiKAFLS (ORCPT ); Tue, 1 Nov 2022 01:11:18 -0400 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 370722BF0; Mon, 31 Oct 2022 22:11:18 -0700 (PDT) Received: from pps.filterd (m0279863.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 2A14xv8P010492; Tue, 1 Nov 2022 05:11:06 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=QZki3yNhJNdqEk75OblUwTCwWovi47EOx4A6q7xKq8s=; b=AdieALIAvxOWRma6Dnb54RmkR+YI72XetoIc29y9FUwPXxPbqYqWAy4oHla7wkejPnDV Nr+QDZDhksoNtlT0YxKurDtefngt7VTbqisjqCGhkm84r8pRQCtdPoA43uLPM99JuJfA RS5K5HepGEAguuQs8wc7BlQJknzXWxCsNJZPlGD4qbGGd793R3eneklOk1WuCXz2ROi+ CMU/+Lez8x8Nuh0gMJR4iWPql72cMix1MziW6CCYSkG+HECYUo8YE2cG/X19VPlvUEH7 pEUY7rUrFvbQ37cP46miAGZcmsfxRc/4OUghdG/W2uqKT8Yvt27PCvDWOhq0TcpO5iPk Yw== Received: from nalasppmta05.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3kjvseg109-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 01 Nov 2022 05:11:06 +0000 Received: from nalasex01c.na.qualcomm.com (nalasex01c.na.qualcomm.com [10.47.97.35]) by NALASPPMTA05.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 2A15B5Gj011380 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 1 Nov 2022 05:11:05 GMT Received: from [10.239.155.106] (10.80.80.8) by nalasex01c.na.qualcomm.com (10.47.97.35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.29; Mon, 31 Oct 2022 22:11:02 -0700 Message-ID: Date: Tue, 1 Nov 2022 13:11:00 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.5.1 Subject: Re: [PATCH v4 1/2] leds: flash: add driver to support flash LED module in QCOM PMICs Content-Language: en-US To: Luca Weiss , , , , "Pavel Machek" , Gene Chen , Jacek Anaszewski , CC: , , Dylan Van Assche References: <20221025073802.2662564-1-quic_fenglinw@quicinc.com> <20221025073802.2662564-2-quic_fenglinw@quicinc.com> From: Fenglin Wu 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 nalasex01c.na.qualcomm.com (10.47.97.35) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-ORIG-GUID: I9A98y4Q0AdmRuewTkNRNRJ6UCVcZxf9 X-Proofpoint-GUID: I9A98y4Q0AdmRuewTkNRNRJ6UCVcZxf9 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.895,Hydra:6.0.545,FMLib:17.11.122.1 definitions=2022-11-01_01,2022-10-31_01,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 spamscore=0 suspectscore=0 mlxlogscore=999 phishscore=0 priorityscore=1501 adultscore=0 clxscore=1015 impostorscore=0 malwarescore=0 mlxscore=0 lowpriorityscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2210170000 definitions=main-2211010038 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=ham 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 On 2022/10/31 21:56, Luca Weiss wrote: > Hi Fenglin, > > On Tue Oct 25, 2022 at 9:38 AM CEST, Fenglin Wu wrote: >> Add initial driver to support flash LED module found in Qualcomm >> Technologies, Inc. PMICs. The flash module can have 3 or 4 channels >> and each channel can be controlled indepedently and support full scale >> current up to 1.5 A. It also supports connecting two channels together >> to supply one LED component with full scale current up to 2 A. In that >> case, the current will be split on each channel symmetrically and the >> channels will be enabled and disabled at the same time. >> >> Signed-off-by: Fenglin Wu >> Tested-by: Luca Weiss # sm7225-fairphone-fp4 + pm6150l >> --- >> drivers/leds/flash/Kconfig | 15 + >> drivers/leds/flash/Makefile | 1 + >> drivers/leds/flash/leds-qcom-flash.c | 700 +++++++++++++++++++++++++++ >> 3 files changed, 716 insertions(+) >> create mode 100644 drivers/leds/flash/leds-qcom-flash.c >> > > > >> +static const struct of_device_id qcom_flash_led_match_table[] = { >> + { .compatible = "qcom,spmi-flash-led" }, >> + { } >> +}; > > Dylan has noticed that auto-loading the module based on dt match doesn't > work currently. It seems that this line is missing here to enable that: > > MODULE_DEVICE_TABLE(of, qcom_flash_led_match_table); > > Please add it for v5! > > Regards > Luca > Will add it for v5, thank you! >> + >> +static struct platform_driver qcom_flash_led_driver = { >> + .driver = { >> + .name = "leds-qcom-flash", >> + .of_match_table = qcom_flash_led_match_table, >> + }, >> + .probe = qcom_flash_led_probe, >> + .remove = qcom_flash_led_remove, >> +}; >> + >> +module_platform_driver(qcom_flash_led_driver); >> + >> +MODULE_DESCRIPTION("QCOM Flash LED driver"); >> +MODULE_LICENSE("GPL"); >> -- >> 2.25.1 >