Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp4881354pxu; Tue, 22 Dec 2020 03:14:09 -0800 (PST) X-Google-Smtp-Source: ABdhPJwqmCq3YXX4X8G5NeKujl7hZE0u+D7u/VsL2KnnN54EqPQl1PW7sdddPyBng6yjkTpAYVNp X-Received: by 2002:a17:906:d152:: with SMTP id br18mr15728337ejb.297.1608635648859; Tue, 22 Dec 2020 03:14:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1608635648; cv=none; d=google.com; s=arc-20160816; b=G2CqeGlExd5+qhGTZG3iWA5w90f06ysuapTTPQpsaMOUlaitAJ6yJbOV697ehyztZi K5NSAieTdXcMRXhQ8Ja/kpWj6oagqtiFYbXy9IuozYmhBVyEH+aX2EjRqKG4PBj32JM5 MIlCnfafGOr/0uWz84B1dP9yJaj7jC9KKix9zEn2mrWa1krd9e5lrqkVlQY7B8fzzt8I xj38kcrJWgjDRYoivynLDUGAP+rt9J/gA5Kd9+bhylU7Qdzm9oXgUbINgGlZd5qK8sUa PY4AoiTTQ6L3KNTQhMwVzl6a48STXIrbA+LPlRRCg/hauCfrferBd25MPBHZew98h8a1 Ji9g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=WRxkLGHSZ0chGApxKb5szbkf2jHWqtVgq1pH5nCsTe4=; b=Y6/Cn2Rl29z+rnhnVSpbDgoaVuBkfAGalUaMRq5zlwx3gyp+JUm1ERRvyQFOuVijJp TsIjScKOf4mn8hJG8xvlfcpjdS+oca26SDGXP/0Th1XAUrSE1FK2PNJJyFDrDzpojwZb Bt9xdR7Y/Ts5nZ+bfawXm0wg9R70BzJLbkSvBM7emKzDQjDyVMZ2pecGptjuMLIjFozV f24g3tGteSg+GZLGnY7VXF6/PCPJqGAJ5mWdcVY4hzzSOI+GAPETjWqWgnzcFYIgLIak iwtj9YCkR/LBcbkEiulDnEj/ov8XFnTcZfScL84pGMru+Xv/SzLUZF4kk7YAMAlduX4e mj1A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Od9CKyEv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c4si8386556ejk.182.2020.12.22.03.13.45; Tue, 22 Dec 2020 03:14:08 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Od9CKyEv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726614AbgLVLLv (ORCPT + 99 others); Tue, 22 Dec 2020 06:11:51 -0500 Received: from mail.kernel.org ([198.145.29.99]:51966 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726095AbgLVLLv (ORCPT ); Tue, 22 Dec 2020 06:11:51 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id 7393722516; Tue, 22 Dec 2020 11:11:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1608635470; bh=Q1euM+YOvuQwr69t7zFVYW1zAzkMWO7kDxvDMc9dnsg=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Od9CKyEvTeGsf0XvRzL/O85XlE9fnPXq/6T2OJSSuTZcWBkf0YqDNfsjtFyMkEn5r vMa+RPKkCGIbeXH3KA3oWCG0tVzQ5jOEQDOIkhwdER8GSiFm3em6Fx7ntKhZZ+OebE f4713+QEDVSyToHkKAuwvH+Ce0y/29ZvAqfgKDDM= Date: Tue, 22 Dec 2020 12:12:24 +0100 From: Greg KH To: Alexandru Ardelean Cc: linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org, jic23@kernel.org, lars@metafoo.de, akpm@linux-foundation.org, andy.shevchenko@gmail.com Subject: Re: [PATCH v5 1/2] lib/string.c: add __sysfs_match_string_with_gaps() helper Message-ID: References: <20201222095210.61897-1-alexandru.ardelean@analog.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20201222095210.61897-1-alexandru.ardelean@analog.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Dec 22, 2020 at 11:52:09AM +0200, Alexandru Ardelean wrote: > The original docstring of the __sysfs_match_string() and match_string() > helper, implied that -1 could be used to search through NULL terminated > arrays, and positive 'n' can be used to go through arrays that may have > NULL elements in the middle of the array. > > This isn't true. Regardless of the value of 'n', the first NULL element in > the array. I can not parse this last sentence, is it missing something? thanks, greg k-h