Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp3159258pxk; Mon, 7 Sep 2020 05:06:49 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxxLdXFS9CkCHL9hALjytZ4eH91+VlHx9InOiew2NQc2tQRwWTF8lLLlNvednI3KWN/HKYI X-Received: by 2002:a05:6402:b72:: with SMTP id cb18mr20607974edb.299.1599480409618; Mon, 07 Sep 2020 05:06:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1599480409; cv=none; d=google.com; s=arc-20160816; b=kiMtAIoWCdEwq/r1uLR1Xl/19IZBV55+hhPwoMvl9TRswZIOU6NWivGsHb8w5SGArG HlES8f5bb5qn3luNAfs/tV65WDhFPg0BCqwsisGvpr6PDeK9JyOH39jFYfqQ+PiikGUc Osxd8Ye9qsiW8CVG28oBv6F7WD5zJYKKXNST/gkn9pL3ONzTyqQHDsG8a04zF2MhjSHL TvazN/+RC6sTUMWTFb1ChC5/GZf97NScmIJAsQ+PvvCgASen8LGvFifIzeZnelZvDsGT 0Ta72QWeEq4weA/gdF625r2llsVUMh0yGzJecR46pNb3iuwcvhprtc68cIvs1SpG85fn 7r7Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=bR2mzR5z4Fp1s//vb7R8PemzbT1nIPea5CxsPeQGbCo=; b=at9obS27pFiGETFYaPZTGmTkGLDnONnRY/PXkY4sIo+qvDG2LXn6we0HWwIIReYSNw 6zT/58GTKxAuDaCZR5FwJSPKYMJjWmI6oM6xkYhuwo2bjhjdQZLfzbtgnBs4tT+jzXxz gFD4bHMSBfi257jeBgv2B7BD86HTV8mTjYH7cpbJ+fOFNHw+SiZ1kKE3A7yDiHEOXPqA dzdPESyR3qo+IviPU4MHh/xbuCbgf09PnY5K+l6o6jNX7Z1wCMOBNfokg0Ka5hyn+oHI VI6t07nhfWJfnncm3Vz1X6a7Zo+kQy/r5Yc0VzFQU0kGVeWsn+37UX2mAhHiTOWR1xvX 8XNQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=sdlgVprv; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t12si9224942ejj.713.2020.09.07.05.06.26; Mon, 07 Sep 2020 05:06:49 -0700 (PDT) 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=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=sdlgVprv; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729201AbgIGME0 (ORCPT + 99 others); Mon, 7 Sep 2020 08:04:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48322 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729190AbgIGL7s (ORCPT ); Mon, 7 Sep 2020 07:59:48 -0400 Received: from mail-ed1-x543.google.com (mail-ed1-x543.google.com [IPv6:2a00:1450:4864:20::543]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C2994C061574 for ; Mon, 7 Sep 2020 04:59:47 -0700 (PDT) Received: by mail-ed1-x543.google.com with SMTP id c10so12525384edk.6 for ; Mon, 07 Sep 2020 04:59:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=bR2mzR5z4Fp1s//vb7R8PemzbT1nIPea5CxsPeQGbCo=; b=sdlgVprv5Ml6FcGFfq4SFwKLBdhqpgt1/tD2prJUf3yezMMf+zk3OqmlSCmjl90GHA 9J+0bfsuL2zGyEMQv67lgp7Uh5bekpJZkJHE6RCa3MxRx2asJEH0Rqd9mlGTMD/4z6Ur rlj+DdN2WEqADLINNVdSYBEhSR/vahUY1tKDlmtHNxKtIAaiKOIlwVeS9MfAxEMbdzNI veqHk6YVwBCiYL+JFMHTSCZgP67iVXGNuh01a9SlxoSynu7DM83hrYh4tzt5UwLCwkk9 giM2ryBZgwbxSSOdWZIXQxuIHht3JyKr6Uv/HaVrENAUpyjSEsHY1RcTVtVySWPD86y2 ro2w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=bR2mzR5z4Fp1s//vb7R8PemzbT1nIPea5CxsPeQGbCo=; b=O6x6LeFBICqtwfQk6jNduTJj+qKzTSEm+RqgHccsy/+UpNYZyKnLcvdu4N5WI+rMOU Z919d2YoXBBGkbpV6Se+oevVWPmHYmtRRySfcKiaFQPSzFCCmZSJSmvAYekOOXW5hSsP Jchc2nkRzLSSPQmhFH/lv0pmhkY6YYLWqhP6XB+CSp6gBNmPkIAkcWr5HSP59kLJBeNd 9+L4c0S95A+Mu9PY2JLGdadIFNL1U+nULLuvgrpcRIbH4SOllIgPlYUZY896fnnrZqlv pDZpjJ3bVLMuaSD70MS8v963ftZ1womAV+1kIDAM700F0Oa8c5J+ivKhrfBpPNz8NHMO 0sWQ== X-Gm-Message-State: AOAM532RFHOLsiIj0vvDQIuL6srd5P6dm9vVR9CYAiqkNSwckqbOVtuk twqwKaN2ubfV/NJl+7NE/ghVOdT0ozVGH23fXjhUU/T6vcU= X-Received: by 2002:a50:f687:: with SMTP id d7mr22155378edn.353.1599479986024; Mon, 07 Sep 2020 04:59:46 -0700 (PDT) MIME-Version: 1.0 References: <20200904154547.3836-1-brgl@bgdev.pl> <20200904154547.3836-16-brgl@bgdev.pl> <20200904164917.GC1891694@smile.fi.intel.com> <20200907115051.GY1891694@smile.fi.intel.com> In-Reply-To: <20200907115051.GY1891694@smile.fi.intel.com> From: Bartosz Golaszewski Date: Mon, 7 Sep 2020 13:59:35 +0200 Message-ID: Subject: Re: [PATCH 15/23] gpio: mockup: use dynamic device IDs To: Andy Shevchenko Cc: Bartosz Golaszewski , Linus Walleij , Jonathan Corbet , Mika Westerberg , Kent Gibson , "open list:GPIO SUBSYSTEM" , linux-doc , Linux Kernel Mailing List , ACPI Devel Maling List Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Sep 7, 2020 at 1:50 PM Andy Shevchenko wrote: > > On Mon, Sep 07, 2020 at 01:04:29PM +0200, Bartosz Golaszewski wrote: > > On Fri, Sep 4, 2020 at 6:49 PM Andy Shevchenko > > wrote: > > > On Fri, Sep 04, 2020 at 05:45:39PM +0200, Bartosz Golaszewski wrote: > > > > From: Bartosz Golaszewski > > > > > > > > We're currently creating chips at module init time only so using a > > > > static index for dummy devices is fine. We want to support dynamically > > > > created chips however so we need to switch to dynamic device IDs. > > > > > > It misses ida_destroy(). > > > > No, we always call ida_free() for separate IDs when removing devices > > and we remove all devices at module exit so no need to call > > ida_destroy(). > > Perhaps couple of words about this in the commit message? > But ida_destroy() and ida_free() are already well documented. It's clear that we remove all devices at exit and that every device removes its ID, there's really no point in mentioning it again. Bart