Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751934AbbETDs0 (ORCPT ); Tue, 19 May 2015 23:48:26 -0400 Received: from mailout1.samsung.com ([203.254.224.24]:57154 "EHLO mailout1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751132AbbETDsY (ORCPT ); Tue, 19 May 2015 23:48:24 -0400 X-AuditID: cbfee68d-f79106d00000728c-0b-555c040564e0 Message-id: <555C0405.9030009@samsung.com> Date: Wed, 20 May 2015 12:48:21 +0900 From: Chanwoo Choi User-Agent: Mozilla/5.0 (X11; Linux i686; rv:17.0) Gecko/20130106 Thunderbird/17.0.2 MIME-version: 1.0 To: Krzysztof Kozlowski Cc: Chanwoo Choi , linux-kernel , "myungjoo.ham@samsung.com" , Charles Keepax , gg@slimlogic.co.uk, Kishon Vijay Abraham I , jaewon02.kim@samsung.com, Roger Quadros , "Pallala, Ramakrishna" , george.cherian@ti.com, Felipe Balbi , Aaro Koskinen Subject: Re: [PATCH 1/2] extcon: Use the unique id for external connector instead of string References: <1431700278-30465-1-git-send-email-cw00.choi@samsung.com> <1431700278-30465-2-git-send-email-cw00.choi@samsung.com> <555B2C56.8080105@samsung.com> <555BFE78.2000503@samsung.com> In-reply-to: <555BFE78.2000503@samsung.com> Content-type: text/plain; charset=UTF-8 Content-transfer-encoding: 7bit X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFjrLIsWRmVeSWpSXmKPExsWyRsSkUJeVJSbUoO2elcWaFw4WB+/XW/yb coPd4tlRbYtTB5ezWvRvcbHY0XCE1eL1C0OLC0972Cwu75rDZnG7cQWbxcI3N5kseh5pOfB6 7Jx1l93j8NeFLB6L97xk8ng58TebR9+WVYweU6f8ZfQ4fmM7k8fnTXIBHFFcNimpOZllqUX6 dglcGRPa17MXdPNV/L94nrmB8T9XFyMnh4SAicTs1o9sELaYxIV764FsLg4hgaWMElcXnmSF KTrbcY0ZIrGIUeLYo3uMEM4DRonXCzeygFTxCmh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niw49esEHCArES3dPm QG07zyRx7+YPsEmcAtoSK3duALuPWUBdYtK8RVC2vMTmNW+ZJzAKzEKyZBaSsllIyhYwMq9i FE0tSC4oTkrPNdQrTswtLs1L10vOz93ECE4Uz6R2MK5ssDjEKMDBqMTDW3AgOlSINbGsuDL3 EKMEB7OSCO+smUAh3pTEyqrUovz4otKc1OJDjKbAMJjILCWanA9MYnkl8YbGJmZGlkbmhhZG xuZK4rwn831ChQTSE0tSs1NTC1KLYPqYODilGhgF201DpQS9z+zq8TbecZMt6632mdsMM35v tI/Nz2WSOXvdKEy6avb1j3OL+qfEilcLTuFZZrrTx24vi6mk8nax+u8Tn8TIbOD9u4Y9P/FE n2dQSHrL2tvNU+dPLHkuFz3tSq3xT96Z96L2s2kJ6mg8m94nuu7bhT9tyeqK2zeaZ0a/Dvrj 7qzEUpyRaKjFXFScCAAvX93sKgMAAA== DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2004 Lines: 49 On 05/20/2015 12:24 PM, Krzysztof Kozlowski wrote: > On 19.05.2015 21:28, Chanwoo Choi wrote: >> Hi Krzysztof, >> >>>>> + >>>>> + if (i == edev->max_supported) >>>>> + return -EINVAL; >>>>> >>>>> if (index < 0 || (edev->max_supported && edev->max_supported <= index)) >>>>> return -EINVAL; >>>>> @@ -605,7 +644,7 @@ static void dummy_sysfs_dev_release(struct device *dev) >>>>> * >>>>> * Return the pointer of extcon device if success or ERR_PTR(err) if fail >>>>> */ >>>>> -struct extcon_dev *extcon_dev_allocate(const char **supported_cable) >>>>> +struct extcon_dev *extcon_dev_allocate(const enum extcon *supported_cable) >>>> >>>> I think you also have to update the documentation. At least for >>>> {devm}_extcon_dev_allocate but maybe in other places too. Previously >>>> the documentation states that supported_cable is an array of strings. >>>> Additionally AFAIU now it must end with EXTCON_NONE. This >>>> sentinel-like info must be clearly documented. >> >> As you commented, extcon must need to document the update and usage method of extcon core. >> The mainline kernel includes only the 'Documentation/extcon/porting-android-switch-class'. >> Namely, the mainline kernel have not included the document showing the usage method of extcon core. > > I mean documentation for the function. The kerneldoc above functions says: > > * @supported_cable: Array of supported cable names ending with NULL. > * If supported_cable is NULL, cable name related APIs > * are disabled. Ah. I misunderstand on previous mail. I'll fix upper description. > > AFAIU now the supported cable must end with EXTCON_NONE. Is it correct? Right. Thanks, Chanwoo Choi -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/