From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id BC3F2C77B7F for ; Fri, 19 May 2023 12:24:05 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 51D9D201; Fri, 19 May 2023 14:23:13 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 51D9D201 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1684499043; bh=BoOQaMg+i9QhInKjFsym4V6rREMwxSEcBjzJOOgPecM=; h=Date:From:To:Cc:Subject:In-Reply-To:References:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=q309SuPv/Yzz44sLCUXLDQEEHVMTBSfN2SQloFa5Blc8GBnwlCi3VXHOH3qO6kduD 3Y2waI5v56hSfON6etYX1hAj+k/X9jkHacY+ilYnErZ4BbB6VKDamSO4htl3wzs/4X 2KXuAxh1k3jRXo4JtbTCpJW9xjc9hoCzUOBYRitY= Received: by alsa1.perex.cz (Postfix, from userid 50401) id B9BECF802E8; Fri, 19 May 2023 14:22:45 +0200 (CEST) Received: from mailman-core.alsa-project.org (mailman-core.alsa-project.org [10.254.200.10]) by alsa1.perex.cz (Postfix) with ESMTP id 5D75BF80272; Fri, 19 May 2023 14:22:45 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id A4120F80272; Fri, 19 May 2023 14:22:41 +0200 (CEST) Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id E5854F8016D for ; Fri, 19 May 2023 14:22:38 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz E5854F8016D Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key, unprotected) header.d=suse.de header.i=@suse.de header.a=rsa-sha256 header.s=susede2_rsa header.b=ozSjPyUT; dkim=pass header.d=suse.de header.i=@suse.de header.a=ed25519-sha256 header.s=susede2_ed25519 header.b=mu1/dYY6 Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 73B721F8B0; Fri, 19 May 2023 12:22:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1684498958; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=UnSDDnNAIAIkoAwDBj8SXBWEBNbyBr2nim5cfFIELO0=; b=ozSjPyUTZ66QSFN0cSa7LeHPTedgAYVHBGCVtIisxHOI/+dCRtkdrsEu/F1ssD3d/d2z0y lHa1gZEKI+s2BAuDcWDvGGnn9TR8/O8kHVMb+sQM1/lkTiF+mpVRRU9U8v9S/EeayHlK/N j9BmueLda8HReM5NB+gfw2r1aUeA+0k= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1684498958; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=UnSDDnNAIAIkoAwDBj8SXBWEBNbyBr2nim5cfFIELO0=; b=mu1/dYY6r9cRtZZ+SxhExhaP0sLP/eUWBs3ezzeELIP+J6RRcD1WRVGvR/6L5Kv4Zo/iKO jsMHXZjVBqJMRIDA== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 23C6413A12; Fri, 19 May 2023 12:22:38 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id +mh0AQ5qZ2QJawAAMHmgww (envelope-from ); Fri, 19 May 2023 12:22:38 +0000 Date: Fri, 19 May 2023 14:22:37 +0200 Message-ID: <875y8o1pf6.wl-tiwai@suse.de> From: Takashi Iwai To: Oswald Buddenhagen Cc: alsa-devel@alsa-project.org, Jaroslav Kysela Subject: Re: [PATCH 5/7] ALSA: emu10k1: centralize freeing PCM voices In-Reply-To: References: <20230518140947.3725394-1-oswald.buddenhagen@gmx.de> <20230518140947.3725394-6-oswald.buddenhagen@gmx.de> <87ttw9hesg.wl-tiwai@suse.de> <87a5y01t1b.wl-tiwai@suse.de> User-Agent: Wanderlust/2.15.9 (Almost Unreal) Emacs/27.2 Mule/6.0 MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII Message-ID-Hash: FDTVGL52CNQ2MPPN3IFGKPYGIXOF5D2D X-Message-ID-Hash: FDTVGL52CNQ2MPPN3IFGKPYGIXOF5D2D X-MailFrom: tiwai@suse.de X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-alsa-devel.alsa-project.org-0; header-match-alsa-devel.alsa-project.org-1; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.8 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: On Fri, 19 May 2023 13:53:01 +0200, Oswald Buddenhagen wrote: > > On Fri, May 19, 2023 at 01:04:32PM +0200, Takashi Iwai wrote: > > On Fri, 19 May 2023 12:43:24 +0200, > > Oswald Buddenhagen wrote: > >> > >> On Thu, May 18, 2023 at 04:53:19PM +0200, Takashi Iwai wrote: > >> > On Thu, 18 May 2023 16:09:45 +0200, > >> > Oswald Buddenhagen wrote: > >> >> -static int snd_emu10k1_pcm_channel_alloc(struct snd_emu10k1_pcm * epcm, int voices) > >> >> +static void snd_emu10k1_pcm_free_voices(struct snd_emu10k1_pcm *epcm) > >> >> { > >> >> - int err, i; > >> >> - > >> >> - for (i = 0; i < ARRAY_SIZE(epcm->voices); i++) { > >> >> + for (unsigned i = 0; i < ARRAY_SIZE(epcm->voices); i++) { > >> > > > I'm not super-strict about it, but > > > as checkpatch complaints, > > > it doesn't, so from that side it's settled. it's really just about the > alsa-local policy. > > what it actually *does* complain about is the use of bare > "unsigned". Ah that's OK, then. > i don't like the excessively verbose "unsigned int", so > i'll switch my uses over to "uint", which already has some use in > alsa. ok? I don't mind much about the use of unsigned without int. Or it could be a simple int there, as that's nothing but a counter that is used locally that can't over 31bit. But the patch description could be still improved. thanks, Takashi