[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Summary: Re: [PATCH for-4.17 v3 00/15] OCaml fixes for Xen 4.17


  • To: Edwin Torok <edvin.torok@xxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Andrew Cooper <Andrew.Cooper3@xxxxxxxxxx>
  • Date: Fri, 11 Nov 2022 20:46:33 +0000
  • Accept-language: en-GB, en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=LbQKZwwFb+48b2hZwngj2rcQlT1T0oyCgAu2QSPatl0=; b=MXyaniQTYZN+AmgGuVFNZah06bX6ZQBpvTykyK15gg1v3NqL8966sbUKO6ShEk/hvzFWLVAGFNe7m8+27IMxWHb73qJ20fsQntz/cnbvnfO+YhUHzlolkmKzTCZwrHeuDhyxAsx0ELrgocuv79QzC/sd654oCqH2mKBBorHeHwPRjflsaDCB6ht7E5Bo81tbWoHcK14FXs9PqTP6PTtR3MRzUoXAPMmJPXiHEt5SRbzKPk3x7x6ppkW+uRFleOwnHBdlUf0thVAiPQcAXHKD7+DXfHx6Z9k6yaZnnbpw+Idpg1i1DnhuSKurx6MPKAxdWrjpWpcvPNUsieOkd136AA==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=KKak4GeWZwSWTcqexCI3JtrTbXPIXgvIlfAzJZ9m5oblxH2zspH9vldoCft7QwxFuMqXUCmRDRQTfwhIhPq1DcbEc+8EvVIlh/Ag8+h6bxv2xQavjwX32aWtIcoAjvfiN1bPdhOHmvGpuc/4qu80We0qyJTTYHtBZykJ5bPVzDZBcnIUdpdR1Ry+eJ1V2L0avMpAe6PcfkuPxcltWu3+DQpiJni49xF4r2MSFDIOq6pg6jYC+zdMrDeDVh0WKsKp6WwTsSynQ/CN/6RBJWzE6n8237QiTKMIuKf8SVfUqPRxJb2P+na8TAGmayZs1KlgU/yjhw4ZOkmXUUeA0b4TfA==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=citrix.com;
  • Cc: Henry Wang <Henry.Wang@xxxxxxx>, Christian Lindig <christian.lindig@xxxxxxxxxx>, David Scott <dave@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, Anthony Perard <anthony.perard@xxxxxxxxxx>
  • Delivery-date: Fri, 11 Nov 2022 20:46:56 +0000
  • Ironport-data: A9a23:YCG/nK3EklrggLk7xPbD5e9wkn2cJEfYwER7XKvMYLTBsI5bpzZTz zNLD2DTPK2OY2TzKI1/Ot+08UJX75GGytRhGwM6pC1hF35El5HIVI+TRqvS04F+DeWYFR46s J9OAjXkBJppJpMJjk71atANlVEliefTAOK5ULSfUsxIbVcMYD87jh5+kPIOjIdtgNyoayuAo tq3qMDEULOf82cc3lk8tuTS9nuDgNyo4GlC5wVnPKgR1LPjvyJ94Kw3dPnZw0TQGuG4LsbiL 87fwbew+H/u/htFIrtJRZ6iLyXm6paLVeS/oiI+t5qK23CulQRrukoPD9IOaF8/ttm8t4sZJ OOhF3CHYVxB0qXkwIzxWvTDes10FfUuFLTveRBTvSEPpqFvnrSFL/hGVSkL0YMkFulfWnFvp PVFEyExNxm6n8mrmIOeb+lvmZF2RCXrFNt3VnBI6xj8VK9jareaBqLA6JlfwSs6gd1IEbDGf c0FZDFzbRPGJRpSJlMQD5F4l+Ct7pX9W2QA9BTJ+uxqvS6Kk1MZPLvFabI5fvSjQ8lPk1nej WXB52njWTkRNcCFyCrD+XWp7gPKtXOgB9lDTuHknhJsqGO55U1NFhM5bgS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sQoufsw39d3w3koYHyCl7G2ACwHtLAqd0 1jJ76imr+npACNjBT101k=
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Thread-index: AQHY84ewJ0jjWhTeBE61ayU/ec/VkK46Nk6A
  • Thread-topic: Summary: Re: [PATCH for-4.17 v3 00/15] OCaml fixes for Xen 4.17

Nothing here is critical enough to go into 4.17 at this juncture.

Various notes/observations from having spent a day trying to untangle
things.

1) Patches 5/6 are a single bugfix and need merging.  Except there was
also an error when taking feedback from the list, and the net result
regresses the original optimisation.  I have a fix sorted in my local queue.

2) The indentation fix (not attached to this series) should scope the
logic, not delete a debug line which was presumably added for a good
reason.  I've got a fix to this effect in my local queue, and we can
discuss the pros/cons of the approach in due course.

3) Patch 1, evtchn Ocaml 5.0 compat, is still missing some corrections
which I gave on earlier postings.  I've fixed it up locally in my queue.

I also notice, while reviewing the whole, that stub_eventchn_init()
passes NULL as a logger, which has the side effect of libxenevtchn
instantiating a default logger which takes control of stdout/stderr. 
Without starting the fight over toxic library behaviour yet again, it
occurs to me in the context of Patch 13, uncaught exception handler,
that in oxenstored, any logging from the C level needs to end up elsewhere.

While we do have ocaml bindings for xentoollog, nothing uses it, and
none of the other libraries (save xl, which isn't used) have a way of
passing the Ocaml Xentoollog down.  This probably wants rethinking, one
way or another.

4) Patches 2/3.  All these libraries have far worse problems than
evtchn, because they can easily use-after-free.  They all need to be
Custom with a finaliser.

5) Patch 4.  The commit message says "A better solution is being worked
on for master", but this is master.  Also, it's not a prerequisite for a
security fix; merely something to make a developers life easier.

6) The re-indent patch.  Policies of when to do it aside, having tried
using it, the format adjustment is incomplete (running ocp-indent gets
me deltas in files I haven't touched), and there needs to be some
.gitignore changes.

That said, it is usually frowned upon to have logic depending on being
in a git tree.  This was perhaps a bigger deal back when we used hg by
default and mirrored into multiple SCMs, but it's still expected not to
rely on this.

7) Patch 8, evtchn fdopen, is two separate patches.  One adding fdopen,
and one adding a NOCLOEXEC argument to the existing init.

They want splitting in two.  fdopen() ought to pass flags so we don't
have to break the ABI again when there is a flag needing passing, and
cloexec probably shouldn't be a boolean.  We should either pass a raw
int32, or a list-of-enums like we do in the xenctrl stubs.  Also, this
patch has inherited errors from patch 1.

9) Patches 8 thru 15 need to be the other side of the intent patch,
because they need backporting to branches which will never get it.  This
is why bugfixes always go at the head of a patch series, and
improvements at the tail.

10) Patch 12 talks about default log levels, but that's bogus
reasoning.  The messages should be warnings because they non-fatal
exceptional cases.

11) Patch 14 talks about using caml_stat_strdup(), but doesn't.

~Andrew

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.