From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=0.2 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED autolearn=no autolearn_force=no version=3.4.4 Received: (qmail 3697 invoked from network); 6 Dec 2021 23:48:56 -0000 Received: from 4ess.inri.net (216.126.196.42) by inbox.vuxu.org with ESMTPUTF8; 6 Dec 2021 23:48:56 -0000 Received: from 95.179.159.8 ([95.179.159.8]) by 4ess; Mon Dec 6 18:32:22 -0500 2021 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; s=default; bh=DnU0vmSjhmh4 fRuy/pn8GZYRakwUl2IU3KT963aLivU=; h=subject:to:from:date; d=margiolis.net; b=CxjIDqnAp/7Kp5yUEIwgxFlVSUlo/xPgmBqh/mvGeGn0Jz0yte+ xzGho6VcGAmznx+ejaalCNR7wXdtcshjplL8Z7dBtTrni2knDnkC104bUnFx/oiPpYRLNY 0WWO4Z101jBYmx6ZZwA5vxazV9fDOxcRM6Qgak+QF7tVKB3MBw= Received: from pleb (athedsl-204457.home.otenet.gr [85.74.118.71]) by christos (OpenSMTPD) with ESMTPSA id c715e313 (TLSv1.3:AEAD-AES256-GCM-SHA384:256:NO) for <9front@9front.org>; Mon, 6 Dec 2021 22:32:12 +0000 (UTC) Date: Tue, 7 Dec 2021 00:31:58 +0200 From: Christos Margiolis To: 9front@9front.org Message-ID: <20211206223158.tuz3mgmwu6axirdt@pleb> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="dzfprv3y7xj7dcyl" Content-Disposition: inline List-ID: <9front.9front.org> List-Help: X-Glyph: ➈ X-Bullshit: configuration interface-based module dependency callback template Subject: [9front] [PATCH] 9/pc/trap.c: Make case fallthrough Reply-To: 9front@9front.org Precedence: bulk --dzfprv3y7xj7dcyl Content-Type: text/plain; charset=us-ascii Content-Disposition: inline There is no need to have 2 cases doing the exact same thing. Christos --dzfprv3y7xj7dcyl Content-Type: multipart/mixed; boundary="upas-fajpzhjhxpahtmzpjufvfalgnb" Content-Disposition: inline This is a multi-part message in MIME format. --upas-fajpzhjhxpahtmzpjufvfalgnb Content-Disposition: inline Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit from postmaster@4ess: The following attachment had content that we can't prove to be harmless. To avoid possible automatic execution, we changed the content headers. The original header was: Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="9trap_fallthrough.diff" --upas-fajpzhjhxpahtmzpjufvfalgnb Content-Type: application/octet-stream Content-Disposition: attachment; filename="9trap_fallthrough.diff.suspect" diff e2a8d3493ab0fdc345b6513a53f30f2b4f36ed97 uncommitted --- a/sys/src/9/pc/trap.c +++ b/sys/src/9/pc/trap.c @@ -39,14 +39,10 @@ for(v = 0; v < 256; v++){ d1 = (vaddr & 0xFFFF0000)|SEGP; switch(v){ - case VectorBPT: - d1 |= SEGPL(3)|SEGIG; - break; - + case VectorBPT: /* FALLTHROUGH */ case VectorSYSCALL: d1 |= SEGPL(3)|SEGIG; break; - default: d1 |= SEGPL(0)|SEGIG; break; --upas-fajpzhjhxpahtmzpjufvfalgnb-- --dzfprv3y7xj7dcyl--