Package: ruby-kgio
Version: 2.9.2-1
Severity: normal
Tags: patch
User: [email protected]
Usertags: origin-ubuntu utopic ubuntu-patch
Dear Maintainer,
In Ubuntu, the attached patch was applied to achieve the following:
* d/p/fix-test-test_default_wait: fix up bad assumption in test that
reading 16K is sufficient to open write space in a pipe. Also add
commentary to the test for the next person who hits this.
This fixes an FTBFS on ppc64el (and any other linux architecture with
page sizes above 16KB.
Thanks for considering the patch.
-apw
-- System Information:
Debian Release: jessie/sid
APT prefers trusty-updates
APT policy: (500, 'trusty-updates'), (500, 'trusty-security'), (500,
'trusty'), (100, 'trusty-backports')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 3.13.0-25-generic (SMP w/4 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
diff -Nru ruby-kgio-2.9.2/debian/changelog ruby-kgio-2.9.2/debian/changelog
diff -Nru ruby-kgio-2.9.2/debian/patches/fix-test-test_default_wait ruby-kgio-2.9.2/debian/patches/fix-test-test_default_wait
--- ruby-kgio-2.9.2/debian/patches/fix-test-test_default_wait 1970-01-01 01:00:00.000000000 +0100
+++ ruby-kgio-2.9.2/debian/patches/fix-test-test_default_wait 2014-04-29 15:21:57.000000000 +0100
@@ -0,0 +1,27 @@
+Description: fix test to take account of larger page sizes on ppc64el
+ The test_default_wait/TestDefaultWait test assume that a single read
+ can definatly switch a "full" pipe to one which will poll writable. The
+ kernel optimises for IO size by delaying the writable status until a
+ complete buffer slot is available; these are the system page. The test
+ already exhibits this by using large IOs compared to the common 4K page
+ size, but this is not sufficient in the face of the 64K page sizes on
+ ppc64el. Up this to 64k which represents the biggest page size available
+ in the kernel.
+Author: Andy Whitcroft <[email protected]>
+Last-Update: 2014-04-29
+
+--- ruby-kgio-2.9.2.orig/test/test_default_wait.rb
++++ ruby-kgio-2.9.2/test/test_default_wait.rb
+@@ -39,7 +39,11 @@ class TestDefaultWait < Test::Unit::Test
+ diff = Time.now - t0
+ assert_in_delta diff, 1.1, 0.2
+
+- a.kgio_read(16384)
++ # Read enough to ensure one kernel buffer is cleared
++ # to ensure that poll et al will start saying we have
++ # enough space to allow a write. This should be at
++ # least the largest system page size we support.
++ a.kgio_read(65536)
+ assert_equal b, b.kgio_wait_writable(1.1)
+ end
+ end
diff -Nru ruby-kgio-2.9.2/debian/patches/series ruby-kgio-2.9.2/debian/patches/series
--- ruby-kgio-2.9.2/debian/patches/series 2014-04-09 21:11:14.000000000 +0100
+++ ruby-kgio-2.9.2/debian/patches/series 2014-04-29 15:16:37.000000000 +0100
@@ -1 +1,2 @@
fix-test
+fix-test-test_default_wait
_______________________________________________
Pkg-ruby-extras-maintainers mailing list
[email protected]
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-ruby-extras-maintainers