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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 07213C25B08 for ; Wed, 17 Aug 2022 13:16:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239893AbiHQNQL (ORCPT ); Wed, 17 Aug 2022 09:16:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45978 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239961AbiHQNPj (ORCPT ); Wed, 17 Aug 2022 09:15:39 -0400 Received: from smtp-out1.suse.de (smtp-out1.suse.de [IPv6:2001:67c:2178:6::1c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8192985A88 for ; Wed, 17 Aug 2022 06:15:22 -0700 (PDT) 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-out1.suse.de (Postfix) with ESMTPS id 7FB5937A47; Wed, 17 Aug 2022 13:15:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1660742120; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=gzWMUo926OQBOYmYnw3ADnCbBaPbZEizFN9qC+x8VIA=; b=Ryr6LXT+25LYEzTLgF9myB+wSGVlrjiIeYZv4us3Ez0zIZQd56e2YEBjcTNfp14U+1Fe3w GYt16OAt6v9xib31CcGK5rH3FsEECwIUQao5qxfmEuIGx5MFj6OuZcSB4iJTgrTGoUqQdU WMt7JJX2tTA1XOLJBlpN+V05VRQjKUM= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1660742120; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=gzWMUo926OQBOYmYnw3ADnCbBaPbZEizFN9qC+x8VIA=; b=/pem1fBk4pLJlNOs7XURWIK0sTSuOZ3UrwuLSaWrVrIrOg0VYlgIqSYfnI+bSas34DA5Xd M/y5XJfNVPEa1HDA== 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 575B513428; Wed, 17 Aug 2022 13:15:20 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id 6AKPFOjp/GItVAAAMHmgww (envelope-from ); Wed, 17 Aug 2022 13:15:20 +0000 Date: Wed, 17 Aug 2022 15:15:19 +0200 Message-ID: <87h72bau54.wl-tiwai@suse.de> From: Takashi Iwai To: Amadeusz =?ISO-8859-2?Q?S=B3awi=F1ski?= Cc: Takashi Iwai , alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org, Cezary Rojewski Subject: Re: [RESEND][PATCH] ALSA: info: Fix llseek return value when using callback In-Reply-To: <20220817124924.3974577-1-amadeuszx.slawinski@linux.intel.com> References: <20220817124924.3974577-1-amadeuszx.slawinski@linux.intel.com> 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=ISO-8859-2 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 17 Aug 2022 14:49:24 +0200, Amadeusz Sławiński wrote: > > When using callback there was a flow of > > ret = -EINVAL > if (callback) { > offset = callback(); > goto out; > } > ... > offset = some other value in case of no callback; > ret = offset; > out: > return ret; > > which causes the snd_info_entry_llseek() to return -EINVAL when there is > callback handler. Fix this by setting "ret" directly to callback return > value before jumping to "out". > > 73029e0ff18d ("ALSA: info - Implement common llseek for binary mode") Fixes tag seems missing. I corrected locally. > Signed-off-by: Amadeusz Sławiński Applied now (with Cc to stable). thanks, Takashi