3 %bcond_without dist_kernel # allow non-distribution kernel
4 %bcond_with verbose # verbose build (V=1)
7 Summary: SSR packets scheduler (Simple Round Robin)
8 Summary(pl.UTF-8): Moduł szeregujący pakiety SRR (prosty algorytm karuzelowy)
9 Name: kernel%{_alt_kernel}-net-sch_srr
11 Release: %{_rel}@%{_kernel_ver_str}
14 Source0: http://mordor.strace.net/sched-srr/sch_srr.v%{version}.tgz
15 # Source0-md5: b51172937997920bfcc1381340cf9de6
16 URL: http://mordor.strace.net/sched-srr/
17 %{?with_dist_kernel:BuildRequires: kernel%{_alt_kernel}-module-build >= 3:2.6.20.2}
18 BuildRequires: rpmbuild(macros) >= 1.379
19 Requires(post,postun): /sbin/depmod
20 %if %{with dist_kernel}
21 %requires_releq_kernel
22 Requires(postun): %releq_kernel
24 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27 This package contains SRR packets scheduler (Simple Round Robin).
29 Simple Round Robin packets schedules - this is the schedules of
30 packets for the Linux operating system with kernels 2.4 or 2.6. Its
31 purpose is the simply round robin distribution of the resources of the
32 allocated bandwidth between its users. It works as follows: the
33 internal queue of scheduler is divided into the given number of
34 virtual queues (slots). Each slot, in turn, has hard limited number of
35 packets located in it. Internal classifier distributes the entering in
36 scheduler packets along the slots, being based either on source IP
37 address or on destination IP address. With the selection of packet
38 from the scheduler, the slots will be processed cyclically, which will
39 ensure more or less uniform distribution.
41 %description -l pl.UTF-8
42 Ten pakiet zawiera moduł szeregujący pakiety SRR (Simple Round Robin).
44 Prosty algorytm karuzelowy przeznaczony dla Linuksa z jądrem 2.4 lub
45 2.6. Jego zadaniem jest zarządzanie dostępnym pasmem pomiędzy
46 wszystkich użytkowników. Prosty algorytm karuzelowy (SRR - Simple
47 Round Robin) działa w następujący sposób: kolejka wewnętrzna modułu
48 szeregującego jest dzielona na zadaną liczbę wirtualnych kolejek
49 (slotów). Z kolei każdy slot posiada ściśle ograniczoną liczbę
50 pakietów. Wewnętrzny klasyfikator dzieli wchodzące pakiety pomiędzy
51 sloty używając do tego celu źródłowego lub docelowego adresu IP. Sloty
52 przetwarzane są karuzelowo (cyklicznie) co zapewnia mniej lub bardziej
53 sprawiedliwą dystrybucję pakietów.
56 %setup -q -n sch_srr.v%{version}
58 cat > Makefile <<'EOF'
64 %build_kernel_modules -m sch_srr
67 rm -rf $RPM_BUILD_ROOT
68 %install_kernel_modules -m sch_srr -d kernel/net/sched
71 rm -rf $RPM_BUILD_ROOT
74 %depmod %{_kernel_ver}
77 %depmod %{_kernel_ver}
80 %defattr(644,root,root,755)
81 /lib/modules/%{_kernel_ver}/kernel/net/sched/sch_srr*.ko*