[bug#77943,1/2] services: shepherd: Provide the right #:kernel-log-file on the Hurd.
Message ID | OSK14Qd--F-9@tutamail.com |
---|---|
State | New |
Headers |
Return-Path: <guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org> X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 645AE27BC4B; Tue, 10 Jun 2025 10:52:23 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-6.4 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED, RCVD_IN_VALIDITY_CERTIFIED,RCVD_IN_VALIDITY_RPBL,RCVD_IN_VALIDITY_SAFE, SPF_HELO_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 861C627BC49 for <patchwork@mira.cbaines.net>; Tue, 10 Jun 2025 10:52:22 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from <guix-patches-bounces@gnu.org>) id 1uOveH-0002Yd-Kj; Tue, 10 Jun 2025 05:52:05 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <Debian-debbugs@debbugs.gnu.org>) id 1uOveG-0002YO-I0 for guix-patches@gnu.org; Tue, 10 Jun 2025 05:52:04 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <Debian-debbugs@debbugs.gnu.org>) id 1uOveG-0002r2-94 for guix-patches@gnu.org; Tue, 10 Jun 2025 05:52:04 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:References:In-Reply-To:From:Date:To:Subject; bh=t+F5Gh0Itpit7mozM3Y5Bh0csM5kOHMxARoOg+djmGk=; b=TNiP3MnFt0TNqnrU2NIz8FMYu8ceQNc2E0vv3oRGFvtDlY8MPZxJ7IiMou02iXSfaPE1x0X0UH4Rmr+YaQEXlhxYK1Y+9k6T49OFfjfsECFIoR3CH2kLBBM4t50iYeS31FWehISrfclBVDmTAgNzXa90wGPsdjPeoFnFDJNl4Gj4IYvpwwxO2/QmWXXuJy41iI5dAKth0a2BTEeC0fFlRRsp8S2W+mt3y7tGaNKVIxVE1dWe8naXfqGjd7liw48XK/44wyvamBxm+HmWbD0kPxDb117HW73X0+J17xvsMjU0gb6ZSNbAGqfbp8u+2xLMMEKxnwmbNKNYD48jRyz3vg==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from <Debian-debbugs@debbugs.gnu.org>) id 1uOveG-0003Yt-0c for guix-patches@gnu.org; Tue, 10 Jun 2025 05:52:04 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#77943] [PATCH 1/2] services: shepherd: Provide the right #:kernel-log-file on the Hurd. Resent-From: yelninei@tutamail.com Original-Sender: "Debbugs-submit" <debbugs-submit-bounces@debbugs.gnu.org> Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 10 Jun 2025 09:52:03 +0000 Resent-Message-ID: <handler.77943.B77943.174954906913241@debbugs.gnu.org> Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 77943 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Ludovic =?utf-8?q?Court=C3=A8s?= <ludo@gnu.org> Cc: 77943 <77943@debbugs.gnu.org> Received: via spool by 77943-submit@debbugs.gnu.org id=B77943.174954906913241 (code B ref 77943); Tue, 10 Jun 2025 09:52:03 +0000 Received: (at 77943) by debbugs.gnu.org; 10 Jun 2025 09:51:09 +0000 Received: from localhost ([127.0.0.1]:34548 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces@debbugs.gnu.org>) id 1uOvdM-0003RL-Ax for submit@debbugs.gnu.org; Tue, 10 Jun 2025 05:51:09 -0400 Received: from mail.w13.tutanota.de ([185.205.69.213]:34432) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <yelninei@tutamail.com>) id 1uOvdI-0003Pi-4j for 77943@debbugs.gnu.org; Tue, 10 Jun 2025 05:51:05 -0400 Received: from tutadb.w10.tutanota.de (w10.api.tuta.com [IPv6:fd:ac::d:10]) by mail.w13.tutanota.de (Postfix) with ESMTP id 8E3C6940B9F2 for <77943@debbugs.gnu.org>; Tue, 10 Jun 2025 11:50:27 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1749549027; s=s1; d=tutamail.com; h=From:From:To:To:Subject:Subject:Content-Description:Content-ID:Content-Type:Content-Type:Content-Transfer-Encoding:Content-Transfer-Encoding:Cc:Cc:Date:Date:In-Reply-To:In-Reply-To:MIME-Version:MIME-Version:Message-ID:Message-ID:Reply-To:References:References:Sender; bh=t+F5Gh0Itpit7mozM3Y5Bh0csM5kOHMxARoOg+djmGk=; b=SFdbj5YZw49AshILKWBF05VwBtCnlgktAmRrNm+IYLzGltmKCOZg8bGwvu2EW0JK Ee4+cFkNnWlTJS+Ks02+ozCSHkA9bDFMwZvQ8cUwlQD0g5s0N907V+uT0+PxVkxu/LZ xjHHIjA5vYpP/IcXCvDkeRUQXwNv3ULg8ye4PJV0ePDKq/QF1JBXzaZ63HIHyoPnv+o v4JLXHqIt3PvY0QfuClLU3Ht/ys9jK0i5TnTHG8hl+nmhp8bfULiqg+4YGtxx8HUQqH fJBGHK9TFZGWXWYY9/om/smvZgo6TdlUzd7ecPaPbUvwED9wwFC4gbOENCpUYM7SujQ wNQLz55/8Q== Date: Tue, 10 Jun 2025 11:50:27 +0200 (CEST) Message-ID: <OSK14Qd--F-9@tutamail.com> In-Reply-To: <87cybmp4q6.fsf@gnu.org> References: <cover.1745163830.git.ludo@gnu.org> <ee2ded1a592d8f91595c26c08f6f9f047d74b4f2.1745163830.git.ludo@gnu.org> <OPRqyKU--F-9@tutamail.com> <87cybmp4q6.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: <guix-patches.gnu.org> List-Unsubscribe: <https://lists.gnu.org/mailman/options/guix-patches>, <mailto:guix-patches-request@gnu.org?subject=unsubscribe> List-Archive: <https://lists.gnu.org/archive/html/guix-patches> List-Post: <mailto:guix-patches@gnu.org> List-Help: <mailto:guix-patches-request@gnu.org?subject=help> List-Subscribe: <https://lists.gnu.org/mailman/listinfo/guix-patches>, <mailto:guix-patches-request@gnu.org?subject=subscribe> Reply-to: yelninei@tutamail.com X-ACL-Warn: , yelninei--- via Guix-patches <guix-patches@gnu.org> From: yelninei--- via Guix-patches via <guix-patches@gnu.org> Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches |
Series |
[bug#77943,1/2] services: shepherd: Provide the right #:kernel-log-file on the Hurd.
|
|
Commit Message
yelninei--- via Guix-patches via
June 10, 2025, 9:50 a.m. UTC
Hello Ludo, Jun 2, 2025, 16:09 by ludo@gnu.org: > Hi, > > Right, I started looking into it back then but then didn’t take the time > to track it down. > I tried your patch that you sent to bug-hurd but I still end up with D_WOULD_BLOCK at the end. Was it working for you? As pointed out by Samuel on bug-hurd the initial "if (err) return err" looks weird. I tried removing it and at the end of /dev/klog it died with SIGLOST. I then tried this patch similar to yours to intercept D_WOULD_BLOCK at the beginning instead: and my example now fails with EAGAIN. I am not sure yet what is setting this, the joy of global variables. However something still seems wrong when I added back the shepherd syslog. It still crashes/hangs when it reaches the initial end of /dev/klog and does not process messages further: there is an extra message and e.g. sshd messages to the syslog dont get processed. root@childhurd ~# ./main irq handler [11]: new delivery port f5e44038 entry f4f39840 errno: Resource temporarily unavailable To be continued. Note: I had to add the patch to the default hurd and just patching the hurd package that is used in operating-system-hurd was not enough. Dont know what is up with that. > Thanks, > Ludo’. >
Comments
Hi Yelninei, yelninei@tutamail.com writes: > I tried your patch that you sent to bug-hurd but I still end up with D_WOULD_BLOCK at the end. Was it working for you? No no, it wasn’t, but I haven’t taken the time to dig further. > As pointed out by Samuel on bug-hurd the initial "if (err) return err" looks weird. I tried removing it and at the end of /dev/klog it died with SIGLOST. [...] > and my example now fails with EAGAIN. I’m not sure what example but EAGAIN is fine, it’s what we want. Thanks for investigating! Ludo’.
diff --git a/trans/streamio.c b/trans/streamio.c index e42ff908..ee3cf9b4 100644 --- a/trans/streamio.c +++ b/trans/streamio.c @@ -1005,7 +1005,12 @@ dev_read (size_t amount, void **buf, size_t *len, int nowait) size_t max, avail; if (err) - return err; + { + if (err == D_WOULD_BLOCK) + return EWOULDBLOCK; + else + return err; + } while (!buffer_readable (input_buffer)) {