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 X-Spam-Level: X-Spam-Status: No, score=-2.1 required=3.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE, SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id AB91AC433DB for ; Sun, 7 Feb 2021 12:55:38 +0000 (UTC) Received: from shelob.surriel.com (shelob.surriel.com [96.67.55.147]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 43FC664E0D for ; Sun, 7 Feb 2021 12:55:38 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 43FC664E0D Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kernelnewbies-bounces@kernelnewbies.org Received: from localhost ([::1] helo=shelob.surriel.com) by shelob.surriel.com with esmtp (Exim 4.94) (envelope-from ) id 1l8jbE-00047Z-2k; Sun, 07 Feb 2021 07:55:36 -0500 Received: from mail-wm1-x332.google.com ([2a00:1450:4864:20::332]) by shelob.surriel.com with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94) (envelope-from ) id 1l8jbC-00047U-44 for kernelnewbies@kernelnewbies.org; Sun, 07 Feb 2021 07:55:34 -0500 Received: by mail-wm1-x332.google.com with SMTP id o24so2897516wmh.5 for ; Sun, 07 Feb 2021 04:55:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=message-id:date:mime-version:user-agent:subject:content-language:to :references:from:cc:in-reply-to:content-transfer-encoding; bh=wK+Jyu5PIssmSySD8O184a5GtjE4/jmpSx3tfOmsq+s=; b=JcLpFTsngEvwRDd2KORbUEXmz4F7DmSUAPRBNvcNMyWL25Xf1peL1gqlnlfKSQ4MJS dUlye+9jPMMZZRLUnq2q7rpo5vbsLQpqSPC3UnQS9lOqoI/5tK7iPGjnZywjkETaWSWw Fn+UGiti3z2TCHhc5/hPUpM0y56IfJWP8LYyduUpDIpxcGghe8AoB8/eI6yiqx/a/7bR TjEBdWD/mN60ZpC1z5+eHuiWUQUyO8njD5ItHxcvXxUKyR2sJEep1Yb5dFe09Pikx8Uw Tm3Y2p9D/I8arInGwruC6dwWV+SpjUU0ySgwZ4yTGz3neG8Rl7X8GfCinFFKfPh1r9HW 81BQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:references:from:cc:in-reply-to :content-transfer-encoding; bh=wK+Jyu5PIssmSySD8O184a5GtjE4/jmpSx3tfOmsq+s=; b=WwAVR6OGpXD9snF7EIDuask9UwC9tCrtBDHDSjNoGpVpsc5S6s3SYN2a4cYsuP2JPI zZgMMjSU8Wx6MU2XF7TQeTLAcoUO+cIFyzdolFW3+xZcmUqGLxxU93Rfa+sH3yvmFZRs vuq5m2mwxAGBK2YvZdAowKYbD3buxpwcgwMcVfkmrNyy8Lu5pDXZxlF+1fdYmYiGg4fm p6Sclq6xx8EICGHkl+l1MMut+kkSnnj/MVkCR8VGbScctRyWgHl/3ligx+X/Qtm6+oxt fTHExvB5l6aYuvpA9KZzdpNXEdaVS0pvnekswb6LZsmzVRSCkTvYHL61W0ixdlBpb40J u4cg== X-Gm-Message-State: AOAM531GMA6l1it39qsyQZz0IwUvzyKhcb/AIGl9z05cds0rSF1qASjR HDkt2JZdHBLa41hpXCqf163oMR7xJQGmytnN X-Google-Smtp-Source: ABdhPJwpw+Q5Tr8ULzeI7wn3H5GZcxTFSN5INJJCd/QcSASaraAPdOV0ec7UBghfW5OjOw5REmbFUA== X-Received: by 2002:a1c:7e0c:: with SMTP id z12mr11185546wmc.85.1612702531262; Sun, 07 Feb 2021 04:55:31 -0800 (PST) Received: from [10.8.0.91] ([82.102.8.68]) by smtp.gmail.com with UTF8SMTPSA id a132sm15646397wmf.42.2021.02.07.04.55.29 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 07 Feb 2021 04:55:30 -0800 (PST) Message-ID: <63765b35-74b2-deb1-3f43-2032cc042d71@gmail.com> Date: Sun, 7 Feb 2021 16:25:26 +0330 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:86.0) Gecko/20100101 Thunderbird/86.0 Subject: Re: grab raw data from microphone and send it to the output Content-Language: en-US To: Ivan Riabtsov References: From: Pouya Abbassi In-Reply-To: Cc: kernelnewbies@kernelnewbies.org X-BeenThere: kernelnewbies@kernelnewbies.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Learn about the Linux kernel List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Errors-To: kernelnewbies-bounces@kernelnewbies.org Hi Ivan. Please consider looking at this question and the comments below it: https://stackoverflow.com/questions/16360378/kernel-module-vs-user-space-application-which-one-is-faster If you need a big speed difference, running your code in kernel-space won't make a huge difference. In either way, you'll get the same CPU cycles. The only thing that I can think of, is using FPGA to do the job. Kernel-space won't do any magic for you. FPGA development is hard and totally different, but it's all magic! - Best regards Pouya On 2/7/21 16:03, Ivan Riabtsov wrote: > Hello. There is a task to receive raw data from the microphone and, > after some processing, send it to the output (headphones or speakers) > to speed up the process, I want to do this at the kernel space, please > tell me where to start (which way to look and what to read)? My sound > device: "Family 17h (Models 10h-1fh) HD Audio Controller". > Thanks Everyone > > _______________________________________________ > Kernelnewbies mailing list > Kernelnewbies@kernelnewbies.org > https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies > _______________________________________________ Kernelnewbies mailing list Kernelnewbies@kernelnewbies.org https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies