From owner-freebsd-current@FreeBSD.ORG Wed Dec 18 17:27:56 2013 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 73F5F1E1 for ; Wed, 18 Dec 2013 17:27:56 +0000 (UTC) Received: from hydra.pix.net (hydra.pix.net [IPv6:2001:470:e254::3c]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 4200F120F for ; Wed, 18 Dec 2013 17:27:56 +0000 (UTC) Received: from torb.pix.net (torb.pix.net [IPv6:2001:470:e254:10:12dd:b1ff:febf:eca9]) (authenticated bits=0) by hydra.pix.net (8.14.5/8.14.5) with ESMTP id rBIHRsvC096918; Wed, 18 Dec 2013 12:27:54 -0500 (EST) (envelope-from lidl@pix.net) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.98 at mail.pix.net Message-ID: <52B1DB1A.7000007@pix.net> Date: Wed, 18 Dec 2013 12:27:54 -0500 From: Kurt Lidl User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:24.0) Gecko/20100101 Thunderbird/24.2.0 MIME-Version: 1.0 To: FreeBSD-Current Subject: makefs enhancement for better rock-ridge support Content-Type: multipart/mixed; boundary="------------040000020509050202000503" X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Dec 2013 17:27:56 -0000 This is a multi-part message in MIME format. --------------040000020509050202000503 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit A while ago, it was reported that the ISO images that FreeBSD generates have a variety of problems (thread starts here): http://lists.freebsd.org/pipermail/freebsd-stable/2013-April/073050.html And again for the 10.0 releases: http://lists.freebsd.org/pipermail/freebsd-stable/2013-December/076284.html Looking into this, it appears that the various bugs in the Rock Ridge extensions have been fixed, except for the actual lack of recording the "serial" numbers in the correct place of the Rock Ridge data. As it turns out, it is almost trivial to fix this. Patch is attached to this message, which will probably be stripped out by the mailing list, but should be available as an attachment from the mail server. -Kurt --------------040000020509050202000503 Content-Type: text/plain; charset=UTF-8; x-mac-type="0"; x-mac-creator="0"; name="makefs.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="makefs.diff" diff --git a/usr.sbin/makefs/cd9660/iso9660_rrip.c b/usr.sbin/makefs/cd9660/iso9660_rrip.c --- a/usr.sbin/makefs/cd9660/iso9660_rrip.c +++ b/usr.sbin/makefs/cd9660/iso9660_rrip.c @@ -629,28 +629,29 @@ cd9660_createSL(cd9660node *node) } } } } int cd9660node_rrip_px(struct ISO_SUSP_ATTRIBUTES *v, fsnode *pxinfo) { - v->attr.rr_entry.PX.h.length[0] = 36; + v->attr.rr_entry.PX.h.length[0] = 44; v->attr.rr_entry.PX.h.version[0] = 1; cd9660_bothendian_dword(pxinfo->inode->st.st_mode, v->attr.rr_entry.PX.mode); cd9660_bothendian_dword(pxinfo->inode->st.st_nlink, v->attr.rr_entry.PX.links); cd9660_bothendian_dword(pxinfo->inode->st.st_uid, v->attr.rr_entry.PX.uid); cd9660_bothendian_dword(pxinfo->inode->st.st_gid, v->attr.rr_entry.PX.gid); + cd9660_bothendian_dword(pxinfo->inode->st.st_ino, + v->attr.rr_entry.PX.serial); - /* Ignoring the serial number for now */ return 1; } int cd9660node_rrip_pn(struct ISO_SUSP_ATTRIBUTES *pn_field, fsnode *fnode) { pn_field->attr.rr_entry.PN.h.length[0] = 20; pn_field->attr.rr_entry.PN.h.version[0] = 1; diff --git a/usr.sbin/makefs/cd9660/iso9660_rrip.h b/usr.sbin/makefs/cd9660/iso9660_rrip.h --- a/usr.sbin/makefs/cd9660/iso9660_rrip.h +++ b/usr.sbin/makefs/cd9660/iso9660_rrip.h @@ -98,17 +98,17 @@ #define SL_FLAGS_ROOT 8 typedef struct { ISO_SUSP_HEADER h; u_char mode [ISODCL(5,12)]; u_char links [ISODCL(13,20)]; u_char uid [ISODCL(21,28)]; u_char gid [ISODCL(29,36)]; - u_char serial [ISODCL(37,44)];/* Not used */ + u_char serial [ISODCL(37,44)]; } ISO_RRIP_PX; typedef struct { ISO_SUSP_HEADER h; u_char high [ISODCL(5,12)]; u_char low [ISODCL(13,20)]; } ISO_RRIP_PN; --------------040000020509050202000503--