Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.kernel > #81795

Bug#1063338: [regression 6.1.76] dlm: cannot start dlm midcomms -97 after backport of e9cdebbe23f1 ("dlm: use kernel_connect() and kernel_bind()")

Path csiph.com!fu-berlin.de!bofh.it!news.nic.it!robomod
From Jordan Rife <jrife@google.com>
Newsgroups linux.debian.bugs.dist, linux.kernel, linux.debian.kernel
Subject Bug#1063338: [regression 6.1.76] dlm: cannot start dlm midcomms -97 after backport of e9cdebbe23f1 ("dlm: use kernel_connect() and kernel_bind()")
Date Thu, 08 Feb 2024 18:50:01 +0100
Message-ID <I5gH7-8MIT-5@gated-at.bofh.it> (permalink)
References <I4sr0-8hwn-5@gated-at.bofh.it> <I4NF8-8v8V-11@gated-at.bofh.it> <I4UZX-8zzf-7@gated-at.bofh.it> <I5bHr-8JRe-1@gated-at.bofh.it> <I4sr0-8hwn-5@gated-at.bofh.it> <I5bHr-8JRe-1@gated-at.bofh.it>
X-Original-To Valentin Kleibel <valentin@vrvis.at>
X-Mailbox-Line From debian-bugs-dist-request@lists.debian.org Thu Feb 8 17:45:12 2024
Old-Return-Path <debbugs@buxtehude.debian.org>
X-Spam-Flag NO
X-Spam-Score 1.64
Reply-To Jordan Rife <jrife@google.com>, 1063338@bugs.debian.org
Resent-To debian-bugs-dist@lists.debian.org
Resent-Cc Debian Kernel Team <debian-kernel@lists.debian.org>
X-Debian-Pr-Message followup 1063338
X-Debian-Pr-Package src:linux
X-Debian-Pr-Keywords patch upstream
X-Debian-Pr-Source linux
X-Forwarded-Encrypted i=1; AJvYcCWZ0m2p9jLU/1zH+ZJW4/6J3hQ9oOSJDWjFzrvsIklH+4etpA9JsrSqTlFmnr0vx2EKQ2ptNdi4W50qocDpkU1wSwvd948S0A==
X-Gm-Message-State AOJu0YwTY6sSEksQfw7LoIR0VOlgOBPs+4nd/BURSBwOAVv56+BM1R4K nKbV4LDmzBK3dLHR+CiGpIs0Lb3P3jAz3xczrseNXES5zxboohYKhe7bCtITUdh6Tb+Uv24XO7g 5i2Oohy9TKtk1RvUCoD/8ZxcUQWhpPbL2vqSL
X-Google-SMTP-Source AGHT+IHisO4YeJ4HMjJTJ7Pa6g2UoWbHmyDF6/F8nMdBmOGtjRmAF7AXJRfz3Lb4ftoWcIr8EGxQVdi4TlQ13SQyHQk=
X-Received by 2002:a05:6214:258b:b0:681:78cf:3920 with SMTP id fq11-20020a056214258b00b0068178cf3920mr12087645qvb.25.1707414157664; Thu, 08 Feb 2024 09:42:37 -0800 (PST)
MIME-Version 1.0
Content-Type text/plain; charset="UTF-8"
Content-Transfer-Encoding quoted-printable
X-Debian-Message from BTS
X-Mailing-List <debian-bugs-dist@lists.debian.org> archive/latest/1820753
List-ID <debian-bugs-dist.lists.debian.org>
List-URL <https://lists.debian.org/debian-bugs-dist/>
Approved robomod@news.nic.it
Lines 73
Organization linux.* mail to news gateway
Sender robomod@news.nic.it
X-Original-Cc Salvatore Bonaccorso <carnil@debian.org>, David Teigland <teigland@redhat.com>, Alexander Aring <aahringo@redhat.com>, 1063338@bugs.debian.org, gfs2@lists.linux.dev, linux-kernel@vger.kernel.org, stable@vger.kernel.org, gregkh@linuxfoundation.org, regressions@lists.linux.dev
X-Original-Date Thu, 8 Feb 2024 09:42:24 -0800
X-Original-Message-ID <CADKFtnQUQt=M32tYhcutP0q6exOgk9R6xgxddDdewbms+7xwTQ@mail.gmail.com>
X-Original-References <38f51dbb-65aa-4ec2-bed2-e914aef27d25@vrvis.at> <ZcNdzZVPD76uSbps@eldamar.lan> <CADKFtnRfqi-A_Ak_S-YC52jPn604+ekcmCmNoTA_yEpAcW4JJg@mail.gmail.com> <1d4c7d06-0c02-4adb-a2a3-ec85fd802ddb@vrvis.at> <38f51dbb-65aa-4ec2-bed2-e914aef27d25@vrvis.at> <1d4c7d06-0c02-4adb-a2a3-ec85fd802ddb@vrvis.at>
Xref csiph.com linux.debian.bugs.dist:1185481 linux.kernel:1743400 linux.debian.kernel:81795

Cross-posted to 3 groups.

Show key headers only | View raw


On Thu, Feb 8, 2024 at 3:37 AM Valentin Kleibel <valentin@vrvis.at> wrote:
>
> Hi Jordan, hi all
>
> > Just a quick look comparing dlm_tcp_listen_bind between the latest 6.1
> > and 6.6 stable branches,
> > it looks like there is a mismatch here with the dlm_local_addr[0] parameter.
> >
> > 6.1
> > ----
> >
> > static int dlm_tcp_listen_bind(struct socket *sock)
> > {
> > int addr_len;
> >
> > /* Bind to our port */
> > make_sockaddr(dlm_local_addr[0], dlm_config.ci_tcp_port, &addr_len);
> > return kernel_bind(sock, (struct sockaddr *)&dlm_local_addr[0],
> >     addr_len);
> > }
> >
> > 6.6
> > ----
> > static int dlm_tcp_listen_bind(struct socket *sock)
> > {
> > int addr_len;
> >
> > /* Bind to our port */
> > make_sockaddr(&dlm_local_addr[0], dlm_config.ci_tcp_port, &addr_len);
> > return kernel_bind(sock, (struct sockaddr *)&dlm_local_addr[0],
> >     addr_len);
> > }
> >
> > 6.6 contains commit c51c9cd8 (fs: dlm: don't put dlm_local_addrs on heap) which
> > changed
> >
> > static struct sockaddr_storage *dlm_local_addr[DLM_MAX_ADDR_COUNT];
> >
> > to
> >
> > static struct sockaddr_storage dlm_local_addr[DLM_MAX_ADDR_COUNT];
> >
> > It looks like kernel_bind() in 6.1 needs to be modified to match.
>
> We tried to apply commit c51c9cd8 (fs: dlm: don't put dlm_local_addrs on
> heap) to the debian kernel 6.1.76 and came up with the attached patch.
> Besides the different offsets there is a slight change dlm_tcp_bind()
> where in 6.1.76 kernel_bind() is used instead of sock->ops->bind() in
> the original commit.
>
> This patch solves the issue we experienced.
>
> Thanks for your help,
> Valentin

Good to hear that works for you! We should fix this in the 6.1 stable
kernel as well.

IMO it may be less risky and simpler to fix the backport of my patch
e9cdebbe23f1 ("dlm: use kernel_connect() and
kernel_bind()") and just switch (struct sockaddr *)&dlm_local_addr[0]
to (struct sockaddr *)dlm_local_addr[0]
in the call to kernel_bind() rather than backporting c51c9cd8 (fs:
dlm: don't put dlm_local_addrs on
heap) to 6.1.

I will have some time soon to fix the 6.1 backport, but it may make
sense just to revert in the meantime.

-Jordan

Back to linux.debian.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Bug#1063338: dlm: cannot start dlm midcomms -97 Valentin Kleibel <valentin@vrvis.at> - 2024-02-06 13:10 +0100
  Bug#1063338: [regression 6.1.67] dlm: cannot start dlm midcomms -97 after backport of e9cdebbe23f1 ("dlm: use kernel_connect() and kernel_bind()") Salvatore Bonaccorso <carnil@debian.org> - 2024-02-07 11:50 +0100
    Bug#1063338: [regression 6.1.67] dlm: cannot start dlm midcomms -97 after backport of e9cdebbe23f1 ("dlm: use kernel_connect() and kernel_bind()") Jordan Rife <jrife@google.com> - 2024-02-07 19:40 +0100
      Bug#1063338: [regression 6.1.67] dlm: cannot start dlm midcomms -97 after backport of e9cdebbe23f1 ("dlm: use kernel_connect() and kernel_bind()") Alexander Aring <aahringo@redhat.com> - 2024-02-07 22:40 +0100
  Bug#1063338: [regression 6.1.76] dlm: cannot start dlm midcomms -97 after backport of e9cdebbe23f1 ("dlm: use kernel_connect() and kernel_bind()") Jordan Rife <jrife@google.com> - 2024-02-08 18:50 +0100
    Bug#1063338: [regression 6.1.76] dlm: cannot start dlm midcomms -97 after backport of e9cdebbe23f1 ("dlm: use kernel_connect() and kernel_bind()") Jordan Rife <jrife@google.com> - 2024-02-08 22:30 +0100
      Bug#1063338: [regression 6.1.76] dlm: cannot start dlm midcomms -97 after backport of e9cdebbe23f1 ("dlm: use kernel_connect() and kernel_bind()") Valentin Kleibel <valentin@vrvis.at> - 2024-02-09 12:10 +0100
        Bug#1063338: [regression 6.1.76] dlm: cannot start dlm midcomms -97 after backport of e9cdebbe23f1 ("dlm: use kernel_connect() and kernel_bind()") Jordan Rife <jrife@google.com> - 2024-02-09 17:40 +0100
  Bug#1063338: dlm: cannot start dlm midcomms -97 Salvatore Bonaccorso <carnil@debian.org> - 2024-02-19 21:10 +0100
  Processed: Re: Bug#1063338: dlm: cannot start dlm midcomms -97 "Debian Bug Tracking System" <owner@bugs.debian.org> - 2024-02-19 21:10 +0100

csiph-web