From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1YB2fW-0000Wk-5E for mharc-grub-devel@gnu.org; Tue, 13 Jan 2015 09:42:06 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:34079) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YB2fT-0000VN-F7 for grub-devel@gnu.org; Tue, 13 Jan 2015 09:42:04 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YB2fN-0003FE-Tm for grub-devel@gnu.org; Tue, 13 Jan 2015 09:42:03 -0500 Received: from r12.unimplemented.org ([141.0.20.126]:48703) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YB2fN-0003F3-Nj for grub-devel@gnu.org; Tue, 13 Jan 2015 09:41:57 -0500 Date: Tue, 13 Jan 2015 15:41:55 +0100 From: Valentin Dornauer To: Andrey Borzenkov Subject: Re: [PATCH] Avoid reusing the same TCP port number Message-ID: <20150113144155.GA7598@unimplemented.org> References: <20140703224125.2e8962fa@opensuse.site> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20140703224125.2e8962fa@opensuse.site> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 141.0.20.126 Cc: grub-devel@gnu.org X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Jan 2015 14:42:04 -0000 Hello Andrey, On Thu, Jul 03, 2014 at 10:41:25PM +0400, Andrey Borzenkov wrote: > May be you can simply use grub_get_time_ms()? After all, we are not > interested in exact time, just in some pseudo-random distribution. It > should have less overhead than grub_get_datetime(). I finally got around to trying out your suggestion concerning the TCP source port "randomization". The main problem I see with using the TSC's value instead of the current time of day (in seconds) is that it will have approximately the same value every time the machine is rebooted and reaches the point where the first file is loaded. This means that clashes are way more likely than with the RTC based solution, at least for the first file. Little or no network jitter could mean even more collisions. Do you think it's still worth the effort to change the previously proposed [1] patch? Thanks Valentin [1] http://lists.gnu.org/archive/html/grub-devel/2014-07/msg00000.html