--- /dev/null
+# Configure the MTU for the interface
+
+eval $(/usr/local/bin/readhash /var/ipfire/ethernet/settings)
+
+set_mtu()
+{
+ local mtu=$1
+ ip link set "$interface" mtu "$mtu"
+
+ # test for buggy nic that lose link at mtu set...
+ carrier=`cat /sys/class/net/$interface/carrier`
+ if [ "$carrier" == "0" ]; then
+ syslog info "Warning! Carrier loss after MTU set. Reinit ..."
+ ip link set "$interface" down
+ ip link set "$interface" up
+ fi
+}
+if [ -n "$new_interface_mtu" ] && $if_up; then
+ if [ $RED_DHCP_FORCE_MTU -ge 576 ]; then
+ new_interface_mtu=$RED_DHCP_FORCE_MTU
+ fi
+ if [ ! "$new_interface_mtu" == "$ifmtu" ]; then
+ # The smalled MTU dhcpcd can work with is 576
+ if [ "$new_interface_mtu" -gt 576 ]; then
+ if set_mtu "$new_interface_mtu"; then
+ syslog info "MTU set to $new_interface_mtu"
+ fi
+ fi
+ fi
+fi
+
# additional kernel modules to the default
#add_drivers+=""
+# skip kernel modules (marvell sdio and compat from backports)
+omit_drivers+="libertas libertas_sdio mwifiex mwifiex_sdio compat"
+
# list of kernel filesystem modules to be included in the generic initramfs
filesystems+="reiserfs vfat xfs"
--- /dev/null
+# Disable automatic conntrack helper assignment
+options nf_conntrack nf_conntrack_helper=0
# Allow access from GREEN
iptables -A POLICYIN -i "${GREEN_DEV}" -j ACCEPT
+# Allow access from BLUE
+if [ "${HAVE_BLUE}" = "true" ] && [ -n "${BLUE_DEV}" ]; then
+ iptables -A POLICYIN -i "${BLUE_DEV}" -j ACCEPT
+fi
+
# IPsec INPUT
case "${HAVE_IPSEC},${POLICY}" in
true,MODE1) ;;
CONFIG_HAVE_ARCH_SECCOMP_FILTER=y
CONFIG_SECCOMP_FILTER=y
CONFIG_HAVE_CC_STACKPROTECTOR=y
-CONFIG_CC_STACKPROTECTOR=y
+# CONFIG_CC_STACKPROTECTOR is not set
# CONFIG_CC_STACKPROTECTOR_NONE is not set
CONFIG_CC_STACKPROTECTOR_REGULAR=y
-# CONFIG_CC_STACKPROTECTOR_STRONG is not set
+CONFIG_CC_STACKPROTECTOR_STRONG=y
CONFIG_HAVE_CONTEXT_TRACKING=y
CONFIG_HAVE_VIRT_CPU_ACCOUNTING_GEN=y
CONFIG_HAVE_IRQ_TIME_ACCOUNTING=y
CONFIG_GRKERNSEC_BRUTE=y
CONFIG_GRKERNSEC_MODHARDEN=y
CONFIG_GRKERNSEC_HIDESYM=y
-CONFIG_GRKERNSEC_RANDSTRUCT=y
-CONFIG_GRKERNSEC_RANDSTRUCT_PERFORMANCE=y
+# CONFIG_GRKERNSEC_RANDSTRUCT is not set
CONFIG_GRKERNSEC_KERN_LOCKOUT=y
#
CONFIG_ARCH_WANT_IPC_PARSE_VERSION=y
CONFIG_HAVE_ARCH_SECCOMP_FILTER=y
CONFIG_HAVE_CC_STACKPROTECTOR=y
-CONFIG_CC_STACKPROTECTOR=y
+# CONFIG_CC_STACKPROTECTOR is not set
# CONFIG_CC_STACKPROTECTOR_NONE is not set
CONFIG_CC_STACKPROTECTOR_REGULAR=y
-# CONFIG_CC_STACKPROTECTOR_STRONG is not set
+CONFIG_CC_STACKPROTECTOR_STRONG=y
CONFIG_HAVE_CONTEXT_TRACKING=y
CONFIG_HAVE_VIRT_CPU_ACCOUNTING_GEN=y
CONFIG_HAVE_IRQ_TIME_ACCOUNTING=y
CONFIG_GRKERNSEC_BRUTE=y
CONFIG_GRKERNSEC_MODHARDEN=y
CONFIG_GRKERNSEC_HIDESYM=y
-CONFIG_GRKERNSEC_RANDSTRUCT=y
-CONFIG_GRKERNSEC_RANDSTRUCT_PERFORMANCE=y
+# CONFIG_GRKERNSEC_RANDSTRUCT is not set
CONFIG_GRKERNSEC_KERN_LOCKOUT=y
CONFIG_GRKERNSEC_OLD_ARM_USERLAND=y
CONFIG_HAVE_ARCH_SECCOMP_FILTER=y
CONFIG_SECCOMP_FILTER=y
CONFIG_HAVE_CC_STACKPROTECTOR=y
-CONFIG_CC_STACKPROTECTOR=y
+# CONFIG_CC_STACKPROTECTOR is not set
# CONFIG_CC_STACKPROTECTOR_NONE is not set
CONFIG_CC_STACKPROTECTOR_REGULAR=y
-# CONFIG_CC_STACKPROTECTOR_STRONG is not set
+CONFIG_CC_STACKPROTECTOR_STRONG=y
CONFIG_HAVE_CONTEXT_TRACKING=y
CONFIG_HAVE_VIRT_CPU_ACCOUNTING_GEN=y
CONFIG_HAVE_IRQ_TIME_ACCOUNTING=y
CONFIG_GRKERNSEC_BRUTE=y
CONFIG_GRKERNSEC_MODHARDEN=y
CONFIG_GRKERNSEC_HIDESYM=y
-CONFIG_GRKERNSEC_RANDSTRUCT=y
-CONFIG_GRKERNSEC_RANDSTRUCT_PERFORMANCE=y
+# CONFIG_GRKERNSEC_RANDSTRUCT is not set
CONFIG_GRKERNSEC_KERN_LOCKOUT=y
CONFIG_GRKERNSEC_OLD_ARM_USERLAND=y
CONFIG_HAVE_ARCH_SECCOMP_FILTER=y
CONFIG_SECCOMP_FILTER=y
CONFIG_HAVE_CC_STACKPROTECTOR=y
-CONFIG_CC_STACKPROTECTOR=y
+# CONFIG_CC_STACKPROTECTOR is not set
# CONFIG_CC_STACKPROTECTOR_NONE is not set
CONFIG_CC_STACKPROTECTOR_REGULAR=y
-# CONFIG_CC_STACKPROTECTOR_STRONG is not set
+CONFIG_CC_STACKPROTECTOR_STRONG=y
CONFIG_HAVE_IRQ_TIME_ACCOUNTING=y
CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE=y
CONFIG_HAVE_ARCH_SOFT_DIRTY=y
CONFIG_GRKERNSEC_BRUTE=y
CONFIG_GRKERNSEC_MODHARDEN=y
CONFIG_GRKERNSEC_HIDESYM=y
-CONFIG_GRKERNSEC_RANDSTRUCT=y
-CONFIG_GRKERNSEC_RANDSTRUCT_PERFORMANCE=y
+# CONFIG_GRKERNSEC_RANDSTRUCT is not set
CONFIG_GRKERNSEC_KERN_LOCKOUT=y
#
CONFIG_HAVE_ARCH_SECCOMP_FILTER=y
CONFIG_SECCOMP_FILTER=y
CONFIG_HAVE_CC_STACKPROTECTOR=y
-CONFIG_CC_STACKPROTECTOR=y
+# CONFIG_CC_STACKPROTECTOR is not set
# CONFIG_CC_STACKPROTECTOR_NONE is not set
CONFIG_CC_STACKPROTECTOR_REGULAR=y
-# CONFIG_CC_STACKPROTECTOR_STRONG is not set
+CONFIG_CC_STACKPROTECTOR_STRONG=y
CONFIG_HAVE_IRQ_TIME_ACCOUNTING=y
CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE=y
CONFIG_HAVE_ARCH_SOFT_DIRTY=y
CONFIG_GRKERNSEC_BRUTE=y
CONFIG_GRKERNSEC_MODHARDEN=y
CONFIG_GRKERNSEC_HIDESYM=y
-CONFIG_GRKERNSEC_RANDSTRUCT=y
-CONFIG_GRKERNSEC_RANDSTRUCT_PERFORMANCE=y
+# CONFIG_GRKERNSEC_RANDSTRUCT is not set
CONFIG_GRKERNSEC_KERN_LOCKOUT=y
#
CONFIG_HAVE_ARCH_SECCOMP_FILTER=y
CONFIG_SECCOMP_FILTER=y
CONFIG_HAVE_CC_STACKPROTECTOR=y
-CONFIG_CC_STACKPROTECTOR=y
+# CONFIG_CC_STACKPROTECTOR is not set
# CONFIG_CC_STACKPROTECTOR_NONE is not set
CONFIG_CC_STACKPROTECTOR_REGULAR=y
-# CONFIG_CC_STACKPROTECTOR_STRONG is not set
+CONFIG_CC_STACKPROTECTOR_STRONG=y
CONFIG_HAVE_CONTEXT_TRACKING=y
CONFIG_HAVE_VIRT_CPU_ACCOUNTING_GEN=y
CONFIG_HAVE_IRQ_TIME_ACCOUNTING=y
# CONFIG_GRKERNSEC_PERF_HARDEN is not set
CONFIG_GRKERNSEC_RAND_THREADSTACK=y
CONFIG_GRKERNSEC_PROC_MEMMAP=y
-CONFIG_GRKERNSEC_KSTACKOVERFLOW=y
+# CONFIG_GRKERNSEC_KSTACKOVERFLOW is not set
CONFIG_GRKERNSEC_BRUTE=y
CONFIG_GRKERNSEC_MODHARDEN=y
CONFIG_GRKERNSEC_HIDESYM=y
-CONFIG_GRKERNSEC_RANDSTRUCT=y
-CONFIG_GRKERNSEC_RANDSTRUCT_PERFORMANCE=y
+# CONFIG_GRKERNSEC_RANDSTRUCT is not set
CONFIG_GRKERNSEC_KERN_LOCKOUT=y
#
#usr/lib/ldscripts/armelfb_linux_eabi.xsw
#usr/lib/ldscripts/armelfb_linux_eabi.xu
#usr/lib/ldscripts/armelfb_linux_eabi.xw
-usr/lib/libbfd-2.22.so
+usr/lib/libbfd-2.24.so
#usr/lib/libbfd.a
#usr/lib/libbfd.la
#usr/lib/libbfd.so
#usr/lib/libiberty.a
-usr/lib/libopcodes-2.22.so
+usr/lib/libopcodes-2.24.so
#usr/lib/libopcodes.a
#usr/lib/libopcodes.la
#usr/lib/libopcodes.so
#usr/bin/armv5tel-unknown-linux-gnueabi-c++
#usr/bin/armv5tel-unknown-linux-gnueabi-g++
#usr/bin/armv5tel-unknown-linux-gnueabi-gcc
-#usr/bin/armv5tel-unknown-linux-gnueabi-gcc-4.4.7
+#usr/bin/armv5tel-unknown-linux-gnueabi-gcc-4.9.3
+#usr/bin/armv5tel-unknown-linux-gnueabi-gcc-ar
+#usr/bin/armv5tel-unknown-linux-gnueabi-gcc-nm
+#usr/bin/armv5tel-unknown-linux-gnueabi-gcc-ranlib
#usr/bin/c++
#usr/bin/cc
#usr/bin/cpp
#usr/bin/g++
#usr/bin/gcc
-#usr/bin/gccbug
+#usr/bin/gcc-ar
+#usr/bin/gcc-nm
+#usr/bin/gcc-ranlib
#usr/bin/gcov
#usr/include/c++
-#usr/include/c++/4.4.7
-#usr/include/c++/4.4.7/algorithm
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/atomic_word.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/basic_file.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/c++allocator.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/c++config.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/c++io.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/c++locale.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/cpu_defines.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/ctype_base.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/ctype_inline.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/ctype_noninline.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/cxxabi_tweaks.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/error_constants.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/extc++.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/gthr-default.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/gthr-posix.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/gthr-single.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/gthr-tpf.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/gthr.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/messages_members.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/os_defines.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/stdc++.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/stdtr1c++.h
-#usr/include/c++/4.4.7/armv5tel-unknown-linux-gnueabi/bits/time_members.h
-#usr/include/c++/4.4.7/array
-#usr/include/c++/4.4.7/backward
-#usr/include/c++/4.4.7/backward/auto_ptr.h
-#usr/include/c++/4.4.7/backward/backward_warning.h
-#usr/include/c++/4.4.7/backward/binders.h
-#usr/include/c++/4.4.7/backward/hash_fun.h
-#usr/include/c++/4.4.7/backward/hash_map
-#usr/include/c++/4.4.7/backward/hash_set
-#usr/include/c++/4.4.7/backward/hashtable.h
-#usr/include/c++/4.4.7/backward/strstream
-#usr/include/c++/4.4.7/bits
-#usr/include/c++/4.4.7/bits/algorithmfwd.h
-#usr/include/c++/4.4.7/bits/allocator.h
-#usr/include/c++/4.4.7/bits/atomic_0.h
-#usr/include/c++/4.4.7/bits/atomic_2.h
-#usr/include/c++/4.4.7/bits/atomicfwd_c.h
-#usr/include/c++/4.4.7/bits/atomicfwd_cxx.h
-#usr/include/c++/4.4.7/bits/basic_ios.h
-#usr/include/c++/4.4.7/bits/basic_ios.tcc
-#usr/include/c++/4.4.7/bits/basic_string.h
-#usr/include/c++/4.4.7/bits/basic_string.tcc
-#usr/include/c++/4.4.7/bits/boost_concept_check.h
-#usr/include/c++/4.4.7/bits/char_traits.h
-#usr/include/c++/4.4.7/bits/cmath.tcc
-#usr/include/c++/4.4.7/bits/codecvt.h
-#usr/include/c++/4.4.7/bits/concept_check.h
-#usr/include/c++/4.4.7/bits/cpp_type_traits.h
-#usr/include/c++/4.4.7/bits/deque.tcc
-#usr/include/c++/4.4.7/bits/forward_list.h
-#usr/include/c++/4.4.7/bits/forward_list.tcc
-#usr/include/c++/4.4.7/bits/fstream.tcc
-#usr/include/c++/4.4.7/bits/functexcept.h
-#usr/include/c++/4.4.7/bits/functional_hash.h
-#usr/include/c++/4.4.7/bits/gslice.h
-#usr/include/c++/4.4.7/bits/gslice_array.h
-#usr/include/c++/4.4.7/bits/hashtable.h
-#usr/include/c++/4.4.7/bits/indirect_array.h
-#usr/include/c++/4.4.7/bits/ios_base.h
-#usr/include/c++/4.4.7/bits/istream.tcc
-#usr/include/c++/4.4.7/bits/list.tcc
-#usr/include/c++/4.4.7/bits/locale_classes.h
-#usr/include/c++/4.4.7/bits/locale_classes.tcc
-#usr/include/c++/4.4.7/bits/locale_facets.h
-#usr/include/c++/4.4.7/bits/locale_facets.tcc
-#usr/include/c++/4.4.7/bits/locale_facets_nonio.h
-#usr/include/c++/4.4.7/bits/locale_facets_nonio.tcc
-#usr/include/c++/4.4.7/bits/localefwd.h
-#usr/include/c++/4.4.7/bits/mask_array.h
-#usr/include/c++/4.4.7/bits/move.h
-#usr/include/c++/4.4.7/bits/ostream.tcc
-#usr/include/c++/4.4.7/bits/ostream_insert.h
-#usr/include/c++/4.4.7/bits/postypes.h
-#usr/include/c++/4.4.7/bits/shared_ptr.h
-#usr/include/c++/4.4.7/bits/slice_array.h
-#usr/include/c++/4.4.7/bits/sstream.tcc
-#usr/include/c++/4.4.7/bits/stl_algo.h
-#usr/include/c++/4.4.7/bits/stl_algobase.h
-#usr/include/c++/4.4.7/bits/stl_bvector.h
-#usr/include/c++/4.4.7/bits/stl_construct.h
-#usr/include/c++/4.4.7/bits/stl_deque.h
-#usr/include/c++/4.4.7/bits/stl_function.h
-#usr/include/c++/4.4.7/bits/stl_heap.h
-#usr/include/c++/4.4.7/bits/stl_iterator.h
-#usr/include/c++/4.4.7/bits/stl_iterator_base_funcs.h
-#usr/include/c++/4.4.7/bits/stl_iterator_base_types.h
-#usr/include/c++/4.4.7/bits/stl_list.h
-#usr/include/c++/4.4.7/bits/stl_map.h
-#usr/include/c++/4.4.7/bits/stl_multimap.h
-#usr/include/c++/4.4.7/bits/stl_multiset.h
-#usr/include/c++/4.4.7/bits/stl_numeric.h
-#usr/include/c++/4.4.7/bits/stl_pair.h
-#usr/include/c++/4.4.7/bits/stl_queue.h
-#usr/include/c++/4.4.7/bits/stl_raw_storage_iter.h
-#usr/include/c++/4.4.7/bits/stl_relops.h
-#usr/include/c++/4.4.7/bits/stl_set.h
-#usr/include/c++/4.4.7/bits/stl_stack.h
-#usr/include/c++/4.4.7/bits/stl_tempbuf.h
-#usr/include/c++/4.4.7/bits/stl_tree.h
-#usr/include/c++/4.4.7/bits/stl_uninitialized.h
-#usr/include/c++/4.4.7/bits/stl_vector.h
-#usr/include/c++/4.4.7/bits/stream_iterator.h
-#usr/include/c++/4.4.7/bits/streambuf.tcc
-#usr/include/c++/4.4.7/bits/streambuf_iterator.h
-#usr/include/c++/4.4.7/bits/stringfwd.h
-#usr/include/c++/4.4.7/bits/unique_ptr.h
-#usr/include/c++/4.4.7/bits/valarray_after.h
-#usr/include/c++/4.4.7/bits/valarray_array.h
-#usr/include/c++/4.4.7/bits/valarray_array.tcc
-#usr/include/c++/4.4.7/bits/valarray_before.h
-#usr/include/c++/4.4.7/bits/vector.tcc
-#usr/include/c++/4.4.7/bitset
-#usr/include/c++/4.4.7/c++0x_warning.h
-#usr/include/c++/4.4.7/cassert
-#usr/include/c++/4.4.7/ccomplex
-#usr/include/c++/4.4.7/cctype
-#usr/include/c++/4.4.7/cerrno
-#usr/include/c++/4.4.7/cfenv
-#usr/include/c++/4.4.7/cfloat
-#usr/include/c++/4.4.7/chrono
-#usr/include/c++/4.4.7/cinttypes
-#usr/include/c++/4.4.7/ciso646
-#usr/include/c++/4.4.7/climits
-#usr/include/c++/4.4.7/clocale
-#usr/include/c++/4.4.7/cmath
-#usr/include/c++/4.4.7/complex
-#usr/include/c++/4.4.7/complex.h
-#usr/include/c++/4.4.7/condition_variable
-#usr/include/c++/4.4.7/csetjmp
-#usr/include/c++/4.4.7/csignal
-#usr/include/c++/4.4.7/cstdarg
-#usr/include/c++/4.4.7/cstdatomic
-#usr/include/c++/4.4.7/cstdbool
-#usr/include/c++/4.4.7/cstddef
-#usr/include/c++/4.4.7/cstdint
-#usr/include/c++/4.4.7/cstdio
-#usr/include/c++/4.4.7/cstdlib
-#usr/include/c++/4.4.7/cstring
-#usr/include/c++/4.4.7/ctgmath
-#usr/include/c++/4.4.7/ctime
-#usr/include/c++/4.4.7/cwchar
-#usr/include/c++/4.4.7/cwctype
-#usr/include/c++/4.4.7/cxxabi-forced.h
-#usr/include/c++/4.4.7/cxxabi.h
-#usr/include/c++/4.4.7/debug
-#usr/include/c++/4.4.7/debug/bitset
-#usr/include/c++/4.4.7/debug/debug.h
-#usr/include/c++/4.4.7/debug/deque
-#usr/include/c++/4.4.7/debug/formatter.h
-#usr/include/c++/4.4.7/debug/functions.h
-#usr/include/c++/4.4.7/debug/list
-#usr/include/c++/4.4.7/debug/macros.h
-#usr/include/c++/4.4.7/debug/map
-#usr/include/c++/4.4.7/debug/map.h
-#usr/include/c++/4.4.7/debug/multimap.h
-#usr/include/c++/4.4.7/debug/multiset.h
-#usr/include/c++/4.4.7/debug/safe_base.h
-#usr/include/c++/4.4.7/debug/safe_iterator.h
-#usr/include/c++/4.4.7/debug/safe_iterator.tcc
-#usr/include/c++/4.4.7/debug/safe_sequence.h
-#usr/include/c++/4.4.7/debug/set
-#usr/include/c++/4.4.7/debug/set.h
-#usr/include/c++/4.4.7/debug/string
-#usr/include/c++/4.4.7/debug/unordered_map
-#usr/include/c++/4.4.7/debug/unordered_set
-#usr/include/c++/4.4.7/debug/vector
-#usr/include/c++/4.4.7/deque
-#usr/include/c++/4.4.7/exception
-#usr/include/c++/4.4.7/exception_defines.h
-#usr/include/c++/4.4.7/exception_ptr.h
-#usr/include/c++/4.4.7/ext
-#usr/include/c++/4.4.7/ext/algorithm
-#usr/include/c++/4.4.7/ext/array_allocator.h
-#usr/include/c++/4.4.7/ext/atomicity.h
-#usr/include/c++/4.4.7/ext/bitmap_allocator.h
-#usr/include/c++/4.4.7/ext/cast.h
-#usr/include/c++/4.4.7/ext/codecvt_specializations.h
-#usr/include/c++/4.4.7/ext/concurrence.h
-#usr/include/c++/4.4.7/ext/debug_allocator.h
-#usr/include/c++/4.4.7/ext/enc_filebuf.h
-#usr/include/c++/4.4.7/ext/extptr_allocator.h
-#usr/include/c++/4.4.7/ext/functional
-#usr/include/c++/4.4.7/ext/hash_map
-#usr/include/c++/4.4.7/ext/hash_set
-#usr/include/c++/4.4.7/ext/iterator
-#usr/include/c++/4.4.7/ext/malloc_allocator.h
-#usr/include/c++/4.4.7/ext/memory
-#usr/include/c++/4.4.7/ext/mt_allocator.h
-#usr/include/c++/4.4.7/ext/new_allocator.h
-#usr/include/c++/4.4.7/ext/numeric
-#usr/include/c++/4.4.7/ext/numeric_traits.h
-#usr/include/c++/4.4.7/ext/pb_ds
-#usr/include/c++/4.4.7/ext/pb_ds/assoc_container.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail
-#usr/include/c++/4.4.7/ext/pb_ds/detail/basic_tree_policy
-#usr/include/c++/4.4.7/ext/pb_ds/detail/basic_tree_policy/basic_tree_policy_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/basic_tree_policy/null_node_metadata.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/basic_tree_policy/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/basic_types.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/bin_search_tree_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/cond_dtor_entry_dealtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/cond_key_dtor_entry_dealtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/node_iterators.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/point_iterators.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/r_erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/rotate_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/const_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/const_point_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/entry_cmp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/entry_pred.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/resize_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_/binomial_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/binomial_heap_base_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/cc_ht_map_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/cmp_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/cond_key_dtor_entry_dealtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/debug_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/debug_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/entry_list_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/erase_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/erase_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/find_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/insert_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/insert_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/resize_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/resize_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/resize_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/size_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/standard_policies.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cond_dealtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/container_base_dispatch.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/debug_map_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/eq_fn
-#usr/include/c++/4.4.7/ext/pb_ds/detail/eq_fn/eq_by_less.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/eq_fn/hash_eq_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/debug_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/debug_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/erase_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/erase_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/find_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/find_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/gp_ht_map_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/insert_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/insert_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/iterator_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/resize_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/resize_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/resize_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/standard_policies.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/direct_mask_range_hashing_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/direct_mod_range_hashing_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/linear_probe_fn_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/mask_based_range_hashing.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/mod_based_range_hashing.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/probe_fn_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/quadratic_probe_fn_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/ranged_hash_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/ranged_probe_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/sample_probe_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/sample_range_hashing.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/sample_ranged_hash_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/sample_ranged_probe_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/const_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/const_point_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/left_child_next_sibling_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/node.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/null_metadata.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/constructor_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/entry_metadata_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/lu_map_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_policy
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_policy/counter_lu_metadata.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_policy/counter_lu_policy_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_policy/mtf_lu_policy_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_policy/sample_update_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/cond_dtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/node_iterators.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/ov_tree_map_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/pairing_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/child_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/cond_dtor_entry_dealtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/const_child_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/head.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/insert_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/internal_node.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/leaf.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/node_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/node_iterators.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/node_metadata_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/pat_trie_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/point_iterators.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/r_erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/rotate_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/split_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/split_join_branch_bag.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/synth_e_access_traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/update_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/priority_queue_base_dispatch.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/node.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/rb_tree_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/rc.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/rc_binomial_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/cc_hash_max_collision_check_resize_trigger_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/hash_exponential_size_policy_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_size_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/hash_prime_size_policy_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/hash_standard_resize_policy_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/sample_resize_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/sample_resize_trigger.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/sample_size_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/node.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/splay_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/splay_tree_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/standard_policies.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/thin_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_policy
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_policy/node_metadata_selector.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_policy/null_node_update_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_policy/order_statistics_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_policy/sample_tree_node_update.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_trace_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/node_metadata_selector.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/null_node_update_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/order_statistics_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/prefix_search_node_update_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/sample_trie_e_access_traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/sample_trie_node_update.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/string_trie_e_access_traits_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/trie_policy_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/type_utils.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/types_traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/unordered_iterator
-#usr/include/c++/4.4.7/ext/pb_ds/detail/unordered_iterator/const_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/unordered_iterator/const_point_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/unordered_iterator/iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/unordered_iterator/point_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/exception.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/hash_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/list_update_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/priority_queue.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/tag_and_trait.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/tree_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/trie_policy.hpp
-#usr/include/c++/4.4.7/ext/pod_char_traits.h
-#usr/include/c++/4.4.7/ext/pointer.h
-#usr/include/c++/4.4.7/ext/pool_allocator.h
-#usr/include/c++/4.4.7/ext/rb_tree
-#usr/include/c++/4.4.7/ext/rc_string_base.h
-#usr/include/c++/4.4.7/ext/rope
-#usr/include/c++/4.4.7/ext/ropeimpl.h
-#usr/include/c++/4.4.7/ext/slist
-#usr/include/c++/4.4.7/ext/sso_string_base.h
-#usr/include/c++/4.4.7/ext/stdio_filebuf.h
-#usr/include/c++/4.4.7/ext/stdio_sync_filebuf.h
-#usr/include/c++/4.4.7/ext/string_conversions.h
-#usr/include/c++/4.4.7/ext/throw_allocator.h
-#usr/include/c++/4.4.7/ext/type_traits.h
-#usr/include/c++/4.4.7/ext/typelist.h
-#usr/include/c++/4.4.7/ext/vstring.h
-#usr/include/c++/4.4.7/ext/vstring.tcc
-#usr/include/c++/4.4.7/ext/vstring_fwd.h
-#usr/include/c++/4.4.7/ext/vstring_util.h
-#usr/include/c++/4.4.7/fenv.h
-#usr/include/c++/4.4.7/forward_list
-#usr/include/c++/4.4.7/fstream
-#usr/include/c++/4.4.7/functional
-#usr/include/c++/4.4.7/initializer_list
-#usr/include/c++/4.4.7/iomanip
-#usr/include/c++/4.4.7/ios
-#usr/include/c++/4.4.7/iosfwd
-#usr/include/c++/4.4.7/iostream
-#usr/include/c++/4.4.7/istream
-#usr/include/c++/4.4.7/iterator
-#usr/include/c++/4.4.7/limits
-#usr/include/c++/4.4.7/list
-#usr/include/c++/4.4.7/locale
-#usr/include/c++/4.4.7/map
-#usr/include/c++/4.4.7/memory
-#usr/include/c++/4.4.7/mutex
-#usr/include/c++/4.4.7/new
-#usr/include/c++/4.4.7/numeric
-#usr/include/c++/4.4.7/ostream
-#usr/include/c++/4.4.7/parallel
-#usr/include/c++/4.4.7/parallel/algo.h
-#usr/include/c++/4.4.7/parallel/algobase.h
-#usr/include/c++/4.4.7/parallel/algorithm
-#usr/include/c++/4.4.7/parallel/algorithmfwd.h
-#usr/include/c++/4.4.7/parallel/balanced_quicksort.h
-#usr/include/c++/4.4.7/parallel/base.h
-#usr/include/c++/4.4.7/parallel/basic_iterator.h
-#usr/include/c++/4.4.7/parallel/checkers.h
-#usr/include/c++/4.4.7/parallel/compatibility.h
-#usr/include/c++/4.4.7/parallel/compiletime_settings.h
-#usr/include/c++/4.4.7/parallel/equally_split.h
-#usr/include/c++/4.4.7/parallel/features.h
-#usr/include/c++/4.4.7/parallel/find.h
-#usr/include/c++/4.4.7/parallel/find_selectors.h
-#usr/include/c++/4.4.7/parallel/for_each.h
-#usr/include/c++/4.4.7/parallel/for_each_selectors.h
-#usr/include/c++/4.4.7/parallel/iterator.h
-#usr/include/c++/4.4.7/parallel/list_partition.h
-#usr/include/c++/4.4.7/parallel/losertree.h
-#usr/include/c++/4.4.7/parallel/merge.h
-#usr/include/c++/4.4.7/parallel/multiseq_selection.h
-#usr/include/c++/4.4.7/parallel/multiway_merge.h
-#usr/include/c++/4.4.7/parallel/multiway_mergesort.h
-#usr/include/c++/4.4.7/parallel/numeric
-#usr/include/c++/4.4.7/parallel/numericfwd.h
-#usr/include/c++/4.4.7/parallel/omp_loop.h
-#usr/include/c++/4.4.7/parallel/omp_loop_static.h
-#usr/include/c++/4.4.7/parallel/par_loop.h
-#usr/include/c++/4.4.7/parallel/parallel.h
-#usr/include/c++/4.4.7/parallel/partial_sum.h
-#usr/include/c++/4.4.7/parallel/partition.h
-#usr/include/c++/4.4.7/parallel/queue.h
-#usr/include/c++/4.4.7/parallel/quicksort.h
-#usr/include/c++/4.4.7/parallel/random_number.h
-#usr/include/c++/4.4.7/parallel/random_shuffle.h
-#usr/include/c++/4.4.7/parallel/search.h
-#usr/include/c++/4.4.7/parallel/set_operations.h
-#usr/include/c++/4.4.7/parallel/settings.h
-#usr/include/c++/4.4.7/parallel/sort.h
-#usr/include/c++/4.4.7/parallel/tags.h
-#usr/include/c++/4.4.7/parallel/types.h
-#usr/include/c++/4.4.7/parallel/unique_copy.h
-#usr/include/c++/4.4.7/parallel/workstealing.h
-#usr/include/c++/4.4.7/queue
-#usr/include/c++/4.4.7/random
-#usr/include/c++/4.4.7/ratio
-#usr/include/c++/4.4.7/regex
-#usr/include/c++/4.4.7/set
-#usr/include/c++/4.4.7/sstream
-#usr/include/c++/4.4.7/stack
-#usr/include/c++/4.4.7/stdatomic.h
-#usr/include/c++/4.4.7/stdexcept
-#usr/include/c++/4.4.7/streambuf
-#usr/include/c++/4.4.7/string
-#usr/include/c++/4.4.7/system_error
-#usr/include/c++/4.4.7/tgmath.h
-#usr/include/c++/4.4.7/thread
-#usr/include/c++/4.4.7/tr1
-#usr/include/c++/4.4.7/tr1/array
-#usr/include/c++/4.4.7/tr1/bessel_function.tcc
-#usr/include/c++/4.4.7/tr1/beta_function.tcc
-#usr/include/c++/4.4.7/tr1/ccomplex
-#usr/include/c++/4.4.7/tr1/cctype
-#usr/include/c++/4.4.7/tr1/cfenv
-#usr/include/c++/4.4.7/tr1/cfloat
-#usr/include/c++/4.4.7/tr1/cinttypes
-#usr/include/c++/4.4.7/tr1/climits
-#usr/include/c++/4.4.7/tr1/cmath
-#usr/include/c++/4.4.7/tr1/complex
-#usr/include/c++/4.4.7/tr1/complex.h
-#usr/include/c++/4.4.7/tr1/cstdarg
-#usr/include/c++/4.4.7/tr1/cstdbool
-#usr/include/c++/4.4.7/tr1/cstdint
-#usr/include/c++/4.4.7/tr1/cstdio
-#usr/include/c++/4.4.7/tr1/cstdlib
-#usr/include/c++/4.4.7/tr1/ctgmath
-#usr/include/c++/4.4.7/tr1/ctime
-#usr/include/c++/4.4.7/tr1/ctype.h
-#usr/include/c++/4.4.7/tr1/cwchar
-#usr/include/c++/4.4.7/tr1/cwctype
-#usr/include/c++/4.4.7/tr1/ell_integral.tcc
-#usr/include/c++/4.4.7/tr1/exp_integral.tcc
-#usr/include/c++/4.4.7/tr1/fenv.h
-#usr/include/c++/4.4.7/tr1/float.h
-#usr/include/c++/4.4.7/tr1/functional
-#usr/include/c++/4.4.7/tr1/functional_hash.h
-#usr/include/c++/4.4.7/tr1/gamma.tcc
-#usr/include/c++/4.4.7/tr1/hashtable.h
-#usr/include/c++/4.4.7/tr1/hypergeometric.tcc
-#usr/include/c++/4.4.7/tr1/inttypes.h
-#usr/include/c++/4.4.7/tr1/legendre_function.tcc
-#usr/include/c++/4.4.7/tr1/limits.h
-#usr/include/c++/4.4.7/tr1/math.h
-#usr/include/c++/4.4.7/tr1/memory
-#usr/include/c++/4.4.7/tr1/modified_bessel_func.tcc
-#usr/include/c++/4.4.7/tr1/poly_hermite.tcc
-#usr/include/c++/4.4.7/tr1/poly_laguerre.tcc
-#usr/include/c++/4.4.7/tr1/random
-#usr/include/c++/4.4.7/tr1/regex
-#usr/include/c++/4.4.7/tr1/riemann_zeta.tcc
-#usr/include/c++/4.4.7/tr1/shared_ptr.h
-#usr/include/c++/4.4.7/tr1/special_function_util.h
-#usr/include/c++/4.4.7/tr1/stdarg.h
-#usr/include/c++/4.4.7/tr1/stdbool.h
-#usr/include/c++/4.4.7/tr1/stdint.h
-#usr/include/c++/4.4.7/tr1/stdio.h
-#usr/include/c++/4.4.7/tr1/stdlib.h
-#usr/include/c++/4.4.7/tr1/tgmath.h
-#usr/include/c++/4.4.7/tr1/tuple
-#usr/include/c++/4.4.7/tr1/type_traits
-#usr/include/c++/4.4.7/tr1/unordered_map
-#usr/include/c++/4.4.7/tr1/unordered_set
-#usr/include/c++/4.4.7/tr1/utility
-#usr/include/c++/4.4.7/tr1/wchar.h
-#usr/include/c++/4.4.7/tr1/wctype.h
-#usr/include/c++/4.4.7/tr1_impl
-#usr/include/c++/4.4.7/tr1_impl/array
-#usr/include/c++/4.4.7/tr1_impl/boost_sp_counted_base.h
-#usr/include/c++/4.4.7/tr1_impl/cctype
-#usr/include/c++/4.4.7/tr1_impl/cfenv
-#usr/include/c++/4.4.7/tr1_impl/cinttypes
-#usr/include/c++/4.4.7/tr1_impl/cmath
-#usr/include/c++/4.4.7/tr1_impl/complex
-#usr/include/c++/4.4.7/tr1_impl/cstdint
-#usr/include/c++/4.4.7/tr1_impl/cstdio
-#usr/include/c++/4.4.7/tr1_impl/cstdlib
-#usr/include/c++/4.4.7/tr1_impl/cwchar
-#usr/include/c++/4.4.7/tr1_impl/cwctype
-#usr/include/c++/4.4.7/tr1_impl/functional
-#usr/include/c++/4.4.7/tr1_impl/functional_hash.h
-#usr/include/c++/4.4.7/tr1_impl/hashtable
-#usr/include/c++/4.4.7/tr1_impl/hashtable_policy.h
-#usr/include/c++/4.4.7/tr1_impl/random
-#usr/include/c++/4.4.7/tr1_impl/random.tcc
-#usr/include/c++/4.4.7/tr1_impl/regex
-#usr/include/c++/4.4.7/tr1_impl/type_traits
-#usr/include/c++/4.4.7/tr1_impl/unordered_map
-#usr/include/c++/4.4.7/tr1_impl/unordered_set
-#usr/include/c++/4.4.7/tr1_impl/utility
-#usr/include/c++/4.4.7/tuple
-#usr/include/c++/4.4.7/type_traits
-#usr/include/c++/4.4.7/typeinfo
-#usr/include/c++/4.4.7/unordered_map
-#usr/include/c++/4.4.7/unordered_set
-#usr/include/c++/4.4.7/utility
-#usr/include/c++/4.4.7/valarray
-#usr/include/c++/4.4.7/vector
-#usr/info
-#usr/info/cpp.info
-#usr/info/cppinternals.info
-#usr/info/dir
-#usr/info/gcc.info
-#usr/info/gccinstall.info
-#usr/info/gccint.info
-#usr/info/libgomp.info
+#usr/include/c++/4.9.3
+#usr/include/c++/4.9.3/algorithm
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/atomic_word.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/basic_file.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/c++allocator.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/c++config.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/c++io.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/c++locale.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/cpu_defines.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/ctype_base.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/ctype_inline.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/cxxabi_tweaks.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/error_constants.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/extc++.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/gthr-default.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/gthr-posix.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/gthr-single.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/gthr.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/messages_members.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/opt_random.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/os_defines.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/stdc++.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/stdtr1c++.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/bits/time_members.h
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/ext
+#usr/include/c++/4.9.3/armv5tel-unknown-linux-gnueabi/ext/opt_random.h
+#usr/include/c++/4.9.3/array
+#usr/include/c++/4.9.3/atomic
+#usr/include/c++/4.9.3/backward
+#usr/include/c++/4.9.3/backward/auto_ptr.h
+#usr/include/c++/4.9.3/backward/backward_warning.h
+#usr/include/c++/4.9.3/backward/binders.h
+#usr/include/c++/4.9.3/backward/hash_fun.h
+#usr/include/c++/4.9.3/backward/hash_map
+#usr/include/c++/4.9.3/backward/hash_set
+#usr/include/c++/4.9.3/backward/hashtable.h
+#usr/include/c++/4.9.3/backward/strstream
+#usr/include/c++/4.9.3/bits
+#usr/include/c++/4.9.3/bits/algorithmfwd.h
+#usr/include/c++/4.9.3/bits/alloc_traits.h
+#usr/include/c++/4.9.3/bits/allocator.h
+#usr/include/c++/4.9.3/bits/atomic_base.h
+#usr/include/c++/4.9.3/bits/atomic_lockfree_defines.h
+#usr/include/c++/4.9.3/bits/basic_ios.h
+#usr/include/c++/4.9.3/bits/basic_ios.tcc
+#usr/include/c++/4.9.3/bits/basic_string.h
+#usr/include/c++/4.9.3/bits/basic_string.tcc
+#usr/include/c++/4.9.3/bits/boost_concept_check.h
+#usr/include/c++/4.9.3/bits/c++0x_warning.h
+#usr/include/c++/4.9.3/bits/c++14_warning.h
+#usr/include/c++/4.9.3/bits/char_traits.h
+#usr/include/c++/4.9.3/bits/codecvt.h
+#usr/include/c++/4.9.3/bits/concept_check.h
+#usr/include/c++/4.9.3/bits/cpp_type_traits.h
+#usr/include/c++/4.9.3/bits/cxxabi_forced.h
+#usr/include/c++/4.9.3/bits/deque.tcc
+#usr/include/c++/4.9.3/bits/enable_special_members.h
+#usr/include/c++/4.9.3/bits/exception_defines.h
+#usr/include/c++/4.9.3/bits/exception_ptr.h
+#usr/include/c++/4.9.3/bits/forward_list.h
+#usr/include/c++/4.9.3/bits/forward_list.tcc
+#usr/include/c++/4.9.3/bits/fstream.tcc
+#usr/include/c++/4.9.3/bits/functexcept.h
+#usr/include/c++/4.9.3/bits/functional_hash.h
+#usr/include/c++/4.9.3/bits/gslice.h
+#usr/include/c++/4.9.3/bits/gslice_array.h
+#usr/include/c++/4.9.3/bits/hash_bytes.h
+#usr/include/c++/4.9.3/bits/hashtable.h
+#usr/include/c++/4.9.3/bits/hashtable_policy.h
+#usr/include/c++/4.9.3/bits/indirect_array.h
+#usr/include/c++/4.9.3/bits/ios_base.h
+#usr/include/c++/4.9.3/bits/istream.tcc
+#usr/include/c++/4.9.3/bits/list.tcc
+#usr/include/c++/4.9.3/bits/locale_classes.h
+#usr/include/c++/4.9.3/bits/locale_classes.tcc
+#usr/include/c++/4.9.3/bits/locale_facets.h
+#usr/include/c++/4.9.3/bits/locale_facets.tcc
+#usr/include/c++/4.9.3/bits/locale_facets_nonio.h
+#usr/include/c++/4.9.3/bits/locale_facets_nonio.tcc
+#usr/include/c++/4.9.3/bits/localefwd.h
+#usr/include/c++/4.9.3/bits/mask_array.h
+#usr/include/c++/4.9.3/bits/memoryfwd.h
+#usr/include/c++/4.9.3/bits/move.h
+#usr/include/c++/4.9.3/bits/nested_exception.h
+#usr/include/c++/4.9.3/bits/ostream.tcc
+#usr/include/c++/4.9.3/bits/ostream_insert.h
+#usr/include/c++/4.9.3/bits/parse_numbers.h
+#usr/include/c++/4.9.3/bits/postypes.h
+#usr/include/c++/4.9.3/bits/predefined_ops.h
+#usr/include/c++/4.9.3/bits/ptr_traits.h
+#usr/include/c++/4.9.3/bits/random.h
+#usr/include/c++/4.9.3/bits/random.tcc
+#usr/include/c++/4.9.3/bits/range_access.h
+#usr/include/c++/4.9.3/bits/regex.h
+#usr/include/c++/4.9.3/bits/regex.tcc
+#usr/include/c++/4.9.3/bits/regex_automaton.h
+#usr/include/c++/4.9.3/bits/regex_automaton.tcc
+#usr/include/c++/4.9.3/bits/regex_compiler.h
+#usr/include/c++/4.9.3/bits/regex_compiler.tcc
+#usr/include/c++/4.9.3/bits/regex_constants.h
+#usr/include/c++/4.9.3/bits/regex_error.h
+#usr/include/c++/4.9.3/bits/regex_executor.h
+#usr/include/c++/4.9.3/bits/regex_executor.tcc
+#usr/include/c++/4.9.3/bits/regex_scanner.h
+#usr/include/c++/4.9.3/bits/regex_scanner.tcc
+#usr/include/c++/4.9.3/bits/shared_ptr.h
+#usr/include/c++/4.9.3/bits/shared_ptr_base.h
+#usr/include/c++/4.9.3/bits/slice_array.h
+#usr/include/c++/4.9.3/bits/sstream.tcc
+#usr/include/c++/4.9.3/bits/stl_algo.h
+#usr/include/c++/4.9.3/bits/stl_algobase.h
+#usr/include/c++/4.9.3/bits/stl_bvector.h
+#usr/include/c++/4.9.3/bits/stl_construct.h
+#usr/include/c++/4.9.3/bits/stl_deque.h
+#usr/include/c++/4.9.3/bits/stl_function.h
+#usr/include/c++/4.9.3/bits/stl_heap.h
+#usr/include/c++/4.9.3/bits/stl_iterator.h
+#usr/include/c++/4.9.3/bits/stl_iterator_base_funcs.h
+#usr/include/c++/4.9.3/bits/stl_iterator_base_types.h
+#usr/include/c++/4.9.3/bits/stl_list.h
+#usr/include/c++/4.9.3/bits/stl_map.h
+#usr/include/c++/4.9.3/bits/stl_multimap.h
+#usr/include/c++/4.9.3/bits/stl_multiset.h
+#usr/include/c++/4.9.3/bits/stl_numeric.h
+#usr/include/c++/4.9.3/bits/stl_pair.h
+#usr/include/c++/4.9.3/bits/stl_queue.h
+#usr/include/c++/4.9.3/bits/stl_raw_storage_iter.h
+#usr/include/c++/4.9.3/bits/stl_relops.h
+#usr/include/c++/4.9.3/bits/stl_set.h
+#usr/include/c++/4.9.3/bits/stl_stack.h
+#usr/include/c++/4.9.3/bits/stl_tempbuf.h
+#usr/include/c++/4.9.3/bits/stl_tree.h
+#usr/include/c++/4.9.3/bits/stl_uninitialized.h
+#usr/include/c++/4.9.3/bits/stl_vector.h
+#usr/include/c++/4.9.3/bits/stream_iterator.h
+#usr/include/c++/4.9.3/bits/streambuf.tcc
+#usr/include/c++/4.9.3/bits/streambuf_iterator.h
+#usr/include/c++/4.9.3/bits/stringfwd.h
+#usr/include/c++/4.9.3/bits/unique_ptr.h
+#usr/include/c++/4.9.3/bits/unordered_map.h
+#usr/include/c++/4.9.3/bits/unordered_set.h
+#usr/include/c++/4.9.3/bits/uses_allocator.h
+#usr/include/c++/4.9.3/bits/valarray_after.h
+#usr/include/c++/4.9.3/bits/valarray_array.h
+#usr/include/c++/4.9.3/bits/valarray_array.tcc
+#usr/include/c++/4.9.3/bits/valarray_before.h
+#usr/include/c++/4.9.3/bits/vector.tcc
+#usr/include/c++/4.9.3/bitset
+#usr/include/c++/4.9.3/cassert
+#usr/include/c++/4.9.3/ccomplex
+#usr/include/c++/4.9.3/cctype
+#usr/include/c++/4.9.3/cerrno
+#usr/include/c++/4.9.3/cfenv
+#usr/include/c++/4.9.3/cfloat
+#usr/include/c++/4.9.3/chrono
+#usr/include/c++/4.9.3/cinttypes
+#usr/include/c++/4.9.3/ciso646
+#usr/include/c++/4.9.3/climits
+#usr/include/c++/4.9.3/clocale
+#usr/include/c++/4.9.3/cmath
+#usr/include/c++/4.9.3/complex
+#usr/include/c++/4.9.3/complex.h
+#usr/include/c++/4.9.3/condition_variable
+#usr/include/c++/4.9.3/csetjmp
+#usr/include/c++/4.9.3/csignal
+#usr/include/c++/4.9.3/cstdalign
+#usr/include/c++/4.9.3/cstdarg
+#usr/include/c++/4.9.3/cstdbool
+#usr/include/c++/4.9.3/cstddef
+#usr/include/c++/4.9.3/cstdint
+#usr/include/c++/4.9.3/cstdio
+#usr/include/c++/4.9.3/cstdlib
+#usr/include/c++/4.9.3/cstring
+#usr/include/c++/4.9.3/ctgmath
+#usr/include/c++/4.9.3/ctime
+#usr/include/c++/4.9.3/cwchar
+#usr/include/c++/4.9.3/cwctype
+#usr/include/c++/4.9.3/cxxabi.h
+#usr/include/c++/4.9.3/debug
+#usr/include/c++/4.9.3/debug/array
+#usr/include/c++/4.9.3/debug/bitset
+#usr/include/c++/4.9.3/debug/debug.h
+#usr/include/c++/4.9.3/debug/deque
+#usr/include/c++/4.9.3/debug/formatter.h
+#usr/include/c++/4.9.3/debug/forward_list
+#usr/include/c++/4.9.3/debug/functions.h
+#usr/include/c++/4.9.3/debug/list
+#usr/include/c++/4.9.3/debug/macros.h
+#usr/include/c++/4.9.3/debug/map
+#usr/include/c++/4.9.3/debug/map.h
+#usr/include/c++/4.9.3/debug/multimap.h
+#usr/include/c++/4.9.3/debug/multiset.h
+#usr/include/c++/4.9.3/debug/safe_base.h
+#usr/include/c++/4.9.3/debug/safe_iterator.h
+#usr/include/c++/4.9.3/debug/safe_iterator.tcc
+#usr/include/c++/4.9.3/debug/safe_local_iterator.h
+#usr/include/c++/4.9.3/debug/safe_local_iterator.tcc
+#usr/include/c++/4.9.3/debug/safe_sequence.h
+#usr/include/c++/4.9.3/debug/safe_sequence.tcc
+#usr/include/c++/4.9.3/debug/safe_unordered_base.h
+#usr/include/c++/4.9.3/debug/safe_unordered_container.h
+#usr/include/c++/4.9.3/debug/safe_unordered_container.tcc
+#usr/include/c++/4.9.3/debug/set
+#usr/include/c++/4.9.3/debug/set.h
+#usr/include/c++/4.9.3/debug/string
+#usr/include/c++/4.9.3/debug/unordered_map
+#usr/include/c++/4.9.3/debug/unordered_set
+#usr/include/c++/4.9.3/debug/vector
+#usr/include/c++/4.9.3/decimal
+#usr/include/c++/4.9.3/decimal/decimal
+#usr/include/c++/4.9.3/decimal/decimal.h
+#usr/include/c++/4.9.3/deque
+#usr/include/c++/4.9.3/exception
+#usr/include/c++/4.9.3/experimental
+#usr/include/c++/4.9.3/experimental/optional
+#usr/include/c++/4.9.3/experimental/string_view
+#usr/include/c++/4.9.3/experimental/string_view.tcc
+#usr/include/c++/4.9.3/ext
+#usr/include/c++/4.9.3/ext/algorithm
+#usr/include/c++/4.9.3/ext/aligned_buffer.h
+#usr/include/c++/4.9.3/ext/alloc_traits.h
+#usr/include/c++/4.9.3/ext/array_allocator.h
+#usr/include/c++/4.9.3/ext/atomicity.h
+#usr/include/c++/4.9.3/ext/bitmap_allocator.h
+#usr/include/c++/4.9.3/ext/cast.h
+#usr/include/c++/4.9.3/ext/cmath
+#usr/include/c++/4.9.3/ext/codecvt_specializations.h
+#usr/include/c++/4.9.3/ext/concurrence.h
+#usr/include/c++/4.9.3/ext/debug_allocator.h
+#usr/include/c++/4.9.3/ext/enc_filebuf.h
+#usr/include/c++/4.9.3/ext/extptr_allocator.h
+#usr/include/c++/4.9.3/ext/functional
+#usr/include/c++/4.9.3/ext/hash_map
+#usr/include/c++/4.9.3/ext/hash_set
+#usr/include/c++/4.9.3/ext/iterator
+#usr/include/c++/4.9.3/ext/malloc_allocator.h
+#usr/include/c++/4.9.3/ext/memory
+#usr/include/c++/4.9.3/ext/mt_allocator.h
+#usr/include/c++/4.9.3/ext/new_allocator.h
+#usr/include/c++/4.9.3/ext/numeric
+#usr/include/c++/4.9.3/ext/numeric_traits.h
+#usr/include/c++/4.9.3/ext/pb_ds
+#usr/include/c++/4.9.3/ext/pb_ds/assoc_container.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/bin_search_tree_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/node_iterators.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/point_iterators.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/r_erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/rotate_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/entry_cmp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/entry_pred.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/point_const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/resize_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_/binomial_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/binomial_heap_base_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/branch_policy
+#usr/include/c++/4.9.3/ext/pb_ds/detail/branch_policy/branch_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/branch_policy/null_node_metadata.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/branch_policy/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/cc_ht_map_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/cmp_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/cond_key_dtor_entry_dealtor.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/debug_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/debug_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/entry_list_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/erase_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/erase_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/find_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/insert_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/insert_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/resize_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/resize_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/resize_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/size_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cond_dealtor.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/container_base_dispatch.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/debug_map_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/eq_fn
+#usr/include/c++/4.9.3/ext/pb_ds/detail/eq_fn/eq_by_less.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/eq_fn/hash_eq_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/debug_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/debug_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/erase_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/erase_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/find_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/find_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/gp_ht_map_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/insert_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/insert_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/iterator_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/resize_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/resize_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/resize_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/direct_mask_range_hashing_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/direct_mod_range_hashing_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/linear_probe_fn_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/mask_based_range_hashing.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/mod_based_range_hashing.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/probe_fn_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/quadratic_probe_fn_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/ranged_hash_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/ranged_probe_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/sample_probe_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/sample_range_hashing.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/sample_ranged_hash_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/sample_ranged_probe_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/left_child_next_sibling_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/node.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/point_const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/constructor_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/entry_metadata_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/lu_map_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_policy
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_policy/lu_counter_metadata.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_policy/sample_update_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/node_iterators.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/ov_tree_map_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/pairing_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/insert_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/pat_trie_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/pat_trie_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/r_erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/rotate_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/split_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/synth_access_traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/update_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/priority_queue_base_dispatch.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/node.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/rb_tree_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/rc.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/rc_binomial_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/cc_hash_max_collision_check_resize_trigger_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/hash_exponential_size_policy_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_size_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/hash_prime_size_policy_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/hash_standard_resize_policy_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/sample_resize_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/sample_resize_trigger.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/sample_size_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/node.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/splay_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/splay_tree_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/standard_policies.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/thin_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/tree_policy
+#usr/include/c++/4.9.3/ext/pb_ds/detail/tree_policy/node_metadata_selector.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/tree_policy/order_statistics_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/tree_policy/sample_tree_node_update.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/tree_trace_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/node_metadata_selector.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/order_statistics_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/prefix_search_node_update_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/sample_trie_access_traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/sample_trie_node_update.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/trie_policy_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/trie_string_access_traits_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/type_utils.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/types_traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/unordered_iterator
+#usr/include/c++/4.9.3/ext/pb_ds/detail/unordered_iterator/const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/unordered_iterator/iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/unordered_iterator/point_const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/unordered_iterator/point_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/exception.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/hash_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/list_update_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/priority_queue.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/tag_and_trait.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/tree_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/trie_policy.hpp
+#usr/include/c++/4.9.3/ext/pod_char_traits.h
+#usr/include/c++/4.9.3/ext/pointer.h
+#usr/include/c++/4.9.3/ext/pool_allocator.h
+#usr/include/c++/4.9.3/ext/random
+#usr/include/c++/4.9.3/ext/random.tcc
+#usr/include/c++/4.9.3/ext/rb_tree
+#usr/include/c++/4.9.3/ext/rc_string_base.h
+#usr/include/c++/4.9.3/ext/rope
+#usr/include/c++/4.9.3/ext/ropeimpl.h
+#usr/include/c++/4.9.3/ext/slist
+#usr/include/c++/4.9.3/ext/sso_string_base.h
+#usr/include/c++/4.9.3/ext/stdio_filebuf.h
+#usr/include/c++/4.9.3/ext/stdio_sync_filebuf.h
+#usr/include/c++/4.9.3/ext/string_conversions.h
+#usr/include/c++/4.9.3/ext/throw_allocator.h
+#usr/include/c++/4.9.3/ext/type_traits.h
+#usr/include/c++/4.9.3/ext/typelist.h
+#usr/include/c++/4.9.3/ext/vstring.h
+#usr/include/c++/4.9.3/ext/vstring.tcc
+#usr/include/c++/4.9.3/ext/vstring_fwd.h
+#usr/include/c++/4.9.3/ext/vstring_util.h
+#usr/include/c++/4.9.3/fenv.h
+#usr/include/c++/4.9.3/forward_list
+#usr/include/c++/4.9.3/fstream
+#usr/include/c++/4.9.3/functional
+#usr/include/c++/4.9.3/future
+#usr/include/c++/4.9.3/initializer_list
+#usr/include/c++/4.9.3/iomanip
+#usr/include/c++/4.9.3/ios
+#usr/include/c++/4.9.3/iosfwd
+#usr/include/c++/4.9.3/iostream
+#usr/include/c++/4.9.3/istream
+#usr/include/c++/4.9.3/iterator
+#usr/include/c++/4.9.3/limits
+#usr/include/c++/4.9.3/list
+#usr/include/c++/4.9.3/locale
+#usr/include/c++/4.9.3/map
+#usr/include/c++/4.9.3/memory
+#usr/include/c++/4.9.3/mutex
+#usr/include/c++/4.9.3/new
+#usr/include/c++/4.9.3/numeric
+#usr/include/c++/4.9.3/ostream
+#usr/include/c++/4.9.3/parallel
+#usr/include/c++/4.9.3/parallel/algo.h
+#usr/include/c++/4.9.3/parallel/algobase.h
+#usr/include/c++/4.9.3/parallel/algorithm
+#usr/include/c++/4.9.3/parallel/algorithmfwd.h
+#usr/include/c++/4.9.3/parallel/balanced_quicksort.h
+#usr/include/c++/4.9.3/parallel/base.h
+#usr/include/c++/4.9.3/parallel/basic_iterator.h
+#usr/include/c++/4.9.3/parallel/checkers.h
+#usr/include/c++/4.9.3/parallel/compatibility.h
+#usr/include/c++/4.9.3/parallel/compiletime_settings.h
+#usr/include/c++/4.9.3/parallel/equally_split.h
+#usr/include/c++/4.9.3/parallel/features.h
+#usr/include/c++/4.9.3/parallel/find.h
+#usr/include/c++/4.9.3/parallel/find_selectors.h
+#usr/include/c++/4.9.3/parallel/for_each.h
+#usr/include/c++/4.9.3/parallel/for_each_selectors.h
+#usr/include/c++/4.9.3/parallel/iterator.h
+#usr/include/c++/4.9.3/parallel/list_partition.h
+#usr/include/c++/4.9.3/parallel/losertree.h
+#usr/include/c++/4.9.3/parallel/merge.h
+#usr/include/c++/4.9.3/parallel/multiseq_selection.h
+#usr/include/c++/4.9.3/parallel/multiway_merge.h
+#usr/include/c++/4.9.3/parallel/multiway_mergesort.h
+#usr/include/c++/4.9.3/parallel/numeric
+#usr/include/c++/4.9.3/parallel/numericfwd.h
+#usr/include/c++/4.9.3/parallel/omp_loop.h
+#usr/include/c++/4.9.3/parallel/omp_loop_static.h
+#usr/include/c++/4.9.3/parallel/par_loop.h
+#usr/include/c++/4.9.3/parallel/parallel.h
+#usr/include/c++/4.9.3/parallel/partial_sum.h
+#usr/include/c++/4.9.3/parallel/partition.h
+#usr/include/c++/4.9.3/parallel/queue.h
+#usr/include/c++/4.9.3/parallel/quicksort.h
+#usr/include/c++/4.9.3/parallel/random_number.h
+#usr/include/c++/4.9.3/parallel/random_shuffle.h
+#usr/include/c++/4.9.3/parallel/search.h
+#usr/include/c++/4.9.3/parallel/set_operations.h
+#usr/include/c++/4.9.3/parallel/settings.h
+#usr/include/c++/4.9.3/parallel/sort.h
+#usr/include/c++/4.9.3/parallel/tags.h
+#usr/include/c++/4.9.3/parallel/types.h
+#usr/include/c++/4.9.3/parallel/unique_copy.h
+#usr/include/c++/4.9.3/parallel/workstealing.h
+#usr/include/c++/4.9.3/profile
+#usr/include/c++/4.9.3/profile/array
+#usr/include/c++/4.9.3/profile/base.h
+#usr/include/c++/4.9.3/profile/bitset
+#usr/include/c++/4.9.3/profile/deque
+#usr/include/c++/4.9.3/profile/forward_list
+#usr/include/c++/4.9.3/profile/impl
+#usr/include/c++/4.9.3/profile/impl/profiler.h
+#usr/include/c++/4.9.3/profile/impl/profiler_algos.h
+#usr/include/c++/4.9.3/profile/impl/profiler_container_size.h
+#usr/include/c++/4.9.3/profile/impl/profiler_hash_func.h
+#usr/include/c++/4.9.3/profile/impl/profiler_hashtable_size.h
+#usr/include/c++/4.9.3/profile/impl/profiler_list_to_slist.h
+#usr/include/c++/4.9.3/profile/impl/profiler_list_to_vector.h
+#usr/include/c++/4.9.3/profile/impl/profiler_map_to_unordered_map.h
+#usr/include/c++/4.9.3/profile/impl/profiler_node.h
+#usr/include/c++/4.9.3/profile/impl/profiler_state.h
+#usr/include/c++/4.9.3/profile/impl/profiler_trace.h
+#usr/include/c++/4.9.3/profile/impl/profiler_vector_size.h
+#usr/include/c++/4.9.3/profile/impl/profiler_vector_to_list.h
+#usr/include/c++/4.9.3/profile/iterator_tracker.h
+#usr/include/c++/4.9.3/profile/list
+#usr/include/c++/4.9.3/profile/map
+#usr/include/c++/4.9.3/profile/map.h
+#usr/include/c++/4.9.3/profile/multimap.h
+#usr/include/c++/4.9.3/profile/multiset.h
+#usr/include/c++/4.9.3/profile/set
+#usr/include/c++/4.9.3/profile/set.h
+#usr/include/c++/4.9.3/profile/unordered_base.h
+#usr/include/c++/4.9.3/profile/unordered_map
+#usr/include/c++/4.9.3/profile/unordered_set
+#usr/include/c++/4.9.3/profile/vector
+#usr/include/c++/4.9.3/queue
+#usr/include/c++/4.9.3/random
+#usr/include/c++/4.9.3/ratio
+#usr/include/c++/4.9.3/regex
+#usr/include/c++/4.9.3/scoped_allocator
+#usr/include/c++/4.9.3/set
+#usr/include/c++/4.9.3/shared_mutex
+#usr/include/c++/4.9.3/sstream
+#usr/include/c++/4.9.3/stack
+#usr/include/c++/4.9.3/stdexcept
+#usr/include/c++/4.9.3/streambuf
+#usr/include/c++/4.9.3/string
+#usr/include/c++/4.9.3/system_error
+#usr/include/c++/4.9.3/tgmath.h
+#usr/include/c++/4.9.3/thread
+#usr/include/c++/4.9.3/tr1
+#usr/include/c++/4.9.3/tr1/array
+#usr/include/c++/4.9.3/tr1/bessel_function.tcc
+#usr/include/c++/4.9.3/tr1/beta_function.tcc
+#usr/include/c++/4.9.3/tr1/ccomplex
+#usr/include/c++/4.9.3/tr1/cctype
+#usr/include/c++/4.9.3/tr1/cfenv
+#usr/include/c++/4.9.3/tr1/cfloat
+#usr/include/c++/4.9.3/tr1/cinttypes
+#usr/include/c++/4.9.3/tr1/climits
+#usr/include/c++/4.9.3/tr1/cmath
+#usr/include/c++/4.9.3/tr1/complex
+#usr/include/c++/4.9.3/tr1/complex.h
+#usr/include/c++/4.9.3/tr1/cstdarg
+#usr/include/c++/4.9.3/tr1/cstdbool
+#usr/include/c++/4.9.3/tr1/cstdint
+#usr/include/c++/4.9.3/tr1/cstdio
+#usr/include/c++/4.9.3/tr1/cstdlib
+#usr/include/c++/4.9.3/tr1/ctgmath
+#usr/include/c++/4.9.3/tr1/ctime
+#usr/include/c++/4.9.3/tr1/ctype.h
+#usr/include/c++/4.9.3/tr1/cwchar
+#usr/include/c++/4.9.3/tr1/cwctype
+#usr/include/c++/4.9.3/tr1/ell_integral.tcc
+#usr/include/c++/4.9.3/tr1/exp_integral.tcc
+#usr/include/c++/4.9.3/tr1/fenv.h
+#usr/include/c++/4.9.3/tr1/float.h
+#usr/include/c++/4.9.3/tr1/functional
+#usr/include/c++/4.9.3/tr1/functional_hash.h
+#usr/include/c++/4.9.3/tr1/gamma.tcc
+#usr/include/c++/4.9.3/tr1/hashtable.h
+#usr/include/c++/4.9.3/tr1/hashtable_policy.h
+#usr/include/c++/4.9.3/tr1/hypergeometric.tcc
+#usr/include/c++/4.9.3/tr1/inttypes.h
+#usr/include/c++/4.9.3/tr1/legendre_function.tcc
+#usr/include/c++/4.9.3/tr1/limits.h
+#usr/include/c++/4.9.3/tr1/math.h
+#usr/include/c++/4.9.3/tr1/memory
+#usr/include/c++/4.9.3/tr1/modified_bessel_func.tcc
+#usr/include/c++/4.9.3/tr1/poly_hermite.tcc
+#usr/include/c++/4.9.3/tr1/poly_laguerre.tcc
+#usr/include/c++/4.9.3/tr1/random
+#usr/include/c++/4.9.3/tr1/random.h
+#usr/include/c++/4.9.3/tr1/random.tcc
+#usr/include/c++/4.9.3/tr1/regex
+#usr/include/c++/4.9.3/tr1/riemann_zeta.tcc
+#usr/include/c++/4.9.3/tr1/shared_ptr.h
+#usr/include/c++/4.9.3/tr1/special_function_util.h
+#usr/include/c++/4.9.3/tr1/stdarg.h
+#usr/include/c++/4.9.3/tr1/stdbool.h
+#usr/include/c++/4.9.3/tr1/stdint.h
+#usr/include/c++/4.9.3/tr1/stdio.h
+#usr/include/c++/4.9.3/tr1/stdlib.h
+#usr/include/c++/4.9.3/tr1/tgmath.h
+#usr/include/c++/4.9.3/tr1/tuple
+#usr/include/c++/4.9.3/tr1/type_traits
+#usr/include/c++/4.9.3/tr1/unordered_map
+#usr/include/c++/4.9.3/tr1/unordered_map.h
+#usr/include/c++/4.9.3/tr1/unordered_set
+#usr/include/c++/4.9.3/tr1/unordered_set.h
+#usr/include/c++/4.9.3/tr1/utility
+#usr/include/c++/4.9.3/tr1/wchar.h
+#usr/include/c++/4.9.3/tr1/wctype.h
+#usr/include/c++/4.9.3/tr2
+#usr/include/c++/4.9.3/tr2/bool_set
+#usr/include/c++/4.9.3/tr2/bool_set.tcc
+#usr/include/c++/4.9.3/tr2/dynamic_bitset
+#usr/include/c++/4.9.3/tr2/dynamic_bitset.tcc
+#usr/include/c++/4.9.3/tr2/ratio
+#usr/include/c++/4.9.3/tr2/type_traits
+#usr/include/c++/4.9.3/tuple
+#usr/include/c++/4.9.3/type_traits
+#usr/include/c++/4.9.3/typeindex
+#usr/include/c++/4.9.3/typeinfo
+#usr/include/c++/4.9.3/unordered_map
+#usr/include/c++/4.9.3/unordered_set
+#usr/include/c++/4.9.3/utility
+#usr/include/c++/4.9.3/valarray
+#usr/include/c++/4.9.3/vector
#usr/lib/gcc
#usr/lib/gcc/armv5tel-unknown-linux-gnueabi
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/cc1
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/cc1plus
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/collect2
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/crtbegin.o
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/crtbeginS.o
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/crtbeginT.o
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/crtend.o
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/crtendS.o
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/finclude
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include-fixed
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include-fixed/README
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include-fixed/limits.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include-fixed/syslimits.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/arm_neon.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/float.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/iso646.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/mf-runtime.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/mmintrin.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/omp.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/ssp
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/ssp/ssp.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/ssp/stdio.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/ssp/string.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/ssp/unistd.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/stdarg.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/stdbool.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/stddef.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/stdfix.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/unwind.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/include/varargs.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/install-tools
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/install-tools/fixinc.sh
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/install-tools/fixinc_list
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/install-tools/fixincl
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/install-tools/gsyslimits.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/install-tools/include
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/install-tools/include/README
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/install-tools/include/limits.h
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/install-tools/macro_list
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/install-tools/mkheaders
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/install-tools/mkheaders.conf
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/install-tools/mkinstalldirs
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/libgcc.a
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/libgcc_eh.a
-#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.4.7/libgcov.a
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/cc1
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/cc1plus
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/collect2
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/crtbegin.o
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/crtbeginS.o
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/crtbeginT.o
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/crtend.o
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/crtendS.o
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/finclude
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include-fixed
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include-fixed/README
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include-fixed/limits.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include-fixed/syslimits.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/arm_acle.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/arm_neon.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/float.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/iso646.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/mmintrin.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/omp.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/sanitizer
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/sanitizer/asan_interface.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/sanitizer/common_interface_defs.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/sanitizer/lsan_interface.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/ssp
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/ssp/ssp.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/ssp/stdio.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/ssp/string.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/ssp/unistd.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/stdalign.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/stdarg.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/stdatomic.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/stdbool.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/stddef.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/stdfix.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/stdint-gcc.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/stdint.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/stdnoreturn.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/unwind-arm-common.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/unwind.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/include/varargs.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/install-tools
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/install-tools/fixinc.sh
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/install-tools/fixinc_list
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/install-tools/fixincl
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/install-tools/gsyslimits.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/install-tools/include
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/install-tools/include/README
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/install-tools/include/limits.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/install-tools/macro_list
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/install-tools/mkheaders
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/install-tools/mkheaders.conf
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/install-tools/mkinstalldirs
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/libgcc.a
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/libgcc_eh.a
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/libgcov.a
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/liblto_plugin.la
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/liblto_plugin.so
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/liblto_plugin.so.0
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/liblto_plugin.so.0.0.0
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/lto-wrapper
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/lto1
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/gengtype
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/gtype.state
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/ada
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/ada/gcc-interface
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/ada/gcc-interface/ada-tree.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/alias.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/all-tree.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/alloc-pool.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/ansidecl.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/attribs.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/auto-host.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/b-header-vars
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/basic-block.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/bitmap.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/builtins.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/bversion.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/c-family
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/c-family/c-common.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/c-family/c-common.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/c-family/c-objc.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/c-family/c-pragma.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/c-family/c-pretty-print.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/c-tree.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/calls.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cfg-flags.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cfgexpand.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cfghooks.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cfgloop.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cgraph.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cif-code.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cilk-builtins.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cilkplus.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/arm
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/arm/aarch-common-protos.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/arm/aout.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/arm/arm-cores.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/arm/arm-opts.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/arm/arm-protos.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/arm/arm.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/arm/bpabi.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/arm/elf.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/arm/linux-eabi.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/arm/linux-elf.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/arm/linux-gas.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/dbxelf.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/elfos.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/glibc-stdint.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/gnu-user.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/initfini-array.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/linux-android.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/linux-protos.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/linux.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/config/vxworks-dummy.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/configargs.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/context.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/coretypes.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cp
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cp/cp-tree.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cp/cp-tree.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cp/cxx-pretty-print.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cp/name-lookup.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cp/type-utils.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cppdefault.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/cpplib.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/debug.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/defaults.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/df.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/diagnostic-color.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/diagnostic-core.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/diagnostic.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/diagnostic.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/double-int.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/dumpfile.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/emit-rtl.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/except.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/filenames.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/fixed-value.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/flag-types.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/flags.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/fold-const.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/function.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gcc-plugin.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gcc-symtab.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/genrtl.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/ggc.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gimple-builder.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gimple-expr.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gimple-fold.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gimple-iterator.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gimple-low.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gimple-pretty-print.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gimple-ssa.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gimple-walk.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gimple.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gimple.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gimplify-me.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gimplify.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gsstruct.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gtm-builtins.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/gtype-desc.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/hard-reg-set.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/hash-table.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/hashtab.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/highlev-plugin-common.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/hwint.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/incpath.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/input.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/insn-codes.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/insn-constants.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/insn-flags.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/insn-modes.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/insn-notes.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/internal-fn.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/internal-fn.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/intl.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/ipa-prop.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/ipa-ref-inline.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/ipa-ref.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/ipa-reference.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/ipa-utils.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/is-a.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/java
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/java/java-tree.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/langhooks.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/libiberty.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/line-map.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/machmode.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/md5.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/mode-classes.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/objc
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/objc/objc-tree.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/obstack.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/omp-builtins.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/options.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/opts.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/output.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/params.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/params.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/pass-instances.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/pass_manager.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/plugin-api.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/plugin-version.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/plugin.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/plugin.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/pointer-set.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/predict.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/predict.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/prefix.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/pretty-print.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/print-rtl.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/print-tree.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/real.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/realmpfr.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/reg-notes.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/regset.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/resource.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/rtl.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/rtl.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/safe-ctype.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/sanitizer.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/sbitmap.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/splay-tree.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/ssa-iterators.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/statistics.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/stmt.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/stor-layout.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/stringpool.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/symtab.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/sync-builtins.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/system.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/target-hooks-macros.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/target.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/target.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/timevar.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/timevar.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tm-preds.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tm.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tm_p.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/toplev.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-cfg.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-cfgcleanup.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-check.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-core.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-dfa.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-dump.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-eh.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-hasher.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-inline.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-into-ssa.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-iterator.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-nested.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-object-size.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-outof-ssa.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-parloops.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-pass.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-phinodes.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-pretty-print.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-ssa-address.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-ssa-alias.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-ssa-coalesce.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-ssa-dom.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-ssa-loop-ivopts.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-ssa-loop-manip.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-ssa-loop-niter.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-ssa-loop.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-ssa-operands.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-ssa-sccvn.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-ssa-ter.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-ssa-threadedge.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-ssa-threadupdate.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-ssa.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree-ssanames.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/tree.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/treestruct.def
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/varasm.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/vec.h
+#usr/lib/gcc/armv5tel-unknown-linux-gnueabi/4.9.3/plugin/include/version.h
+#usr/lib/libasan.a
+#usr/lib/libasan.la
+#usr/lib/libasan.so
+usr/lib/libasan.so.1
+usr/lib/libasan.so.1.0.0
+#usr/lib/libasan_preinit.o
+#usr/lib/libatomic.a
+#usr/lib/libatomic.la
+#usr/lib/libatomic.so
+usr/lib/libatomic.so.1
+usr/lib/libatomic.so.1.1.0
#usr/lib/libgomp.a
#usr/lib/libgomp.la
#usr/lib/libgomp.so
usr/lib/libgomp.so.1
usr/lib/libgomp.so.1.0.0
#usr/lib/libgomp.spec
-#usr/lib/libmudflap.a
-#usr/lib/libmudflap.la
-#usr/lib/libmudflap.so
-usr/lib/libmudflap.so.0
-usr/lib/libmudflap.so.0.0.0
-#usr/lib/libmudflapth.a
-#usr/lib/libmudflapth.la
-#usr/lib/libmudflapth.so
-usr/lib/libmudflapth.so.0
-usr/lib/libmudflapth.so.0.0.0
+#usr/lib/libitm.a
+#usr/lib/libitm.la
+#usr/lib/libitm.so
+usr/lib/libitm.so.1
+usr/lib/libitm.so.1.0.0
+#usr/lib/libitm.spec
+#usr/lib/libsanitizer.spec
#usr/lib/libssp.a
#usr/lib/libssp.la
#usr/lib/libssp.so
#usr/lib/libssp_nonshared.a
#usr/lib/libssp_nonshared.la
#usr/lib/libstdc++.a
-usr/lib/libstdc++.so.6.0.13
+usr/lib/libstdc++.so.6.0.20
+#usr/lib/libstdc++.so.6.0.20-gdb.py
#usr/lib/libsupc++.a
#usr/lib/libsupc++.la
-#usr/man
-#usr/man/man1
-#usr/man/man1/cpp.1
-#usr/man/man1/g++.1
-#usr/man/man1/gcc.1
-#usr/man/man1/gcov.1
-#usr/man/man7
-#usr/man/man7/fsf-funding.7
-#usr/man/man7/gfdl.7
-#usr/man/man7/gpl.7
+#usr/lib/libubsan.a
+#usr/lib/libubsan.la
+#usr/lib/libubsan.so
+usr/lib/libubsan.so.0
+usr/lib/libubsan.so.0.0.0
+#usr/share/gcc-4.9.3
+#usr/share/gcc-4.9.3/python
+#usr/share/gcc-4.9.3/python/libstdcxx
+#usr/share/gcc-4.9.3/python/libstdcxx/__init__.py
+#usr/share/gcc-4.9.3/python/libstdcxx/v6
+#usr/share/gcc-4.9.3/python/libstdcxx/v6/__init__.py
+#usr/share/gcc-4.9.3/python/libstdcxx/v6/printers.py
+#usr/share/info/cpp.info
+#usr/share/info/cppinternals.info
+#usr/share/info/gcc.info
+#usr/share/info/gccinstall.info
+#usr/share/info/gccint.info
+#usr/share/info/libgomp.info
+#usr/share/info/libitm.info
+#usr/share/info/libquadmath.info
+#usr/share/man/man1/cpp.1
+#usr/share/man/man1/g++.1
+#usr/share/man/man1/gcc.1
+#usr/share/man/man1/gcov.1
+#usr/share/man/man7/fsf-funding.7
+#usr/share/man/man7/gfdl.7
+#usr/share/man/man7/gpl.7
#etc/rc.d/init.d/cyrus-sasl
etc/rc.d/init.d/dhcp
etc/rc.d/init.d/dhcrelay
+#etc/rc.d/init.d/dnsdist
etc/rc.d/init.d/dnsmasq
etc/rc.d/init.d/fcron
#etc/rc.d/init.d/fetchmail
usr/bin/diff
#usr/bin/diff3
#usr/bin/sdiff
+#usr/info
#usr/info/diff.info
+#usr/info/dir
#usr/man/man1/cmp.1
#usr/man/man1/diff.1
#usr/man/man1/diff3.1
#usr/lib/ldscripts/i386linux.xn
#usr/lib/ldscripts/i386linux.xr
#usr/lib/ldscripts/i386linux.xu
-usr/lib/libbfd-2.22.so
+usr/lib/libbfd-2.24.so
#usr/lib/libbfd.a
#usr/lib/libbfd.la
#usr/lib/libbfd.so
#usr/lib/libiberty.a
-usr/lib/libopcodes-2.22.so
+usr/lib/libopcodes-2.24.so
#usr/lib/libopcodes.a
#usr/lib/libopcodes.la
#usr/lib/libopcodes.so
#usr/bin/cpp
#usr/bin/g++
#usr/bin/gcc
-#usr/bin/gccbug
+#usr/bin/gcc-ar
+#usr/bin/gcc-nm
+#usr/bin/gcc-ranlib
#usr/bin/gcov
#usr/bin/i586-pc-linux-gnu-c++
#usr/bin/i586-pc-linux-gnu-g++
#usr/bin/i586-pc-linux-gnu-gcc
-#usr/bin/i586-pc-linux-gnu-gcc-4.4.7
+#usr/bin/i586-pc-linux-gnu-gcc-4.9.3
+#usr/bin/i586-pc-linux-gnu-gcc-ar
+#usr/bin/i586-pc-linux-gnu-gcc-nm
+#usr/bin/i586-pc-linux-gnu-gcc-ranlib
#usr/include/c++
-#usr/include/c++/4.4.7
-#usr/include/c++/4.4.7/algorithm
-#usr/include/c++/4.4.7/array
-#usr/include/c++/4.4.7/backward
-#usr/include/c++/4.4.7/backward/auto_ptr.h
-#usr/include/c++/4.4.7/backward/backward_warning.h
-#usr/include/c++/4.4.7/backward/binders.h
-#usr/include/c++/4.4.7/backward/hash_fun.h
-#usr/include/c++/4.4.7/backward/hash_map
-#usr/include/c++/4.4.7/backward/hash_set
-#usr/include/c++/4.4.7/backward/hashtable.h
-#usr/include/c++/4.4.7/backward/strstream
-#usr/include/c++/4.4.7/bits
-#usr/include/c++/4.4.7/bits/algorithmfwd.h
-#usr/include/c++/4.4.7/bits/allocator.h
-#usr/include/c++/4.4.7/bits/atomic_0.h
-#usr/include/c++/4.4.7/bits/atomic_2.h
-#usr/include/c++/4.4.7/bits/atomicfwd_c.h
-#usr/include/c++/4.4.7/bits/atomicfwd_cxx.h
-#usr/include/c++/4.4.7/bits/basic_ios.h
-#usr/include/c++/4.4.7/bits/basic_ios.tcc
-#usr/include/c++/4.4.7/bits/basic_string.h
-#usr/include/c++/4.4.7/bits/basic_string.tcc
-#usr/include/c++/4.4.7/bits/boost_concept_check.h
-#usr/include/c++/4.4.7/bits/char_traits.h
-#usr/include/c++/4.4.7/bits/cmath.tcc
-#usr/include/c++/4.4.7/bits/codecvt.h
-#usr/include/c++/4.4.7/bits/concept_check.h
-#usr/include/c++/4.4.7/bits/cpp_type_traits.h
-#usr/include/c++/4.4.7/bits/deque.tcc
-#usr/include/c++/4.4.7/bits/forward_list.h
-#usr/include/c++/4.4.7/bits/forward_list.tcc
-#usr/include/c++/4.4.7/bits/fstream.tcc
-#usr/include/c++/4.4.7/bits/functexcept.h
-#usr/include/c++/4.4.7/bits/functional_hash.h
-#usr/include/c++/4.4.7/bits/gslice.h
-#usr/include/c++/4.4.7/bits/gslice_array.h
-#usr/include/c++/4.4.7/bits/hashtable.h
-#usr/include/c++/4.4.7/bits/indirect_array.h
-#usr/include/c++/4.4.7/bits/ios_base.h
-#usr/include/c++/4.4.7/bits/istream.tcc
-#usr/include/c++/4.4.7/bits/list.tcc
-#usr/include/c++/4.4.7/bits/locale_classes.h
-#usr/include/c++/4.4.7/bits/locale_classes.tcc
-#usr/include/c++/4.4.7/bits/locale_facets.h
-#usr/include/c++/4.4.7/bits/locale_facets.tcc
-#usr/include/c++/4.4.7/bits/locale_facets_nonio.h
-#usr/include/c++/4.4.7/bits/locale_facets_nonio.tcc
-#usr/include/c++/4.4.7/bits/localefwd.h
-#usr/include/c++/4.4.7/bits/mask_array.h
-#usr/include/c++/4.4.7/bits/move.h
-#usr/include/c++/4.4.7/bits/ostream.tcc
-#usr/include/c++/4.4.7/bits/ostream_insert.h
-#usr/include/c++/4.4.7/bits/postypes.h
-#usr/include/c++/4.4.7/bits/shared_ptr.h
-#usr/include/c++/4.4.7/bits/slice_array.h
-#usr/include/c++/4.4.7/bits/sstream.tcc
-#usr/include/c++/4.4.7/bits/stl_algo.h
-#usr/include/c++/4.4.7/bits/stl_algobase.h
-#usr/include/c++/4.4.7/bits/stl_bvector.h
-#usr/include/c++/4.4.7/bits/stl_construct.h
-#usr/include/c++/4.4.7/bits/stl_deque.h
-#usr/include/c++/4.4.7/bits/stl_function.h
-#usr/include/c++/4.4.7/bits/stl_heap.h
-#usr/include/c++/4.4.7/bits/stl_iterator.h
-#usr/include/c++/4.4.7/bits/stl_iterator_base_funcs.h
-#usr/include/c++/4.4.7/bits/stl_iterator_base_types.h
-#usr/include/c++/4.4.7/bits/stl_list.h
-#usr/include/c++/4.4.7/bits/stl_map.h
-#usr/include/c++/4.4.7/bits/stl_multimap.h
-#usr/include/c++/4.4.7/bits/stl_multiset.h
-#usr/include/c++/4.4.7/bits/stl_numeric.h
-#usr/include/c++/4.4.7/bits/stl_pair.h
-#usr/include/c++/4.4.7/bits/stl_queue.h
-#usr/include/c++/4.4.7/bits/stl_raw_storage_iter.h
-#usr/include/c++/4.4.7/bits/stl_relops.h
-#usr/include/c++/4.4.7/bits/stl_set.h
-#usr/include/c++/4.4.7/bits/stl_stack.h
-#usr/include/c++/4.4.7/bits/stl_tempbuf.h
-#usr/include/c++/4.4.7/bits/stl_tree.h
-#usr/include/c++/4.4.7/bits/stl_uninitialized.h
-#usr/include/c++/4.4.7/bits/stl_vector.h
-#usr/include/c++/4.4.7/bits/stream_iterator.h
-#usr/include/c++/4.4.7/bits/streambuf.tcc
-#usr/include/c++/4.4.7/bits/streambuf_iterator.h
-#usr/include/c++/4.4.7/bits/stringfwd.h
-#usr/include/c++/4.4.7/bits/unique_ptr.h
-#usr/include/c++/4.4.7/bits/valarray_after.h
-#usr/include/c++/4.4.7/bits/valarray_array.h
-#usr/include/c++/4.4.7/bits/valarray_array.tcc
-#usr/include/c++/4.4.7/bits/valarray_before.h
-#usr/include/c++/4.4.7/bits/vector.tcc
-#usr/include/c++/4.4.7/bitset
-#usr/include/c++/4.4.7/c++0x_warning.h
-#usr/include/c++/4.4.7/cassert
-#usr/include/c++/4.4.7/ccomplex
-#usr/include/c++/4.4.7/cctype
-#usr/include/c++/4.4.7/cerrno
-#usr/include/c++/4.4.7/cfenv
-#usr/include/c++/4.4.7/cfloat
-#usr/include/c++/4.4.7/chrono
-#usr/include/c++/4.4.7/cinttypes
-#usr/include/c++/4.4.7/ciso646
-#usr/include/c++/4.4.7/climits
-#usr/include/c++/4.4.7/clocale
-#usr/include/c++/4.4.7/cmath
-#usr/include/c++/4.4.7/complex
-#usr/include/c++/4.4.7/complex.h
-#usr/include/c++/4.4.7/condition_variable
-#usr/include/c++/4.4.7/csetjmp
-#usr/include/c++/4.4.7/csignal
-#usr/include/c++/4.4.7/cstdarg
-#usr/include/c++/4.4.7/cstdatomic
-#usr/include/c++/4.4.7/cstdbool
-#usr/include/c++/4.4.7/cstddef
-#usr/include/c++/4.4.7/cstdint
-#usr/include/c++/4.4.7/cstdio
-#usr/include/c++/4.4.7/cstdlib
-#usr/include/c++/4.4.7/cstring
-#usr/include/c++/4.4.7/ctgmath
-#usr/include/c++/4.4.7/ctime
-#usr/include/c++/4.4.7/cwchar
-#usr/include/c++/4.4.7/cwctype
-#usr/include/c++/4.4.7/cxxabi-forced.h
-#usr/include/c++/4.4.7/cxxabi.h
-#usr/include/c++/4.4.7/debug
-#usr/include/c++/4.4.7/debug/bitset
-#usr/include/c++/4.4.7/debug/debug.h
-#usr/include/c++/4.4.7/debug/deque
-#usr/include/c++/4.4.7/debug/formatter.h
-#usr/include/c++/4.4.7/debug/functions.h
-#usr/include/c++/4.4.7/debug/list
-#usr/include/c++/4.4.7/debug/macros.h
-#usr/include/c++/4.4.7/debug/map
-#usr/include/c++/4.4.7/debug/map.h
-#usr/include/c++/4.4.7/debug/multimap.h
-#usr/include/c++/4.4.7/debug/multiset.h
-#usr/include/c++/4.4.7/debug/safe_base.h
-#usr/include/c++/4.4.7/debug/safe_iterator.h
-#usr/include/c++/4.4.7/debug/safe_iterator.tcc
-#usr/include/c++/4.4.7/debug/safe_sequence.h
-#usr/include/c++/4.4.7/debug/set
-#usr/include/c++/4.4.7/debug/set.h
-#usr/include/c++/4.4.7/debug/string
-#usr/include/c++/4.4.7/debug/unordered_map
-#usr/include/c++/4.4.7/debug/unordered_set
-#usr/include/c++/4.4.7/debug/vector
-#usr/include/c++/4.4.7/deque
-#usr/include/c++/4.4.7/exception
-#usr/include/c++/4.4.7/exception_defines.h
-#usr/include/c++/4.4.7/exception_ptr.h
-#usr/include/c++/4.4.7/ext
-#usr/include/c++/4.4.7/ext/algorithm
-#usr/include/c++/4.4.7/ext/array_allocator.h
-#usr/include/c++/4.4.7/ext/atomicity.h
-#usr/include/c++/4.4.7/ext/bitmap_allocator.h
-#usr/include/c++/4.4.7/ext/cast.h
-#usr/include/c++/4.4.7/ext/codecvt_specializations.h
-#usr/include/c++/4.4.7/ext/concurrence.h
-#usr/include/c++/4.4.7/ext/debug_allocator.h
-#usr/include/c++/4.4.7/ext/enc_filebuf.h
-#usr/include/c++/4.4.7/ext/extptr_allocator.h
-#usr/include/c++/4.4.7/ext/functional
-#usr/include/c++/4.4.7/ext/hash_map
-#usr/include/c++/4.4.7/ext/hash_set
-#usr/include/c++/4.4.7/ext/iterator
-#usr/include/c++/4.4.7/ext/malloc_allocator.h
-#usr/include/c++/4.4.7/ext/memory
-#usr/include/c++/4.4.7/ext/mt_allocator.h
-#usr/include/c++/4.4.7/ext/new_allocator.h
-#usr/include/c++/4.4.7/ext/numeric
-#usr/include/c++/4.4.7/ext/numeric_traits.h
-#usr/include/c++/4.4.7/ext/pb_ds
-#usr/include/c++/4.4.7/ext/pb_ds/assoc_container.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail
-#usr/include/c++/4.4.7/ext/pb_ds/detail/basic_tree_policy
-#usr/include/c++/4.4.7/ext/pb_ds/detail/basic_tree_policy/basic_tree_policy_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/basic_tree_policy/null_node_metadata.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/basic_tree_policy/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/basic_types.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/bin_search_tree_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/cond_dtor_entry_dealtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/cond_key_dtor_entry_dealtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/node_iterators.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/point_iterators.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/r_erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/rotate_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/const_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/const_point_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/entry_cmp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/entry_pred.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/resize_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_/binomial_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/binomial_heap_base_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/cc_ht_map_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/cmp_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/cond_key_dtor_entry_dealtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/debug_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/debug_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/entry_list_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/erase_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/erase_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/find_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/insert_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/insert_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/resize_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/resize_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/resize_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/size_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/standard_policies.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cond_dealtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/container_base_dispatch.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/debug_map_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/eq_fn
-#usr/include/c++/4.4.7/ext/pb_ds/detail/eq_fn/eq_by_less.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/eq_fn/hash_eq_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/debug_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/debug_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/erase_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/erase_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/find_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/find_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/gp_ht_map_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/insert_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/insert_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/iterator_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/resize_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/resize_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/resize_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/standard_policies.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/direct_mask_range_hashing_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/direct_mod_range_hashing_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/linear_probe_fn_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/mask_based_range_hashing.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/mod_based_range_hashing.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/probe_fn_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/quadratic_probe_fn_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/ranged_hash_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/ranged_probe_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/sample_probe_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/sample_range_hashing.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/sample_ranged_hash_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/sample_ranged_probe_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/const_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/const_point_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/left_child_next_sibling_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/node.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/null_metadata.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/constructor_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/entry_metadata_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/lu_map_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_policy
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_policy/counter_lu_metadata.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_policy/counter_lu_policy_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_policy/mtf_lu_policy_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_policy/sample_update_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/cond_dtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/node_iterators.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/ov_tree_map_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/pairing_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/child_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/cond_dtor_entry_dealtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/const_child_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/head.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/insert_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/internal_node.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/leaf.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/node_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/node_iterators.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/node_metadata_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/pat_trie_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/point_iterators.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/r_erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/rotate_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/split_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/split_join_branch_bag.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/synth_e_access_traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/update_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/priority_queue_base_dispatch.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/node.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/rb_tree_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/rc.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/rc_binomial_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/cc_hash_max_collision_check_resize_trigger_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/hash_exponential_size_policy_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_size_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/hash_prime_size_policy_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/hash_standard_resize_policy_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/sample_resize_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/sample_resize_trigger.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/sample_size_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/node.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/splay_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/splay_tree_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/standard_policies.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/thin_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_policy
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_policy/node_metadata_selector.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_policy/null_node_update_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_policy/order_statistics_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_policy/sample_tree_node_update.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_trace_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/node_metadata_selector.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/null_node_update_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/order_statistics_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/prefix_search_node_update_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/sample_trie_e_access_traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/sample_trie_node_update.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/string_trie_e_access_traits_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/trie_policy_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/type_utils.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/types_traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/unordered_iterator
-#usr/include/c++/4.4.7/ext/pb_ds/detail/unordered_iterator/const_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/unordered_iterator/const_point_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/unordered_iterator/iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/unordered_iterator/point_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/exception.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/hash_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/list_update_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/priority_queue.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/tag_and_trait.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/tree_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/trie_policy.hpp
-#usr/include/c++/4.4.7/ext/pod_char_traits.h
-#usr/include/c++/4.4.7/ext/pointer.h
-#usr/include/c++/4.4.7/ext/pool_allocator.h
-#usr/include/c++/4.4.7/ext/rb_tree
-#usr/include/c++/4.4.7/ext/rc_string_base.h
-#usr/include/c++/4.4.7/ext/rope
-#usr/include/c++/4.4.7/ext/ropeimpl.h
-#usr/include/c++/4.4.7/ext/slist
-#usr/include/c++/4.4.7/ext/sso_string_base.h
-#usr/include/c++/4.4.7/ext/stdio_filebuf.h
-#usr/include/c++/4.4.7/ext/stdio_sync_filebuf.h
-#usr/include/c++/4.4.7/ext/string_conversions.h
-#usr/include/c++/4.4.7/ext/throw_allocator.h
-#usr/include/c++/4.4.7/ext/type_traits.h
-#usr/include/c++/4.4.7/ext/typelist.h
-#usr/include/c++/4.4.7/ext/vstring.h
-#usr/include/c++/4.4.7/ext/vstring.tcc
-#usr/include/c++/4.4.7/ext/vstring_fwd.h
-#usr/include/c++/4.4.7/ext/vstring_util.h
-#usr/include/c++/4.4.7/fenv.h
-#usr/include/c++/4.4.7/forward_list
-#usr/include/c++/4.4.7/fstream
-#usr/include/c++/4.4.7/functional
-#usr/include/c++/4.4.7/i586-pc-linux-gnu
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/atomic_word.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/basic_file.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/c++allocator.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/c++config.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/c++io.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/c++locale.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/cpu_defines.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/ctype_base.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/ctype_inline.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/ctype_noninline.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/cxxabi_tweaks.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/error_constants.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/extc++.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/gthr-default.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/gthr-posix.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/gthr-single.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/gthr-tpf.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/gthr.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/messages_members.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/os_defines.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/stdc++.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/stdtr1c++.h
-#usr/include/c++/4.4.7/i586-pc-linux-gnu/bits/time_members.h
-#usr/include/c++/4.4.7/initializer_list
-#usr/include/c++/4.4.7/iomanip
-#usr/include/c++/4.4.7/ios
-#usr/include/c++/4.4.7/iosfwd
-#usr/include/c++/4.4.7/iostream
-#usr/include/c++/4.4.7/istream
-#usr/include/c++/4.4.7/iterator
-#usr/include/c++/4.4.7/limits
-#usr/include/c++/4.4.7/list
-#usr/include/c++/4.4.7/locale
-#usr/include/c++/4.4.7/map
-#usr/include/c++/4.4.7/memory
-#usr/include/c++/4.4.7/mutex
-#usr/include/c++/4.4.7/new
-#usr/include/c++/4.4.7/numeric
-#usr/include/c++/4.4.7/ostream
-#usr/include/c++/4.4.7/parallel
-#usr/include/c++/4.4.7/parallel/algo.h
-#usr/include/c++/4.4.7/parallel/algobase.h
-#usr/include/c++/4.4.7/parallel/algorithm
-#usr/include/c++/4.4.7/parallel/algorithmfwd.h
-#usr/include/c++/4.4.7/parallel/balanced_quicksort.h
-#usr/include/c++/4.4.7/parallel/base.h
-#usr/include/c++/4.4.7/parallel/basic_iterator.h
-#usr/include/c++/4.4.7/parallel/checkers.h
-#usr/include/c++/4.4.7/parallel/compatibility.h
-#usr/include/c++/4.4.7/parallel/compiletime_settings.h
-#usr/include/c++/4.4.7/parallel/equally_split.h
-#usr/include/c++/4.4.7/parallel/features.h
-#usr/include/c++/4.4.7/parallel/find.h
-#usr/include/c++/4.4.7/parallel/find_selectors.h
-#usr/include/c++/4.4.7/parallel/for_each.h
-#usr/include/c++/4.4.7/parallel/for_each_selectors.h
-#usr/include/c++/4.4.7/parallel/iterator.h
-#usr/include/c++/4.4.7/parallel/list_partition.h
-#usr/include/c++/4.4.7/parallel/losertree.h
-#usr/include/c++/4.4.7/parallel/merge.h
-#usr/include/c++/4.4.7/parallel/multiseq_selection.h
-#usr/include/c++/4.4.7/parallel/multiway_merge.h
-#usr/include/c++/4.4.7/parallel/multiway_mergesort.h
-#usr/include/c++/4.4.7/parallel/numeric
-#usr/include/c++/4.4.7/parallel/numericfwd.h
-#usr/include/c++/4.4.7/parallel/omp_loop.h
-#usr/include/c++/4.4.7/parallel/omp_loop_static.h
-#usr/include/c++/4.4.7/parallel/par_loop.h
-#usr/include/c++/4.4.7/parallel/parallel.h
-#usr/include/c++/4.4.7/parallel/partial_sum.h
-#usr/include/c++/4.4.7/parallel/partition.h
-#usr/include/c++/4.4.7/parallel/queue.h
-#usr/include/c++/4.4.7/parallel/quicksort.h
-#usr/include/c++/4.4.7/parallel/random_number.h
-#usr/include/c++/4.4.7/parallel/random_shuffle.h
-#usr/include/c++/4.4.7/parallel/search.h
-#usr/include/c++/4.4.7/parallel/set_operations.h
-#usr/include/c++/4.4.7/parallel/settings.h
-#usr/include/c++/4.4.7/parallel/sort.h
-#usr/include/c++/4.4.7/parallel/tags.h
-#usr/include/c++/4.4.7/parallel/types.h
-#usr/include/c++/4.4.7/parallel/unique_copy.h
-#usr/include/c++/4.4.7/parallel/workstealing.h
-#usr/include/c++/4.4.7/queue
-#usr/include/c++/4.4.7/random
-#usr/include/c++/4.4.7/ratio
-#usr/include/c++/4.4.7/regex
-#usr/include/c++/4.4.7/set
-#usr/include/c++/4.4.7/sstream
-#usr/include/c++/4.4.7/stack
-#usr/include/c++/4.4.7/stdatomic.h
-#usr/include/c++/4.4.7/stdexcept
-#usr/include/c++/4.4.7/streambuf
-#usr/include/c++/4.4.7/string
-#usr/include/c++/4.4.7/system_error
-#usr/include/c++/4.4.7/tgmath.h
-#usr/include/c++/4.4.7/thread
-#usr/include/c++/4.4.7/tr1
-#usr/include/c++/4.4.7/tr1/array
-#usr/include/c++/4.4.7/tr1/bessel_function.tcc
-#usr/include/c++/4.4.7/tr1/beta_function.tcc
-#usr/include/c++/4.4.7/tr1/ccomplex
-#usr/include/c++/4.4.7/tr1/cctype
-#usr/include/c++/4.4.7/tr1/cfenv
-#usr/include/c++/4.4.7/tr1/cfloat
-#usr/include/c++/4.4.7/tr1/cinttypes
-#usr/include/c++/4.4.7/tr1/climits
-#usr/include/c++/4.4.7/tr1/cmath
-#usr/include/c++/4.4.7/tr1/complex
-#usr/include/c++/4.4.7/tr1/complex.h
-#usr/include/c++/4.4.7/tr1/cstdarg
-#usr/include/c++/4.4.7/tr1/cstdbool
-#usr/include/c++/4.4.7/tr1/cstdint
-#usr/include/c++/4.4.7/tr1/cstdio
-#usr/include/c++/4.4.7/tr1/cstdlib
-#usr/include/c++/4.4.7/tr1/ctgmath
-#usr/include/c++/4.4.7/tr1/ctime
-#usr/include/c++/4.4.7/tr1/ctype.h
-#usr/include/c++/4.4.7/tr1/cwchar
-#usr/include/c++/4.4.7/tr1/cwctype
-#usr/include/c++/4.4.7/tr1/ell_integral.tcc
-#usr/include/c++/4.4.7/tr1/exp_integral.tcc
-#usr/include/c++/4.4.7/tr1/fenv.h
-#usr/include/c++/4.4.7/tr1/float.h
-#usr/include/c++/4.4.7/tr1/functional
-#usr/include/c++/4.4.7/tr1/functional_hash.h
-#usr/include/c++/4.4.7/tr1/gamma.tcc
-#usr/include/c++/4.4.7/tr1/hashtable.h
-#usr/include/c++/4.4.7/tr1/hypergeometric.tcc
-#usr/include/c++/4.4.7/tr1/inttypes.h
-#usr/include/c++/4.4.7/tr1/legendre_function.tcc
-#usr/include/c++/4.4.7/tr1/limits.h
-#usr/include/c++/4.4.7/tr1/math.h
-#usr/include/c++/4.4.7/tr1/memory
-#usr/include/c++/4.4.7/tr1/modified_bessel_func.tcc
-#usr/include/c++/4.4.7/tr1/poly_hermite.tcc
-#usr/include/c++/4.4.7/tr1/poly_laguerre.tcc
-#usr/include/c++/4.4.7/tr1/random
-#usr/include/c++/4.4.7/tr1/regex
-#usr/include/c++/4.4.7/tr1/riemann_zeta.tcc
-#usr/include/c++/4.4.7/tr1/shared_ptr.h
-#usr/include/c++/4.4.7/tr1/special_function_util.h
-#usr/include/c++/4.4.7/tr1/stdarg.h
-#usr/include/c++/4.4.7/tr1/stdbool.h
-#usr/include/c++/4.4.7/tr1/stdint.h
-#usr/include/c++/4.4.7/tr1/stdio.h
-#usr/include/c++/4.4.7/tr1/stdlib.h
-#usr/include/c++/4.4.7/tr1/tgmath.h
-#usr/include/c++/4.4.7/tr1/tuple
-#usr/include/c++/4.4.7/tr1/type_traits
-#usr/include/c++/4.4.7/tr1/unordered_map
-#usr/include/c++/4.4.7/tr1/unordered_set
-#usr/include/c++/4.4.7/tr1/utility
-#usr/include/c++/4.4.7/tr1/wchar.h
-#usr/include/c++/4.4.7/tr1/wctype.h
-#usr/include/c++/4.4.7/tr1_impl
-#usr/include/c++/4.4.7/tr1_impl/array
-#usr/include/c++/4.4.7/tr1_impl/boost_sp_counted_base.h
-#usr/include/c++/4.4.7/tr1_impl/cctype
-#usr/include/c++/4.4.7/tr1_impl/cfenv
-#usr/include/c++/4.4.7/tr1_impl/cinttypes
-#usr/include/c++/4.4.7/tr1_impl/cmath
-#usr/include/c++/4.4.7/tr1_impl/complex
-#usr/include/c++/4.4.7/tr1_impl/cstdint
-#usr/include/c++/4.4.7/tr1_impl/cstdio
-#usr/include/c++/4.4.7/tr1_impl/cstdlib
-#usr/include/c++/4.4.7/tr1_impl/cwchar
-#usr/include/c++/4.4.7/tr1_impl/cwctype
-#usr/include/c++/4.4.7/tr1_impl/functional
-#usr/include/c++/4.4.7/tr1_impl/functional_hash.h
-#usr/include/c++/4.4.7/tr1_impl/hashtable
-#usr/include/c++/4.4.7/tr1_impl/hashtable_policy.h
-#usr/include/c++/4.4.7/tr1_impl/random
-#usr/include/c++/4.4.7/tr1_impl/random.tcc
-#usr/include/c++/4.4.7/tr1_impl/regex
-#usr/include/c++/4.4.7/tr1_impl/type_traits
-#usr/include/c++/4.4.7/tr1_impl/unordered_map
-#usr/include/c++/4.4.7/tr1_impl/unordered_set
-#usr/include/c++/4.4.7/tr1_impl/utility
-#usr/include/c++/4.4.7/tuple
-#usr/include/c++/4.4.7/type_traits
-#usr/include/c++/4.4.7/typeinfo
-#usr/include/c++/4.4.7/unordered_map
-#usr/include/c++/4.4.7/unordered_set
-#usr/include/c++/4.4.7/utility
-#usr/include/c++/4.4.7/valarray
-#usr/include/c++/4.4.7/vector
-#usr/info
-#usr/info/cpp.info
-#usr/info/cppinternals.info
-#usr/info/dir
-#usr/info/gcc.info
-#usr/info/gccinstall.info
-#usr/info/gccint.info
-#usr/info/libgomp.info
+#usr/include/c++/4.9.3
+#usr/include/c++/4.9.3/algorithm
+#usr/include/c++/4.9.3/array
+#usr/include/c++/4.9.3/atomic
+#usr/include/c++/4.9.3/backward
+#usr/include/c++/4.9.3/backward/auto_ptr.h
+#usr/include/c++/4.9.3/backward/backward_warning.h
+#usr/include/c++/4.9.3/backward/binders.h
+#usr/include/c++/4.9.3/backward/hash_fun.h
+#usr/include/c++/4.9.3/backward/hash_map
+#usr/include/c++/4.9.3/backward/hash_set
+#usr/include/c++/4.9.3/backward/hashtable.h
+#usr/include/c++/4.9.3/backward/strstream
+#usr/include/c++/4.9.3/bits
+#usr/include/c++/4.9.3/bits/algorithmfwd.h
+#usr/include/c++/4.9.3/bits/alloc_traits.h
+#usr/include/c++/4.9.3/bits/allocator.h
+#usr/include/c++/4.9.3/bits/atomic_base.h
+#usr/include/c++/4.9.3/bits/atomic_lockfree_defines.h
+#usr/include/c++/4.9.3/bits/basic_ios.h
+#usr/include/c++/4.9.3/bits/basic_ios.tcc
+#usr/include/c++/4.9.3/bits/basic_string.h
+#usr/include/c++/4.9.3/bits/basic_string.tcc
+#usr/include/c++/4.9.3/bits/boost_concept_check.h
+#usr/include/c++/4.9.3/bits/c++0x_warning.h
+#usr/include/c++/4.9.3/bits/c++14_warning.h
+#usr/include/c++/4.9.3/bits/char_traits.h
+#usr/include/c++/4.9.3/bits/codecvt.h
+#usr/include/c++/4.9.3/bits/concept_check.h
+#usr/include/c++/4.9.3/bits/cpp_type_traits.h
+#usr/include/c++/4.9.3/bits/cxxabi_forced.h
+#usr/include/c++/4.9.3/bits/deque.tcc
+#usr/include/c++/4.9.3/bits/enable_special_members.h
+#usr/include/c++/4.9.3/bits/exception_defines.h
+#usr/include/c++/4.9.3/bits/exception_ptr.h
+#usr/include/c++/4.9.3/bits/forward_list.h
+#usr/include/c++/4.9.3/bits/forward_list.tcc
+#usr/include/c++/4.9.3/bits/fstream.tcc
+#usr/include/c++/4.9.3/bits/functexcept.h
+#usr/include/c++/4.9.3/bits/functional_hash.h
+#usr/include/c++/4.9.3/bits/gslice.h
+#usr/include/c++/4.9.3/bits/gslice_array.h
+#usr/include/c++/4.9.3/bits/hash_bytes.h
+#usr/include/c++/4.9.3/bits/hashtable.h
+#usr/include/c++/4.9.3/bits/hashtable_policy.h
+#usr/include/c++/4.9.3/bits/indirect_array.h
+#usr/include/c++/4.9.3/bits/ios_base.h
+#usr/include/c++/4.9.3/bits/istream.tcc
+#usr/include/c++/4.9.3/bits/list.tcc
+#usr/include/c++/4.9.3/bits/locale_classes.h
+#usr/include/c++/4.9.3/bits/locale_classes.tcc
+#usr/include/c++/4.9.3/bits/locale_facets.h
+#usr/include/c++/4.9.3/bits/locale_facets.tcc
+#usr/include/c++/4.9.3/bits/locale_facets_nonio.h
+#usr/include/c++/4.9.3/bits/locale_facets_nonio.tcc
+#usr/include/c++/4.9.3/bits/localefwd.h
+#usr/include/c++/4.9.3/bits/mask_array.h
+#usr/include/c++/4.9.3/bits/memoryfwd.h
+#usr/include/c++/4.9.3/bits/move.h
+#usr/include/c++/4.9.3/bits/nested_exception.h
+#usr/include/c++/4.9.3/bits/ostream.tcc
+#usr/include/c++/4.9.3/bits/ostream_insert.h
+#usr/include/c++/4.9.3/bits/parse_numbers.h
+#usr/include/c++/4.9.3/bits/postypes.h
+#usr/include/c++/4.9.3/bits/predefined_ops.h
+#usr/include/c++/4.9.3/bits/ptr_traits.h
+#usr/include/c++/4.9.3/bits/random.h
+#usr/include/c++/4.9.3/bits/random.tcc
+#usr/include/c++/4.9.3/bits/range_access.h
+#usr/include/c++/4.9.3/bits/regex.h
+#usr/include/c++/4.9.3/bits/regex.tcc
+#usr/include/c++/4.9.3/bits/regex_automaton.h
+#usr/include/c++/4.9.3/bits/regex_automaton.tcc
+#usr/include/c++/4.9.3/bits/regex_compiler.h
+#usr/include/c++/4.9.3/bits/regex_compiler.tcc
+#usr/include/c++/4.9.3/bits/regex_constants.h
+#usr/include/c++/4.9.3/bits/regex_error.h
+#usr/include/c++/4.9.3/bits/regex_executor.h
+#usr/include/c++/4.9.3/bits/regex_executor.tcc
+#usr/include/c++/4.9.3/bits/regex_scanner.h
+#usr/include/c++/4.9.3/bits/regex_scanner.tcc
+#usr/include/c++/4.9.3/bits/shared_ptr.h
+#usr/include/c++/4.9.3/bits/shared_ptr_base.h
+#usr/include/c++/4.9.3/bits/slice_array.h
+#usr/include/c++/4.9.3/bits/sstream.tcc
+#usr/include/c++/4.9.3/bits/stl_algo.h
+#usr/include/c++/4.9.3/bits/stl_algobase.h
+#usr/include/c++/4.9.3/bits/stl_bvector.h
+#usr/include/c++/4.9.3/bits/stl_construct.h
+#usr/include/c++/4.9.3/bits/stl_deque.h
+#usr/include/c++/4.9.3/bits/stl_function.h
+#usr/include/c++/4.9.3/bits/stl_heap.h
+#usr/include/c++/4.9.3/bits/stl_iterator.h
+#usr/include/c++/4.9.3/bits/stl_iterator_base_funcs.h
+#usr/include/c++/4.9.3/bits/stl_iterator_base_types.h
+#usr/include/c++/4.9.3/bits/stl_list.h
+#usr/include/c++/4.9.3/bits/stl_map.h
+#usr/include/c++/4.9.3/bits/stl_multimap.h
+#usr/include/c++/4.9.3/bits/stl_multiset.h
+#usr/include/c++/4.9.3/bits/stl_numeric.h
+#usr/include/c++/4.9.3/bits/stl_pair.h
+#usr/include/c++/4.9.3/bits/stl_queue.h
+#usr/include/c++/4.9.3/bits/stl_raw_storage_iter.h
+#usr/include/c++/4.9.3/bits/stl_relops.h
+#usr/include/c++/4.9.3/bits/stl_set.h
+#usr/include/c++/4.9.3/bits/stl_stack.h
+#usr/include/c++/4.9.3/bits/stl_tempbuf.h
+#usr/include/c++/4.9.3/bits/stl_tree.h
+#usr/include/c++/4.9.3/bits/stl_uninitialized.h
+#usr/include/c++/4.9.3/bits/stl_vector.h
+#usr/include/c++/4.9.3/bits/stream_iterator.h
+#usr/include/c++/4.9.3/bits/streambuf.tcc
+#usr/include/c++/4.9.3/bits/streambuf_iterator.h
+#usr/include/c++/4.9.3/bits/stringfwd.h
+#usr/include/c++/4.9.3/bits/unique_ptr.h
+#usr/include/c++/4.9.3/bits/unordered_map.h
+#usr/include/c++/4.9.3/bits/unordered_set.h
+#usr/include/c++/4.9.3/bits/uses_allocator.h
+#usr/include/c++/4.9.3/bits/valarray_after.h
+#usr/include/c++/4.9.3/bits/valarray_array.h
+#usr/include/c++/4.9.3/bits/valarray_array.tcc
+#usr/include/c++/4.9.3/bits/valarray_before.h
+#usr/include/c++/4.9.3/bits/vector.tcc
+#usr/include/c++/4.9.3/bitset
+#usr/include/c++/4.9.3/cassert
+#usr/include/c++/4.9.3/ccomplex
+#usr/include/c++/4.9.3/cctype
+#usr/include/c++/4.9.3/cerrno
+#usr/include/c++/4.9.3/cfenv
+#usr/include/c++/4.9.3/cfloat
+#usr/include/c++/4.9.3/chrono
+#usr/include/c++/4.9.3/cinttypes
+#usr/include/c++/4.9.3/ciso646
+#usr/include/c++/4.9.3/climits
+#usr/include/c++/4.9.3/clocale
+#usr/include/c++/4.9.3/cmath
+#usr/include/c++/4.9.3/complex
+#usr/include/c++/4.9.3/complex.h
+#usr/include/c++/4.9.3/condition_variable
+#usr/include/c++/4.9.3/csetjmp
+#usr/include/c++/4.9.3/csignal
+#usr/include/c++/4.9.3/cstdalign
+#usr/include/c++/4.9.3/cstdarg
+#usr/include/c++/4.9.3/cstdbool
+#usr/include/c++/4.9.3/cstddef
+#usr/include/c++/4.9.3/cstdint
+#usr/include/c++/4.9.3/cstdio
+#usr/include/c++/4.9.3/cstdlib
+#usr/include/c++/4.9.3/cstring
+#usr/include/c++/4.9.3/ctgmath
+#usr/include/c++/4.9.3/ctime
+#usr/include/c++/4.9.3/cwchar
+#usr/include/c++/4.9.3/cwctype
+#usr/include/c++/4.9.3/cxxabi.h
+#usr/include/c++/4.9.3/debug
+#usr/include/c++/4.9.3/debug/array
+#usr/include/c++/4.9.3/debug/bitset
+#usr/include/c++/4.9.3/debug/debug.h
+#usr/include/c++/4.9.3/debug/deque
+#usr/include/c++/4.9.3/debug/formatter.h
+#usr/include/c++/4.9.3/debug/forward_list
+#usr/include/c++/4.9.3/debug/functions.h
+#usr/include/c++/4.9.3/debug/list
+#usr/include/c++/4.9.3/debug/macros.h
+#usr/include/c++/4.9.3/debug/map
+#usr/include/c++/4.9.3/debug/map.h
+#usr/include/c++/4.9.3/debug/multimap.h
+#usr/include/c++/4.9.3/debug/multiset.h
+#usr/include/c++/4.9.3/debug/safe_base.h
+#usr/include/c++/4.9.3/debug/safe_iterator.h
+#usr/include/c++/4.9.3/debug/safe_iterator.tcc
+#usr/include/c++/4.9.3/debug/safe_local_iterator.h
+#usr/include/c++/4.9.3/debug/safe_local_iterator.tcc
+#usr/include/c++/4.9.3/debug/safe_sequence.h
+#usr/include/c++/4.9.3/debug/safe_sequence.tcc
+#usr/include/c++/4.9.3/debug/safe_unordered_base.h
+#usr/include/c++/4.9.3/debug/safe_unordered_container.h
+#usr/include/c++/4.9.3/debug/safe_unordered_container.tcc
+#usr/include/c++/4.9.3/debug/set
+#usr/include/c++/4.9.3/debug/set.h
+#usr/include/c++/4.9.3/debug/string
+#usr/include/c++/4.9.3/debug/unordered_map
+#usr/include/c++/4.9.3/debug/unordered_set
+#usr/include/c++/4.9.3/debug/vector
+#usr/include/c++/4.9.3/decimal
+#usr/include/c++/4.9.3/decimal/decimal
+#usr/include/c++/4.9.3/decimal/decimal.h
+#usr/include/c++/4.9.3/deque
+#usr/include/c++/4.9.3/exception
+#usr/include/c++/4.9.3/experimental
+#usr/include/c++/4.9.3/experimental/optional
+#usr/include/c++/4.9.3/experimental/string_view
+#usr/include/c++/4.9.3/experimental/string_view.tcc
+#usr/include/c++/4.9.3/ext
+#usr/include/c++/4.9.3/ext/algorithm
+#usr/include/c++/4.9.3/ext/aligned_buffer.h
+#usr/include/c++/4.9.3/ext/alloc_traits.h
+#usr/include/c++/4.9.3/ext/array_allocator.h
+#usr/include/c++/4.9.3/ext/atomicity.h
+#usr/include/c++/4.9.3/ext/bitmap_allocator.h
+#usr/include/c++/4.9.3/ext/cast.h
+#usr/include/c++/4.9.3/ext/cmath
+#usr/include/c++/4.9.3/ext/codecvt_specializations.h
+#usr/include/c++/4.9.3/ext/concurrence.h
+#usr/include/c++/4.9.3/ext/debug_allocator.h
+#usr/include/c++/4.9.3/ext/enc_filebuf.h
+#usr/include/c++/4.9.3/ext/extptr_allocator.h
+#usr/include/c++/4.9.3/ext/functional
+#usr/include/c++/4.9.3/ext/hash_map
+#usr/include/c++/4.9.3/ext/hash_set
+#usr/include/c++/4.9.3/ext/iterator
+#usr/include/c++/4.9.3/ext/malloc_allocator.h
+#usr/include/c++/4.9.3/ext/memory
+#usr/include/c++/4.9.3/ext/mt_allocator.h
+#usr/include/c++/4.9.3/ext/new_allocator.h
+#usr/include/c++/4.9.3/ext/numeric
+#usr/include/c++/4.9.3/ext/numeric_traits.h
+#usr/include/c++/4.9.3/ext/pb_ds
+#usr/include/c++/4.9.3/ext/pb_ds/assoc_container.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/bin_search_tree_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/node_iterators.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/point_iterators.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/r_erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/rotate_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/entry_cmp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/entry_pred.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/point_const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/resize_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_/binomial_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/binomial_heap_base_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/branch_policy
+#usr/include/c++/4.9.3/ext/pb_ds/detail/branch_policy/branch_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/branch_policy/null_node_metadata.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/branch_policy/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/cc_ht_map_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/cmp_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/cond_key_dtor_entry_dealtor.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/debug_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/debug_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/entry_list_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/erase_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/erase_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/find_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/insert_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/insert_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/resize_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/resize_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/resize_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/size_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cond_dealtor.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/container_base_dispatch.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/debug_map_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/eq_fn
+#usr/include/c++/4.9.3/ext/pb_ds/detail/eq_fn/eq_by_less.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/eq_fn/hash_eq_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/debug_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/debug_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/erase_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/erase_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/find_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/find_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/gp_ht_map_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/insert_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/insert_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/iterator_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/resize_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/resize_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/resize_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/direct_mask_range_hashing_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/direct_mod_range_hashing_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/linear_probe_fn_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/mask_based_range_hashing.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/mod_based_range_hashing.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/probe_fn_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/quadratic_probe_fn_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/ranged_hash_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/ranged_probe_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/sample_probe_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/sample_range_hashing.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/sample_ranged_hash_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/sample_ranged_probe_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/left_child_next_sibling_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/node.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/point_const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/constructor_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/entry_metadata_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/lu_map_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_policy
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_policy/lu_counter_metadata.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_policy/sample_update_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/node_iterators.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/ov_tree_map_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/pairing_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/insert_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/pat_trie_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/pat_trie_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/r_erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/rotate_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/split_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/synth_access_traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/update_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/priority_queue_base_dispatch.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/node.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/rb_tree_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/rc.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/rc_binomial_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/cc_hash_max_collision_check_resize_trigger_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/hash_exponential_size_policy_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_size_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/hash_prime_size_policy_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/hash_standard_resize_policy_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/sample_resize_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/sample_resize_trigger.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/sample_size_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/node.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/splay_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/splay_tree_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/standard_policies.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/thin_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/tree_policy
+#usr/include/c++/4.9.3/ext/pb_ds/detail/tree_policy/node_metadata_selector.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/tree_policy/order_statistics_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/tree_policy/sample_tree_node_update.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/tree_trace_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/node_metadata_selector.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/order_statistics_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/prefix_search_node_update_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/sample_trie_access_traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/sample_trie_node_update.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/trie_policy_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/trie_string_access_traits_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/type_utils.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/types_traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/unordered_iterator
+#usr/include/c++/4.9.3/ext/pb_ds/detail/unordered_iterator/const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/unordered_iterator/iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/unordered_iterator/point_const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/unordered_iterator/point_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/exception.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/hash_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/list_update_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/priority_queue.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/tag_and_trait.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/tree_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/trie_policy.hpp
+#usr/include/c++/4.9.3/ext/pod_char_traits.h
+#usr/include/c++/4.9.3/ext/pointer.h
+#usr/include/c++/4.9.3/ext/pool_allocator.h
+#usr/include/c++/4.9.3/ext/random
+#usr/include/c++/4.9.3/ext/random.tcc
+#usr/include/c++/4.9.3/ext/rb_tree
+#usr/include/c++/4.9.3/ext/rc_string_base.h
+#usr/include/c++/4.9.3/ext/rope
+#usr/include/c++/4.9.3/ext/ropeimpl.h
+#usr/include/c++/4.9.3/ext/slist
+#usr/include/c++/4.9.3/ext/sso_string_base.h
+#usr/include/c++/4.9.3/ext/stdio_filebuf.h
+#usr/include/c++/4.9.3/ext/stdio_sync_filebuf.h
+#usr/include/c++/4.9.3/ext/string_conversions.h
+#usr/include/c++/4.9.3/ext/throw_allocator.h
+#usr/include/c++/4.9.3/ext/type_traits.h
+#usr/include/c++/4.9.3/ext/typelist.h
+#usr/include/c++/4.9.3/ext/vstring.h
+#usr/include/c++/4.9.3/ext/vstring.tcc
+#usr/include/c++/4.9.3/ext/vstring_fwd.h
+#usr/include/c++/4.9.3/ext/vstring_util.h
+#usr/include/c++/4.9.3/fenv.h
+#usr/include/c++/4.9.3/forward_list
+#usr/include/c++/4.9.3/fstream
+#usr/include/c++/4.9.3/functional
+#usr/include/c++/4.9.3/future
+#usr/include/c++/4.9.3/i586-pc-linux-gnu
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/atomic_word.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/basic_file.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/c++allocator.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/c++config.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/c++io.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/c++locale.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/cpu_defines.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/ctype_base.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/ctype_inline.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/cxxabi_tweaks.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/error_constants.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/extc++.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/gthr-default.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/gthr-posix.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/gthr-single.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/gthr.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/messages_members.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/opt_random.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/os_defines.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/stdc++.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/stdtr1c++.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/bits/time_members.h
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/ext
+#usr/include/c++/4.9.3/i586-pc-linux-gnu/ext/opt_random.h
+#usr/include/c++/4.9.3/initializer_list
+#usr/include/c++/4.9.3/iomanip
+#usr/include/c++/4.9.3/ios
+#usr/include/c++/4.9.3/iosfwd
+#usr/include/c++/4.9.3/iostream
+#usr/include/c++/4.9.3/istream
+#usr/include/c++/4.9.3/iterator
+#usr/include/c++/4.9.3/limits
+#usr/include/c++/4.9.3/list
+#usr/include/c++/4.9.3/locale
+#usr/include/c++/4.9.3/map
+#usr/include/c++/4.9.3/memory
+#usr/include/c++/4.9.3/mutex
+#usr/include/c++/4.9.3/new
+#usr/include/c++/4.9.3/numeric
+#usr/include/c++/4.9.3/ostream
+#usr/include/c++/4.9.3/parallel
+#usr/include/c++/4.9.3/parallel/algo.h
+#usr/include/c++/4.9.3/parallel/algobase.h
+#usr/include/c++/4.9.3/parallel/algorithm
+#usr/include/c++/4.9.3/parallel/algorithmfwd.h
+#usr/include/c++/4.9.3/parallel/balanced_quicksort.h
+#usr/include/c++/4.9.3/parallel/base.h
+#usr/include/c++/4.9.3/parallel/basic_iterator.h
+#usr/include/c++/4.9.3/parallel/checkers.h
+#usr/include/c++/4.9.3/parallel/compatibility.h
+#usr/include/c++/4.9.3/parallel/compiletime_settings.h
+#usr/include/c++/4.9.3/parallel/equally_split.h
+#usr/include/c++/4.9.3/parallel/features.h
+#usr/include/c++/4.9.3/parallel/find.h
+#usr/include/c++/4.9.3/parallel/find_selectors.h
+#usr/include/c++/4.9.3/parallel/for_each.h
+#usr/include/c++/4.9.3/parallel/for_each_selectors.h
+#usr/include/c++/4.9.3/parallel/iterator.h
+#usr/include/c++/4.9.3/parallel/list_partition.h
+#usr/include/c++/4.9.3/parallel/losertree.h
+#usr/include/c++/4.9.3/parallel/merge.h
+#usr/include/c++/4.9.3/parallel/multiseq_selection.h
+#usr/include/c++/4.9.3/parallel/multiway_merge.h
+#usr/include/c++/4.9.3/parallel/multiway_mergesort.h
+#usr/include/c++/4.9.3/parallel/numeric
+#usr/include/c++/4.9.3/parallel/numericfwd.h
+#usr/include/c++/4.9.3/parallel/omp_loop.h
+#usr/include/c++/4.9.3/parallel/omp_loop_static.h
+#usr/include/c++/4.9.3/parallel/par_loop.h
+#usr/include/c++/4.9.3/parallel/parallel.h
+#usr/include/c++/4.9.3/parallel/partial_sum.h
+#usr/include/c++/4.9.3/parallel/partition.h
+#usr/include/c++/4.9.3/parallel/queue.h
+#usr/include/c++/4.9.3/parallel/quicksort.h
+#usr/include/c++/4.9.3/parallel/random_number.h
+#usr/include/c++/4.9.3/parallel/random_shuffle.h
+#usr/include/c++/4.9.3/parallel/search.h
+#usr/include/c++/4.9.3/parallel/set_operations.h
+#usr/include/c++/4.9.3/parallel/settings.h
+#usr/include/c++/4.9.3/parallel/sort.h
+#usr/include/c++/4.9.3/parallel/tags.h
+#usr/include/c++/4.9.3/parallel/types.h
+#usr/include/c++/4.9.3/parallel/unique_copy.h
+#usr/include/c++/4.9.3/parallel/workstealing.h
+#usr/include/c++/4.9.3/profile
+#usr/include/c++/4.9.3/profile/array
+#usr/include/c++/4.9.3/profile/base.h
+#usr/include/c++/4.9.3/profile/bitset
+#usr/include/c++/4.9.3/profile/deque
+#usr/include/c++/4.9.3/profile/forward_list
+#usr/include/c++/4.9.3/profile/impl
+#usr/include/c++/4.9.3/profile/impl/profiler.h
+#usr/include/c++/4.9.3/profile/impl/profiler_algos.h
+#usr/include/c++/4.9.3/profile/impl/profiler_container_size.h
+#usr/include/c++/4.9.3/profile/impl/profiler_hash_func.h
+#usr/include/c++/4.9.3/profile/impl/profiler_hashtable_size.h
+#usr/include/c++/4.9.3/profile/impl/profiler_list_to_slist.h
+#usr/include/c++/4.9.3/profile/impl/profiler_list_to_vector.h
+#usr/include/c++/4.9.3/profile/impl/profiler_map_to_unordered_map.h
+#usr/include/c++/4.9.3/profile/impl/profiler_node.h
+#usr/include/c++/4.9.3/profile/impl/profiler_state.h
+#usr/include/c++/4.9.3/profile/impl/profiler_trace.h
+#usr/include/c++/4.9.3/profile/impl/profiler_vector_size.h
+#usr/include/c++/4.9.3/profile/impl/profiler_vector_to_list.h
+#usr/include/c++/4.9.3/profile/iterator_tracker.h
+#usr/include/c++/4.9.3/profile/list
+#usr/include/c++/4.9.3/profile/map
+#usr/include/c++/4.9.3/profile/map.h
+#usr/include/c++/4.9.3/profile/multimap.h
+#usr/include/c++/4.9.3/profile/multiset.h
+#usr/include/c++/4.9.3/profile/set
+#usr/include/c++/4.9.3/profile/set.h
+#usr/include/c++/4.9.3/profile/unordered_base.h
+#usr/include/c++/4.9.3/profile/unordered_map
+#usr/include/c++/4.9.3/profile/unordered_set
+#usr/include/c++/4.9.3/profile/vector
+#usr/include/c++/4.9.3/queue
+#usr/include/c++/4.9.3/random
+#usr/include/c++/4.9.3/ratio
+#usr/include/c++/4.9.3/regex
+#usr/include/c++/4.9.3/scoped_allocator
+#usr/include/c++/4.9.3/set
+#usr/include/c++/4.9.3/shared_mutex
+#usr/include/c++/4.9.3/sstream
+#usr/include/c++/4.9.3/stack
+#usr/include/c++/4.9.3/stdexcept
+#usr/include/c++/4.9.3/streambuf
+#usr/include/c++/4.9.3/string
+#usr/include/c++/4.9.3/system_error
+#usr/include/c++/4.9.3/tgmath.h
+#usr/include/c++/4.9.3/thread
+#usr/include/c++/4.9.3/tr1
+#usr/include/c++/4.9.3/tr1/array
+#usr/include/c++/4.9.3/tr1/bessel_function.tcc
+#usr/include/c++/4.9.3/tr1/beta_function.tcc
+#usr/include/c++/4.9.3/tr1/ccomplex
+#usr/include/c++/4.9.3/tr1/cctype
+#usr/include/c++/4.9.3/tr1/cfenv
+#usr/include/c++/4.9.3/tr1/cfloat
+#usr/include/c++/4.9.3/tr1/cinttypes
+#usr/include/c++/4.9.3/tr1/climits
+#usr/include/c++/4.9.3/tr1/cmath
+#usr/include/c++/4.9.3/tr1/complex
+#usr/include/c++/4.9.3/tr1/complex.h
+#usr/include/c++/4.9.3/tr1/cstdarg
+#usr/include/c++/4.9.3/tr1/cstdbool
+#usr/include/c++/4.9.3/tr1/cstdint
+#usr/include/c++/4.9.3/tr1/cstdio
+#usr/include/c++/4.9.3/tr1/cstdlib
+#usr/include/c++/4.9.3/tr1/ctgmath
+#usr/include/c++/4.9.3/tr1/ctime
+#usr/include/c++/4.9.3/tr1/ctype.h
+#usr/include/c++/4.9.3/tr1/cwchar
+#usr/include/c++/4.9.3/tr1/cwctype
+#usr/include/c++/4.9.3/tr1/ell_integral.tcc
+#usr/include/c++/4.9.3/tr1/exp_integral.tcc
+#usr/include/c++/4.9.3/tr1/fenv.h
+#usr/include/c++/4.9.3/tr1/float.h
+#usr/include/c++/4.9.3/tr1/functional
+#usr/include/c++/4.9.3/tr1/functional_hash.h
+#usr/include/c++/4.9.3/tr1/gamma.tcc
+#usr/include/c++/4.9.3/tr1/hashtable.h
+#usr/include/c++/4.9.3/tr1/hashtable_policy.h
+#usr/include/c++/4.9.3/tr1/hypergeometric.tcc
+#usr/include/c++/4.9.3/tr1/inttypes.h
+#usr/include/c++/4.9.3/tr1/legendre_function.tcc
+#usr/include/c++/4.9.3/tr1/limits.h
+#usr/include/c++/4.9.3/tr1/math.h
+#usr/include/c++/4.9.3/tr1/memory
+#usr/include/c++/4.9.3/tr1/modified_bessel_func.tcc
+#usr/include/c++/4.9.3/tr1/poly_hermite.tcc
+#usr/include/c++/4.9.3/tr1/poly_laguerre.tcc
+#usr/include/c++/4.9.3/tr1/random
+#usr/include/c++/4.9.3/tr1/random.h
+#usr/include/c++/4.9.3/tr1/random.tcc
+#usr/include/c++/4.9.3/tr1/regex
+#usr/include/c++/4.9.3/tr1/riemann_zeta.tcc
+#usr/include/c++/4.9.3/tr1/shared_ptr.h
+#usr/include/c++/4.9.3/tr1/special_function_util.h
+#usr/include/c++/4.9.3/tr1/stdarg.h
+#usr/include/c++/4.9.3/tr1/stdbool.h
+#usr/include/c++/4.9.3/tr1/stdint.h
+#usr/include/c++/4.9.3/tr1/stdio.h
+#usr/include/c++/4.9.3/tr1/stdlib.h
+#usr/include/c++/4.9.3/tr1/tgmath.h
+#usr/include/c++/4.9.3/tr1/tuple
+#usr/include/c++/4.9.3/tr1/type_traits
+#usr/include/c++/4.9.3/tr1/unordered_map
+#usr/include/c++/4.9.3/tr1/unordered_map.h
+#usr/include/c++/4.9.3/tr1/unordered_set
+#usr/include/c++/4.9.3/tr1/unordered_set.h
+#usr/include/c++/4.9.3/tr1/utility
+#usr/include/c++/4.9.3/tr1/wchar.h
+#usr/include/c++/4.9.3/tr1/wctype.h
+#usr/include/c++/4.9.3/tr2
+#usr/include/c++/4.9.3/tr2/bool_set
+#usr/include/c++/4.9.3/tr2/bool_set.tcc
+#usr/include/c++/4.9.3/tr2/dynamic_bitset
+#usr/include/c++/4.9.3/tr2/dynamic_bitset.tcc
+#usr/include/c++/4.9.3/tr2/ratio
+#usr/include/c++/4.9.3/tr2/type_traits
+#usr/include/c++/4.9.3/tuple
+#usr/include/c++/4.9.3/type_traits
+#usr/include/c++/4.9.3/typeindex
+#usr/include/c++/4.9.3/typeinfo
+#usr/include/c++/4.9.3/unordered_map
+#usr/include/c++/4.9.3/unordered_set
+#usr/include/c++/4.9.3/utility
+#usr/include/c++/4.9.3/valarray
+#usr/include/c++/4.9.3/vector
#usr/lib/gcc
#usr/lib/gcc/i586-pc-linux-gnu
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/cc1
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/cc1plus
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/collect2
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/crtbegin.o
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/crtbeginS.o
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/crtbeginT.o
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/crtend.o
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/crtendS.o
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/crtfastmath.o
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/crtprec32.o
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/crtprec64.o
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/crtprec80.o
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/finclude
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include-fixed
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include-fixed/README
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include-fixed/limits.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include-fixed/syslimits.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/ammintrin.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/avxintrin.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/bmmintrin.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/cpuid.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/cross-stdarg.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/emmintrin.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/float.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/immintrin.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/iso646.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/mf-runtime.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/mm3dnow.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/mm_malloc.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/mmintrin-common.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/mmintrin.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/nmmintrin.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/omp.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/pmmintrin.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/smmintrin.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/ssp
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/ssp/ssp.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/ssp/stdio.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/ssp/string.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/ssp/unistd.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/stdarg.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/stdbool.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/stddef.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/stdfix.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/tmmintrin.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/unwind.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/varargs.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/wmmintrin.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/x86intrin.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/include/xmmintrin.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/install-tools
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/install-tools/fixinc.sh
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/install-tools/fixinc_list
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/install-tools/fixincl
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/install-tools/gsyslimits.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/install-tools/include
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/install-tools/include/README
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/install-tools/include/limits.h
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/install-tools/macro_list
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/install-tools/mkheaders
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/install-tools/mkheaders.conf
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/install-tools/mkinstalldirs
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/libgcc.a
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/libgcc_eh.a
-#usr/lib/gcc/i586-pc-linux-gnu/4.4.7/libgcov.a
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/cc1
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/cc1plus
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/collect2
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/crtbegin.o
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/crtbeginS.o
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/crtbeginT.o
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/crtend.o
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/crtendS.o
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/crtfastmath.o
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/crtprec32.o
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/crtprec64.o
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/crtprec80.o
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/finclude
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include-fixed
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include-fixed/README
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include-fixed/limits.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include-fixed/syslimits.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/adxintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/ammintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/avx2intrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/avx512cdintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/avx512erintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/avx512fintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/avx512pfintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/avxintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/bmi2intrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/bmiintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/bmmintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/cilk.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/cilk_api.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/cilk_api_linux.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/cilk_stub.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/cilk_undocumented.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/common.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/holder.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/hyperobject_base.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/metaprogramming.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/reducer.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/reducer_file.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/reducer_list.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/reducer_max.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/reducer_min.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/reducer_min_max.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/reducer_opadd.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/reducer_opand.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/reducer_opmul.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/reducer_opor.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/reducer_opxor.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/reducer_ostream.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cilk/reducer_string.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cpuid.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/cross-stdarg.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/emmintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/f16cintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/float.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/fma4intrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/fmaintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/fxsrintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/ia32intrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/immintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/iso646.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/lwpintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/lzcntintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/mm3dnow.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/mm_malloc.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/mmintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/nmmintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/omp.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/pmmintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/popcntintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/prfchwintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/quadmath.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/quadmath_weak.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/rdseedintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/rtmintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/sanitizer
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/sanitizer/asan_interface.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/sanitizer/common_interface_defs.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/sanitizer/lsan_interface.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/shaintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/smmintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/ssp
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/ssp/ssp.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/ssp/stdio.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/ssp/string.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/ssp/unistd.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/stdalign.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/stdarg.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/stdatomic.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/stdbool.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/stddef.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/stdfix.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/stdint-gcc.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/stdint.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/stdnoreturn.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/tbmintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/tmmintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/unwind.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/varargs.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/wmmintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/x86intrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/xmmintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/xopintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/xsaveintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/xsaveoptintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/include/xtestintrin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/install-tools
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/install-tools/fixinc.sh
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/install-tools/fixinc_list
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/install-tools/fixincl
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/install-tools/gsyslimits.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/install-tools/include
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/install-tools/include/README
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/install-tools/include/limits.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/install-tools/macro_list
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/install-tools/mkheaders
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/install-tools/mkheaders.conf
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/install-tools/mkinstalldirs
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/libgcc.a
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/libgcc_eh.a
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/libgcov.a
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/liblto_plugin.la
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/liblto_plugin.so
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/liblto_plugin.so.0
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/liblto_plugin.so.0.0.0
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/lto-wrapper
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/lto1
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/gengtype
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/gtype.state
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/ada
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/ada/gcc-interface
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/ada/gcc-interface/ada-tree.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/alias.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/all-tree.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/alloc-pool.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/ansidecl.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/attribs.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/auto-host.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/b-header-vars
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/basic-block.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/bitmap.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/builtins.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/bversion.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/c-family
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/c-family/c-common.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/c-family/c-common.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/c-family/c-objc.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/c-family/c-pragma.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/c-family/c-pretty-print.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/c-tree.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/calls.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cfg-flags.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cfgexpand.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cfghooks.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cfgloop.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cgraph.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cif-code.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cilk-builtins.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cilkplus.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/dbxelf.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/elfos.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/glibc-stdint.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/gnu-user.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/i386
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/i386/att.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/i386/gnu-user-common.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/i386/gnu-user.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/i386/i386-opts.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/i386/i386-protos.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/i386/i386.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/i386/linux-common.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/i386/linux.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/i386/stringop.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/i386/unix.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/i386/x86-tune.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/initfini-array.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/linux-android.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/linux-protos.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/linux.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/config/vxworks-dummy.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/configargs.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/context.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/coretypes.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cp
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cp/cp-tree.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cp/cp-tree.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cp/cxx-pretty-print.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cp/name-lookup.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cp/type-utils.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cppdefault.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/cpplib.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/debug.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/defaults.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/df.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/diagnostic-color.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/diagnostic-core.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/diagnostic.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/diagnostic.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/double-int.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/dumpfile.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/emit-rtl.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/except.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/filenames.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/fixed-value.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/flag-types.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/flags.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/fold-const.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/function.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gcc-plugin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gcc-symtab.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/genrtl.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/ggc.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gimple-builder.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gimple-expr.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gimple-fold.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gimple-iterator.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gimple-low.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gimple-pretty-print.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gimple-ssa.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gimple-walk.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gimple.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gimple.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gimplify-me.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gimplify.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gsstruct.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gtm-builtins.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/gtype-desc.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/hard-reg-set.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/hash-table.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/hashtab.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/highlev-plugin-common.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/hwint.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/incpath.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/input.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/insn-codes.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/insn-constants.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/insn-flags.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/insn-modes.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/insn-notes.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/internal-fn.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/internal-fn.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/intl.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/ipa-prop.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/ipa-ref-inline.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/ipa-ref.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/ipa-reference.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/ipa-utils.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/is-a.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/java
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/java/java-tree.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/langhooks.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/libiberty.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/line-map.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/machmode.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/md5.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/mode-classes.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/objc
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/objc/objc-tree.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/obstack.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/omp-builtins.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/options.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/opts.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/output.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/params.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/params.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/pass-instances.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/pass_manager.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/plugin-api.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/plugin-version.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/plugin.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/plugin.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/pointer-set.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/predict.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/predict.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/prefix.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/pretty-print.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/print-rtl.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/print-tree.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/real.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/realmpfr.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/reg-notes.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/regset.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/resource.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/rtl.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/rtl.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/safe-ctype.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/sanitizer.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/sbitmap.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/splay-tree.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/ssa-iterators.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/statistics.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/stmt.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/stor-layout.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/stringpool.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/symtab.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/sync-builtins.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/system.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/target-hooks-macros.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/target.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/target.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/timevar.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/timevar.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tm-preds.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tm.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tm_p.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/toplev.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-cfg.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-cfgcleanup.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-check.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-core.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-dfa.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-dump.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-eh.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-hasher.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-inline.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-into-ssa.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-iterator.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-nested.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-object-size.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-outof-ssa.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-parloops.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-pass.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-phinodes.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-pretty-print.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-ssa-address.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-ssa-alias.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-ssa-coalesce.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-ssa-dom.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-ssa-loop-ivopts.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-ssa-loop-manip.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-ssa-loop-niter.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-ssa-loop.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-ssa-operands.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-ssa-sccvn.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-ssa-ter.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-ssa-threadedge.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-ssa-threadupdate.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-ssa.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree-ssanames.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/tree.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/treestruct.def
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/varasm.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/vec.h
+#usr/lib/gcc/i586-pc-linux-gnu/4.9.3/plugin/include/version.h
+#usr/lib/libasan.a
+#usr/lib/libasan.la
+#usr/lib/libasan.so
+usr/lib/libasan.so.1
+usr/lib/libasan.so.1.0.0
+usr/lib/libasan_preinit.o
+#usr/lib/libatomic.a
+#usr/lib/libatomic.la
+usr/lib/libatomic.so
+usr/lib/libatomic.so.1
+usr/lib/libatomic.so.1.1.0
+#usr/lib/libcilkrts.a
+#usr/lib/libcilkrts.la
+#usr/lib/libcilkrts.so
+usr/lib/libcilkrts.so.5
+usr/lib/libcilkrts.so.5.0.0
+#usr/lib/libcilkrts.spec
#usr/lib/libgomp.a
#usr/lib/libgomp.la
#usr/lib/libgomp.so
usr/lib/libgomp.so.1
usr/lib/libgomp.so.1.0.0
#usr/lib/libgomp.spec
-#usr/lib/libmudflap.a
-#usr/lib/libmudflap.la
-#usr/lib/libmudflap.so
-usr/lib/libmudflap.so.0
-usr/lib/libmudflap.so.0.0.0
-#usr/lib/libmudflapth.a
-#usr/lib/libmudflapth.la
-#usr/lib/libmudflapth.so
-usr/lib/libmudflapth.so.0
-usr/lib/libmudflapth.so.0.0.0
+#usr/lib/libitm.a
+#usr/lib/libitm.la
+#usr/lib/libitm.so
+usr/lib/libitm.so.1
+usr/lib/libitm.so.1.0.0
+#usr/lib/libitm.spec
+#usr/lib/libquadmath.a
+#usr/lib/libquadmath.la
+#usr/lib/libquadmath.so
+usr/lib/libquadmath.so.0
+usr/lib/libquadmath.so.0.0.0
+#usr/lib/libsanitizer.spec
#usr/lib/libssp.a
#usr/lib/libssp.la
#usr/lib/libssp.so
#usr/lib/libssp_nonshared.a
#usr/lib/libssp_nonshared.la
#usr/lib/libstdc++.a
-usr/lib/libstdc++.so.6.0.13
+usr/lib/libstdc++.so.6.0.20
+#usr/lib/libstdc++.so.6.0.20-gdb.py
#usr/lib/libsupc++.a
#usr/lib/libsupc++.la
-#usr/man
-#usr/man/man1
-#usr/man/man1/cpp.1
-#usr/man/man1/g++.1
-#usr/man/man1/gcc.1
-#usr/man/man1/gcov.1
-#usr/man/man7
-#usr/man/man7/fsf-funding.7
-#usr/man/man7/gfdl.7
-#usr/man/man7/gpl.7
+#usr/lib/libubsan.a
+#usr/lib/libubsan.la
+#usr/lib/libubsan.so
+usr/lib/libubsan.so.0
+usr/lib/libubsan.so.0.0.0
+#usr/lib/libvtv.a
+#usr/lib/libvtv.la
+#usr/lib/libvtv.so
+usr/lib/libvtv.so.0
+usr/lib/libvtv.so.0.0.0
+#usr/share/gcc-4.9.3
+#usr/share/gcc-4.9.3/python
+#usr/share/gcc-4.9.3/python/libstdcxx
+#usr/share/gcc-4.9.3/python/libstdcxx/__init__.py
+#usr/share/gcc-4.9.3/python/libstdcxx/v6
+#usr/share/gcc-4.9.3/python/libstdcxx/v6/__init__.py
+#usr/share/gcc-4.9.3/python/libstdcxx/v6/printers.py
+#usr/share/info/cpp.info
+#usr/share/info/cppinternals.info
+#usr/share/info/gcc.info
+#usr/share/info/gccinstall.info
+#usr/share/info/gccint.info
+#usr/share/info/libgomp.info
+#usr/share/info/libitm.info
+#usr/share/info/libquadmath.info
+#usr/share/man/man1/cpp.1
+#usr/share/man/man1/g++.1
+#usr/share/man/man1/gcc.1
+#usr/share/man/man1/gcov.1
+#usr/share/man/man7/fsf-funding.7
+#usr/share/man/man7/gfdl.7
+#usr/share/man/man7/gpl.7
#etc/rc.d/init.d/cyrus-sasl
etc/rc.d/init.d/dhcp
etc/rc.d/init.d/dhcrelay
+#etc/rc.d/init.d/dnsdist
etc/rc.d/init.d/dnsmasq
etc/rc.d/init.d/fcron
#etc/rc.d/init.d/fetchmail
--- /dev/null
+#usr/include/mpc.h
+#usr/lib/libmpc.a
+#usr/lib/libmpc.la
+#usr/lib/libmpc.so
+usr/lib/libmpc.so.3
+usr/lib/libmpc.so.3.0.0
+#usr/share/info/mpc.info
--- /dev/null
+usr/bin/lua
+usr/bin/luac
+#usr/include/lauxlib.h
+#usr/include/lua.h
+#usr/include/lua.hpp
+#usr/include/luaconf.h
+#usr/include/lualib.h
+usr/lib/liblua-5.3.so
+#usr/lib/liblua.a
+#usr/lib/liblua.la
+usr/lib/liblua.so
+#usr/lib/pkgconfig/lua.pc
+#usr/share/man/man1/lua.1
+#usr/share/man/man1/luac.1
usr/lib/libtinfo.so.5
usr/lib/libtinfo.so.5.9
#usr/lib/terminfo
+#usr/man
+#usr/man/man1
#usr/man/man1/captoinfo.1m
#usr/man/man1/clear.1
#usr/man/man1/infocmp.1m
#usr/man/man5
#usr/man/man5/term.5
#usr/man/man5/terminfo.5
+#usr/man/man7
#usr/man/man7/term.7
#usr/share/tabset
#usr/share/tabset/std
usr/bin/ntpdate
usr/bin/ntpdc
usr/bin/ntpq
+#usr/bin/ntpsnmpd
usr/bin/ntptime
usr/bin/ntptrace
usr/bin/sntp
#usr/share/man/man1/ntpdc.1
#usr/share/man/man1/ntpq.1
#usr/share/man/man1/ntptrace.1
+#usr/share/man/man1/ntpsnmpd.1
#usr/share/man/man1/sntp.1
#usr/share/man/man1/update-leap.1
#usr/share/man/man5/ntp.conf.5
etc/modprobe.d
etc/modprobe.d/btmrvl_sdio.conf
etc/modprobe.d/cfg80211.conf
+etc/modprobe.d/nf_conntrack.conf
etc/modprobe.d/pcspeaker.conf
etc/modules.conf
etc/mtab
#usr/share/zoneinfo/America/Eirunepe
#usr/share/zoneinfo/America/El_Salvador
#usr/share/zoneinfo/America/Ensenada
+#usr/share/zoneinfo/America/Fort_Nelson
#usr/share/zoneinfo/America/Fort_Wayne
#usr/share/zoneinfo/America/Fortaleza
#usr/share/zoneinfo/America/Glace_Bay
#usr/share/zoneinfo/posix/America/Eirunepe
#usr/share/zoneinfo/posix/America/El_Salvador
#usr/share/zoneinfo/posix/America/Ensenada
+#usr/share/zoneinfo/posix/America/Fort_Nelson
#usr/share/zoneinfo/posix/America/Fort_Wayne
#usr/share/zoneinfo/posix/America/Fortaleza
#usr/share/zoneinfo/posix/America/Glace_Bay
#usr/share/zoneinfo/right/America/Eirunepe
#usr/share/zoneinfo/right/America/El_Salvador
#usr/share/zoneinfo/right/America/Ensenada
+#usr/share/zoneinfo/right/America/Fort_Nelson
#usr/share/zoneinfo/right/America/Fort_Wayne
#usr/share/zoneinfo/right/America/Fortaleza
#usr/share/zoneinfo/right/America/Glace_Bay
#usr/lib/ldscripts/i386linux.xn
#usr/lib/ldscripts/i386linux.xr
#usr/lib/ldscripts/i386linux.xu
-#usr/lib/libbfd-2.22.so
+#usr/lib/libbfd-2.24.so
#usr/lib/libbfd.a
#usr/lib/libbfd.la
#usr/lib/libbfd.so
#usr/lib/libiberty.a
-#usr/lib/libopcodes-2.22.so
+#usr/lib/libopcodes-2.24.so
#usr/lib/libopcodes.a
#usr/lib/libopcodes.la
#usr/lib/libopcodes.so
#usr/bin/cpp
#usr/bin/g++
#usr/bin/gcc
-#usr/bin/gccbug
+#usr/bin/gcc-ar
+#usr/bin/gcc-nm
+#usr/bin/gcc-ranlib
#usr/bin/gcov
#usr/bin/x86_64-unknown-linux-gnu-c++
#usr/bin/x86_64-unknown-linux-gnu-g++
#usr/bin/x86_64-unknown-linux-gnu-gcc
-#usr/bin/x86_64-unknown-linux-gnu-gcc-4.4.7
+#usr/bin/x86_64-unknown-linux-gnu-gcc-4.9.3
+#usr/bin/x86_64-unknown-linux-gnu-gcc-ar
+#usr/bin/x86_64-unknown-linux-gnu-gcc-nm
+#usr/bin/x86_64-unknown-linux-gnu-gcc-ranlib
#usr/include/c++
-#usr/include/c++/4.4.7
-#usr/include/c++/4.4.7/algorithm
-#usr/include/c++/4.4.7/array
-#usr/include/c++/4.4.7/backward
-#usr/include/c++/4.4.7/backward/auto_ptr.h
-#usr/include/c++/4.4.7/backward/backward_warning.h
-#usr/include/c++/4.4.7/backward/binders.h
-#usr/include/c++/4.4.7/backward/hash_fun.h
-#usr/include/c++/4.4.7/backward/hash_map
-#usr/include/c++/4.4.7/backward/hash_set
-#usr/include/c++/4.4.7/backward/hashtable.h
-#usr/include/c++/4.4.7/backward/strstream
-#usr/include/c++/4.4.7/bits
-#usr/include/c++/4.4.7/bits/algorithmfwd.h
-#usr/include/c++/4.4.7/bits/allocator.h
-#usr/include/c++/4.4.7/bits/atomic_0.h
-#usr/include/c++/4.4.7/bits/atomic_2.h
-#usr/include/c++/4.4.7/bits/atomicfwd_c.h
-#usr/include/c++/4.4.7/bits/atomicfwd_cxx.h
-#usr/include/c++/4.4.7/bits/basic_ios.h
-#usr/include/c++/4.4.7/bits/basic_ios.tcc
-#usr/include/c++/4.4.7/bits/basic_string.h
-#usr/include/c++/4.4.7/bits/basic_string.tcc
-#usr/include/c++/4.4.7/bits/boost_concept_check.h
-#usr/include/c++/4.4.7/bits/char_traits.h
-#usr/include/c++/4.4.7/bits/cmath.tcc
-#usr/include/c++/4.4.7/bits/codecvt.h
-#usr/include/c++/4.4.7/bits/concept_check.h
-#usr/include/c++/4.4.7/bits/cpp_type_traits.h
-#usr/include/c++/4.4.7/bits/deque.tcc
-#usr/include/c++/4.4.7/bits/forward_list.h
-#usr/include/c++/4.4.7/bits/forward_list.tcc
-#usr/include/c++/4.4.7/bits/fstream.tcc
-#usr/include/c++/4.4.7/bits/functexcept.h
-#usr/include/c++/4.4.7/bits/functional_hash.h
-#usr/include/c++/4.4.7/bits/gslice.h
-#usr/include/c++/4.4.7/bits/gslice_array.h
-#usr/include/c++/4.4.7/bits/hashtable.h
-#usr/include/c++/4.4.7/bits/indirect_array.h
-#usr/include/c++/4.4.7/bits/ios_base.h
-#usr/include/c++/4.4.7/bits/istream.tcc
-#usr/include/c++/4.4.7/bits/list.tcc
-#usr/include/c++/4.4.7/bits/locale_classes.h
-#usr/include/c++/4.4.7/bits/locale_classes.tcc
-#usr/include/c++/4.4.7/bits/locale_facets.h
-#usr/include/c++/4.4.7/bits/locale_facets.tcc
-#usr/include/c++/4.4.7/bits/locale_facets_nonio.h
-#usr/include/c++/4.4.7/bits/locale_facets_nonio.tcc
-#usr/include/c++/4.4.7/bits/localefwd.h
-#usr/include/c++/4.4.7/bits/mask_array.h
-#usr/include/c++/4.4.7/bits/move.h
-#usr/include/c++/4.4.7/bits/ostream.tcc
-#usr/include/c++/4.4.7/bits/ostream_insert.h
-#usr/include/c++/4.4.7/bits/postypes.h
-#usr/include/c++/4.4.7/bits/shared_ptr.h
-#usr/include/c++/4.4.7/bits/slice_array.h
-#usr/include/c++/4.4.7/bits/sstream.tcc
-#usr/include/c++/4.4.7/bits/stl_algo.h
-#usr/include/c++/4.4.7/bits/stl_algobase.h
-#usr/include/c++/4.4.7/bits/stl_bvector.h
-#usr/include/c++/4.4.7/bits/stl_construct.h
-#usr/include/c++/4.4.7/bits/stl_deque.h
-#usr/include/c++/4.4.7/bits/stl_function.h
-#usr/include/c++/4.4.7/bits/stl_heap.h
-#usr/include/c++/4.4.7/bits/stl_iterator.h
-#usr/include/c++/4.4.7/bits/stl_iterator_base_funcs.h
-#usr/include/c++/4.4.7/bits/stl_iterator_base_types.h
-#usr/include/c++/4.4.7/bits/stl_list.h
-#usr/include/c++/4.4.7/bits/stl_map.h
-#usr/include/c++/4.4.7/bits/stl_multimap.h
-#usr/include/c++/4.4.7/bits/stl_multiset.h
-#usr/include/c++/4.4.7/bits/stl_numeric.h
-#usr/include/c++/4.4.7/bits/stl_pair.h
-#usr/include/c++/4.4.7/bits/stl_queue.h
-#usr/include/c++/4.4.7/bits/stl_raw_storage_iter.h
-#usr/include/c++/4.4.7/bits/stl_relops.h
-#usr/include/c++/4.4.7/bits/stl_set.h
-#usr/include/c++/4.4.7/bits/stl_stack.h
-#usr/include/c++/4.4.7/bits/stl_tempbuf.h
-#usr/include/c++/4.4.7/bits/stl_tree.h
-#usr/include/c++/4.4.7/bits/stl_uninitialized.h
-#usr/include/c++/4.4.7/bits/stl_vector.h
-#usr/include/c++/4.4.7/bits/stream_iterator.h
-#usr/include/c++/4.4.7/bits/streambuf.tcc
-#usr/include/c++/4.4.7/bits/streambuf_iterator.h
-#usr/include/c++/4.4.7/bits/stringfwd.h
-#usr/include/c++/4.4.7/bits/unique_ptr.h
-#usr/include/c++/4.4.7/bits/valarray_after.h
-#usr/include/c++/4.4.7/bits/valarray_array.h
-#usr/include/c++/4.4.7/bits/valarray_array.tcc
-#usr/include/c++/4.4.7/bits/valarray_before.h
-#usr/include/c++/4.4.7/bits/vector.tcc
-#usr/include/c++/4.4.7/bitset
-#usr/include/c++/4.4.7/c++0x_warning.h
-#usr/include/c++/4.4.7/cassert
-#usr/include/c++/4.4.7/ccomplex
-#usr/include/c++/4.4.7/cctype
-#usr/include/c++/4.4.7/cerrno
-#usr/include/c++/4.4.7/cfenv
-#usr/include/c++/4.4.7/cfloat
-#usr/include/c++/4.4.7/chrono
-#usr/include/c++/4.4.7/cinttypes
-#usr/include/c++/4.4.7/ciso646
-#usr/include/c++/4.4.7/climits
-#usr/include/c++/4.4.7/clocale
-#usr/include/c++/4.4.7/cmath
-#usr/include/c++/4.4.7/complex
-#usr/include/c++/4.4.7/complex.h
-#usr/include/c++/4.4.7/condition_variable
-#usr/include/c++/4.4.7/csetjmp
-#usr/include/c++/4.4.7/csignal
-#usr/include/c++/4.4.7/cstdarg
-#usr/include/c++/4.4.7/cstdatomic
-#usr/include/c++/4.4.7/cstdbool
-#usr/include/c++/4.4.7/cstddef
-#usr/include/c++/4.4.7/cstdint
-#usr/include/c++/4.4.7/cstdio
-#usr/include/c++/4.4.7/cstdlib
-#usr/include/c++/4.4.7/cstring
-#usr/include/c++/4.4.7/ctgmath
-#usr/include/c++/4.4.7/ctime
-#usr/include/c++/4.4.7/cwchar
-#usr/include/c++/4.4.7/cwctype
-#usr/include/c++/4.4.7/cxxabi-forced.h
-#usr/include/c++/4.4.7/cxxabi.h
-#usr/include/c++/4.4.7/debug
-#usr/include/c++/4.4.7/debug/bitset
-#usr/include/c++/4.4.7/debug/debug.h
-#usr/include/c++/4.4.7/debug/deque
-#usr/include/c++/4.4.7/debug/formatter.h
-#usr/include/c++/4.4.7/debug/functions.h
-#usr/include/c++/4.4.7/debug/list
-#usr/include/c++/4.4.7/debug/macros.h
-#usr/include/c++/4.4.7/debug/map
-#usr/include/c++/4.4.7/debug/map.h
-#usr/include/c++/4.4.7/debug/multimap.h
-#usr/include/c++/4.4.7/debug/multiset.h
-#usr/include/c++/4.4.7/debug/safe_base.h
-#usr/include/c++/4.4.7/debug/safe_iterator.h
-#usr/include/c++/4.4.7/debug/safe_iterator.tcc
-#usr/include/c++/4.4.7/debug/safe_sequence.h
-#usr/include/c++/4.4.7/debug/set
-#usr/include/c++/4.4.7/debug/set.h
-#usr/include/c++/4.4.7/debug/string
-#usr/include/c++/4.4.7/debug/unordered_map
-#usr/include/c++/4.4.7/debug/unordered_set
-#usr/include/c++/4.4.7/debug/vector
-#usr/include/c++/4.4.7/deque
-#usr/include/c++/4.4.7/exception
-#usr/include/c++/4.4.7/exception_defines.h
-#usr/include/c++/4.4.7/exception_ptr.h
-#usr/include/c++/4.4.7/ext
-#usr/include/c++/4.4.7/ext/algorithm
-#usr/include/c++/4.4.7/ext/array_allocator.h
-#usr/include/c++/4.4.7/ext/atomicity.h
-#usr/include/c++/4.4.7/ext/bitmap_allocator.h
-#usr/include/c++/4.4.7/ext/cast.h
-#usr/include/c++/4.4.7/ext/codecvt_specializations.h
-#usr/include/c++/4.4.7/ext/concurrence.h
-#usr/include/c++/4.4.7/ext/debug_allocator.h
-#usr/include/c++/4.4.7/ext/enc_filebuf.h
-#usr/include/c++/4.4.7/ext/extptr_allocator.h
-#usr/include/c++/4.4.7/ext/functional
-#usr/include/c++/4.4.7/ext/hash_map
-#usr/include/c++/4.4.7/ext/hash_set
-#usr/include/c++/4.4.7/ext/iterator
-#usr/include/c++/4.4.7/ext/malloc_allocator.h
-#usr/include/c++/4.4.7/ext/memory
-#usr/include/c++/4.4.7/ext/mt_allocator.h
-#usr/include/c++/4.4.7/ext/new_allocator.h
-#usr/include/c++/4.4.7/ext/numeric
-#usr/include/c++/4.4.7/ext/numeric_traits.h
-#usr/include/c++/4.4.7/ext/pb_ds
-#usr/include/c++/4.4.7/ext/pb_ds/assoc_container.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail
-#usr/include/c++/4.4.7/ext/pb_ds/detail/basic_tree_policy
-#usr/include/c++/4.4.7/ext/pb_ds/detail/basic_tree_policy/basic_tree_policy_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/basic_tree_policy/null_node_metadata.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/basic_tree_policy/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/basic_types.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/bin_search_tree_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/cond_dtor_entry_dealtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/cond_key_dtor_entry_dealtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/node_iterators.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/point_iterators.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/r_erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/rotate_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/bin_search_tree_/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/const_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/const_point_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/entry_cmp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/entry_pred.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/resize_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binary_heap_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_/binomial_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/binomial_heap_base_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/binomial_heap_base_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/cc_ht_map_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/cmp_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/cond_key_dtor_entry_dealtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/debug_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/debug_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/entry_list_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/erase_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/erase_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/find_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/insert_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/insert_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/resize_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/resize_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/resize_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/size_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/standard_policies.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cc_hash_table_map_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/cond_dealtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/container_base_dispatch.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/debug_map_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/eq_fn
-#usr/include/c++/4.4.7/ext/pb_ds/detail/eq_fn/eq_by_less.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/eq_fn/hash_eq_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/debug_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/debug_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/erase_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/erase_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/find_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/find_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/gp_ht_map_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/insert_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/insert_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/iterator_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/resize_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/resize_no_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/resize_store_hash_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/standard_policies.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/gp_hash_table_map_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/direct_mask_range_hashing_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/direct_mod_range_hashing_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/linear_probe_fn_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/mask_based_range_hashing.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/mod_based_range_hashing.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/probe_fn_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/quadratic_probe_fn_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/ranged_hash_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/ranged_probe_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/sample_probe_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/sample_range_hashing.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/sample_ranged_hash_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/hash_fn/sample_ranged_probe_fn.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/const_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/const_point_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/left_child_next_sibling_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/node.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/null_metadata.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/left_child_next_sibling_heap_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/constructor_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/entry_metadata_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/lu_map_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_map_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_policy
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_policy/counter_lu_metadata.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_policy/counter_lu_policy_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_policy/mtf_lu_policy_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/list_update_policy/sample_update_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/cond_dtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/node_iterators.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/ov_tree_map_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/ov_tree_map_/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/pairing_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pairing_heap_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/child_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/cond_dtor_entry_dealtor.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/const_child_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/head.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/insert_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/internal_node.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/iterators_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/leaf.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/node_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/node_iterators.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/node_metadata_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/pat_trie_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/point_iterators.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/policy_access_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/r_erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/rotate_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/split_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/split_join_branch_bag.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/synth_e_access_traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/pat_trie_/update_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/priority_queue_base_dispatch.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/node.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/rb_tree_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rb_tree_map_/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/rc.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/rc_binomial_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/rc_binomial_heap_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/cc_hash_max_collision_check_resize_trigger_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/hash_exponential_size_policy_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_size_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/hash_prime_size_policy_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/hash_standard_resize_policy_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/sample_resize_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/sample_resize_trigger.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/resize_policy/sample_size_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/info_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/node.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/splay_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/splay_tree_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/splay_tree_/traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/standard_policies.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/constructors_destructor_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/debug_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/erase_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/find_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/insert_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/split_join_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/thin_heap_.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/thin_heap_/trace_fn_imps.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_policy
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_policy/node_metadata_selector.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_policy/null_node_update_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_policy/order_statistics_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_policy/sample_tree_node_update.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/tree_trace_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/node_metadata_selector.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/null_node_update_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/order_statistics_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/prefix_search_node_update_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/sample_trie_e_access_traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/sample_trie_node_update.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/string_trie_e_access_traits_imp.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/trie_policy/trie_policy_base.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/type_utils.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/types_traits.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/unordered_iterator
-#usr/include/c++/4.4.7/ext/pb_ds/detail/unordered_iterator/const_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/unordered_iterator/const_point_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/unordered_iterator/iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/detail/unordered_iterator/point_iterator.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/exception.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/hash_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/list_update_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/priority_queue.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/tag_and_trait.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/tree_policy.hpp
-#usr/include/c++/4.4.7/ext/pb_ds/trie_policy.hpp
-#usr/include/c++/4.4.7/ext/pod_char_traits.h
-#usr/include/c++/4.4.7/ext/pointer.h
-#usr/include/c++/4.4.7/ext/pool_allocator.h
-#usr/include/c++/4.4.7/ext/rb_tree
-#usr/include/c++/4.4.7/ext/rc_string_base.h
-#usr/include/c++/4.4.7/ext/rope
-#usr/include/c++/4.4.7/ext/ropeimpl.h
-#usr/include/c++/4.4.7/ext/slist
-#usr/include/c++/4.4.7/ext/sso_string_base.h
-#usr/include/c++/4.4.7/ext/stdio_filebuf.h
-#usr/include/c++/4.4.7/ext/stdio_sync_filebuf.h
-#usr/include/c++/4.4.7/ext/string_conversions.h
-#usr/include/c++/4.4.7/ext/throw_allocator.h
-#usr/include/c++/4.4.7/ext/type_traits.h
-#usr/include/c++/4.4.7/ext/typelist.h
-#usr/include/c++/4.4.7/ext/vstring.h
-#usr/include/c++/4.4.7/ext/vstring.tcc
-#usr/include/c++/4.4.7/ext/vstring_fwd.h
-#usr/include/c++/4.4.7/ext/vstring_util.h
-#usr/include/c++/4.4.7/fenv.h
-#usr/include/c++/4.4.7/forward_list
-#usr/include/c++/4.4.7/fstream
-#usr/include/c++/4.4.7/functional
-#usr/include/c++/4.4.7/initializer_list
-#usr/include/c++/4.4.7/iomanip
-#usr/include/c++/4.4.7/ios
-#usr/include/c++/4.4.7/iosfwd
-#usr/include/c++/4.4.7/iostream
-#usr/include/c++/4.4.7/istream
-#usr/include/c++/4.4.7/iterator
-#usr/include/c++/4.4.7/limits
-#usr/include/c++/4.4.7/list
-#usr/include/c++/4.4.7/locale
-#usr/include/c++/4.4.7/map
-#usr/include/c++/4.4.7/memory
-#usr/include/c++/4.4.7/mutex
-#usr/include/c++/4.4.7/new
-#usr/include/c++/4.4.7/numeric
-#usr/include/c++/4.4.7/ostream
-#usr/include/c++/4.4.7/parallel
-#usr/include/c++/4.4.7/parallel/algo.h
-#usr/include/c++/4.4.7/parallel/algobase.h
-#usr/include/c++/4.4.7/parallel/algorithm
-#usr/include/c++/4.4.7/parallel/algorithmfwd.h
-#usr/include/c++/4.4.7/parallel/balanced_quicksort.h
-#usr/include/c++/4.4.7/parallel/base.h
-#usr/include/c++/4.4.7/parallel/basic_iterator.h
-#usr/include/c++/4.4.7/parallel/checkers.h
-#usr/include/c++/4.4.7/parallel/compatibility.h
-#usr/include/c++/4.4.7/parallel/compiletime_settings.h
-#usr/include/c++/4.4.7/parallel/equally_split.h
-#usr/include/c++/4.4.7/parallel/features.h
-#usr/include/c++/4.4.7/parallel/find.h
-#usr/include/c++/4.4.7/parallel/find_selectors.h
-#usr/include/c++/4.4.7/parallel/for_each.h
-#usr/include/c++/4.4.7/parallel/for_each_selectors.h
-#usr/include/c++/4.4.7/parallel/iterator.h
-#usr/include/c++/4.4.7/parallel/list_partition.h
-#usr/include/c++/4.4.7/parallel/losertree.h
-#usr/include/c++/4.4.7/parallel/merge.h
-#usr/include/c++/4.4.7/parallel/multiseq_selection.h
-#usr/include/c++/4.4.7/parallel/multiway_merge.h
-#usr/include/c++/4.4.7/parallel/multiway_mergesort.h
-#usr/include/c++/4.4.7/parallel/numeric
-#usr/include/c++/4.4.7/parallel/numericfwd.h
-#usr/include/c++/4.4.7/parallel/omp_loop.h
-#usr/include/c++/4.4.7/parallel/omp_loop_static.h
-#usr/include/c++/4.4.7/parallel/par_loop.h
-#usr/include/c++/4.4.7/parallel/parallel.h
-#usr/include/c++/4.4.7/parallel/partial_sum.h
-#usr/include/c++/4.4.7/parallel/partition.h
-#usr/include/c++/4.4.7/parallel/queue.h
-#usr/include/c++/4.4.7/parallel/quicksort.h
-#usr/include/c++/4.4.7/parallel/random_number.h
-#usr/include/c++/4.4.7/parallel/random_shuffle.h
-#usr/include/c++/4.4.7/parallel/search.h
-#usr/include/c++/4.4.7/parallel/set_operations.h
-#usr/include/c++/4.4.7/parallel/settings.h
-#usr/include/c++/4.4.7/parallel/sort.h
-#usr/include/c++/4.4.7/parallel/tags.h
-#usr/include/c++/4.4.7/parallel/types.h
-#usr/include/c++/4.4.7/parallel/unique_copy.h
-#usr/include/c++/4.4.7/parallel/workstealing.h
-#usr/include/c++/4.4.7/queue
-#usr/include/c++/4.4.7/random
-#usr/include/c++/4.4.7/ratio
-#usr/include/c++/4.4.7/regex
-#usr/include/c++/4.4.7/set
-#usr/include/c++/4.4.7/sstream
-#usr/include/c++/4.4.7/stack
-#usr/include/c++/4.4.7/stdatomic.h
-#usr/include/c++/4.4.7/stdexcept
-#usr/include/c++/4.4.7/streambuf
-#usr/include/c++/4.4.7/string
-#usr/include/c++/4.4.7/system_error
-#usr/include/c++/4.4.7/tgmath.h
-#usr/include/c++/4.4.7/thread
-#usr/include/c++/4.4.7/tr1
-#usr/include/c++/4.4.7/tr1/array
-#usr/include/c++/4.4.7/tr1/bessel_function.tcc
-#usr/include/c++/4.4.7/tr1/beta_function.tcc
-#usr/include/c++/4.4.7/tr1/ccomplex
-#usr/include/c++/4.4.7/tr1/cctype
-#usr/include/c++/4.4.7/tr1/cfenv
-#usr/include/c++/4.4.7/tr1/cfloat
-#usr/include/c++/4.4.7/tr1/cinttypes
-#usr/include/c++/4.4.7/tr1/climits
-#usr/include/c++/4.4.7/tr1/cmath
-#usr/include/c++/4.4.7/tr1/complex
-#usr/include/c++/4.4.7/tr1/complex.h
-#usr/include/c++/4.4.7/tr1/cstdarg
-#usr/include/c++/4.4.7/tr1/cstdbool
-#usr/include/c++/4.4.7/tr1/cstdint
-#usr/include/c++/4.4.7/tr1/cstdio
-#usr/include/c++/4.4.7/tr1/cstdlib
-#usr/include/c++/4.4.7/tr1/ctgmath
-#usr/include/c++/4.4.7/tr1/ctime
-#usr/include/c++/4.4.7/tr1/ctype.h
-#usr/include/c++/4.4.7/tr1/cwchar
-#usr/include/c++/4.4.7/tr1/cwctype
-#usr/include/c++/4.4.7/tr1/ell_integral.tcc
-#usr/include/c++/4.4.7/tr1/exp_integral.tcc
-#usr/include/c++/4.4.7/tr1/fenv.h
-#usr/include/c++/4.4.7/tr1/float.h
-#usr/include/c++/4.4.7/tr1/functional
-#usr/include/c++/4.4.7/tr1/functional_hash.h
-#usr/include/c++/4.4.7/tr1/gamma.tcc
-#usr/include/c++/4.4.7/tr1/hashtable.h
-#usr/include/c++/4.4.7/tr1/hypergeometric.tcc
-#usr/include/c++/4.4.7/tr1/inttypes.h
-#usr/include/c++/4.4.7/tr1/legendre_function.tcc
-#usr/include/c++/4.4.7/tr1/limits.h
-#usr/include/c++/4.4.7/tr1/math.h
-#usr/include/c++/4.4.7/tr1/memory
-#usr/include/c++/4.4.7/tr1/modified_bessel_func.tcc
-#usr/include/c++/4.4.7/tr1/poly_hermite.tcc
-#usr/include/c++/4.4.7/tr1/poly_laguerre.tcc
-#usr/include/c++/4.4.7/tr1/random
-#usr/include/c++/4.4.7/tr1/regex
-#usr/include/c++/4.4.7/tr1/riemann_zeta.tcc
-#usr/include/c++/4.4.7/tr1/shared_ptr.h
-#usr/include/c++/4.4.7/tr1/special_function_util.h
-#usr/include/c++/4.4.7/tr1/stdarg.h
-#usr/include/c++/4.4.7/tr1/stdbool.h
-#usr/include/c++/4.4.7/tr1/stdint.h
-#usr/include/c++/4.4.7/tr1/stdio.h
-#usr/include/c++/4.4.7/tr1/stdlib.h
-#usr/include/c++/4.4.7/tr1/tgmath.h
-#usr/include/c++/4.4.7/tr1/tuple
-#usr/include/c++/4.4.7/tr1/type_traits
-#usr/include/c++/4.4.7/tr1/unordered_map
-#usr/include/c++/4.4.7/tr1/unordered_set
-#usr/include/c++/4.4.7/tr1/utility
-#usr/include/c++/4.4.7/tr1/wchar.h
-#usr/include/c++/4.4.7/tr1/wctype.h
-#usr/include/c++/4.4.7/tr1_impl
-#usr/include/c++/4.4.7/tr1_impl/array
-#usr/include/c++/4.4.7/tr1_impl/boost_sp_counted_base.h
-#usr/include/c++/4.4.7/tr1_impl/cctype
-#usr/include/c++/4.4.7/tr1_impl/cfenv
-#usr/include/c++/4.4.7/tr1_impl/cinttypes
-#usr/include/c++/4.4.7/tr1_impl/cmath
-#usr/include/c++/4.4.7/tr1_impl/complex
-#usr/include/c++/4.4.7/tr1_impl/cstdint
-#usr/include/c++/4.4.7/tr1_impl/cstdio
-#usr/include/c++/4.4.7/tr1_impl/cstdlib
-#usr/include/c++/4.4.7/tr1_impl/cwchar
-#usr/include/c++/4.4.7/tr1_impl/cwctype
-#usr/include/c++/4.4.7/tr1_impl/functional
-#usr/include/c++/4.4.7/tr1_impl/functional_hash.h
-#usr/include/c++/4.4.7/tr1_impl/hashtable
-#usr/include/c++/4.4.7/tr1_impl/hashtable_policy.h
-#usr/include/c++/4.4.7/tr1_impl/random
-#usr/include/c++/4.4.7/tr1_impl/random.tcc
-#usr/include/c++/4.4.7/tr1_impl/regex
-#usr/include/c++/4.4.7/tr1_impl/type_traits
-#usr/include/c++/4.4.7/tr1_impl/unordered_map
-#usr/include/c++/4.4.7/tr1_impl/unordered_set
-#usr/include/c++/4.4.7/tr1_impl/utility
-#usr/include/c++/4.4.7/tuple
-#usr/include/c++/4.4.7/type_traits
-#usr/include/c++/4.4.7/typeinfo
-#usr/include/c++/4.4.7/unordered_map
-#usr/include/c++/4.4.7/unordered_set
-#usr/include/c++/4.4.7/utility
-#usr/include/c++/4.4.7/valarray
-#usr/include/c++/4.4.7/vector
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/atomic_word.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/basic_file.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/c++allocator.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/c++config.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/c++io.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/c++locale.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/cpu_defines.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/ctype_base.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/ctype_inline.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/ctype_noninline.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/cxxabi_tweaks.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/error_constants.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/extc++.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/gthr-default.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/gthr-posix.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/gthr-single.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/gthr-tpf.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/gthr.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/messages_members.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/os_defines.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/stdc++.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/stdtr1c++.h
-#usr/include/c++/4.4.7/x86_64-unknown-linux-gnu/bits/time_members.h
-#usr/info
-#usr/info/cpp.info
-#usr/info/cppinternals.info
-#usr/info/dir
-#usr/info/gcc.info
-#usr/info/gccinstall.info
-#usr/info/gccint.info
-#usr/info/libgomp.info
+#usr/include/c++/4.9.3
+#usr/include/c++/4.9.3/algorithm
+#usr/include/c++/4.9.3/array
+#usr/include/c++/4.9.3/atomic
+#usr/include/c++/4.9.3/backward
+#usr/include/c++/4.9.3/backward/auto_ptr.h
+#usr/include/c++/4.9.3/backward/backward_warning.h
+#usr/include/c++/4.9.3/backward/binders.h
+#usr/include/c++/4.9.3/backward/hash_fun.h
+#usr/include/c++/4.9.3/backward/hash_map
+#usr/include/c++/4.9.3/backward/hash_set
+#usr/include/c++/4.9.3/backward/hashtable.h
+#usr/include/c++/4.9.3/backward/strstream
+#usr/include/c++/4.9.3/bits
+#usr/include/c++/4.9.3/bits/algorithmfwd.h
+#usr/include/c++/4.9.3/bits/alloc_traits.h
+#usr/include/c++/4.9.3/bits/allocator.h
+#usr/include/c++/4.9.3/bits/atomic_base.h
+#usr/include/c++/4.9.3/bits/atomic_lockfree_defines.h
+#usr/include/c++/4.9.3/bits/basic_ios.h
+#usr/include/c++/4.9.3/bits/basic_ios.tcc
+#usr/include/c++/4.9.3/bits/basic_string.h
+#usr/include/c++/4.9.3/bits/basic_string.tcc
+#usr/include/c++/4.9.3/bits/boost_concept_check.h
+#usr/include/c++/4.9.3/bits/c++0x_warning.h
+#usr/include/c++/4.9.3/bits/c++14_warning.h
+#usr/include/c++/4.9.3/bits/char_traits.h
+#usr/include/c++/4.9.3/bits/codecvt.h
+#usr/include/c++/4.9.3/bits/concept_check.h
+#usr/include/c++/4.9.3/bits/cpp_type_traits.h
+#usr/include/c++/4.9.3/bits/cxxabi_forced.h
+#usr/include/c++/4.9.3/bits/deque.tcc
+#usr/include/c++/4.9.3/bits/enable_special_members.h
+#usr/include/c++/4.9.3/bits/exception_defines.h
+#usr/include/c++/4.9.3/bits/exception_ptr.h
+#usr/include/c++/4.9.3/bits/forward_list.h
+#usr/include/c++/4.9.3/bits/forward_list.tcc
+#usr/include/c++/4.9.3/bits/fstream.tcc
+#usr/include/c++/4.9.3/bits/functexcept.h
+#usr/include/c++/4.9.3/bits/functional_hash.h
+#usr/include/c++/4.9.3/bits/gslice.h
+#usr/include/c++/4.9.3/bits/gslice_array.h
+#usr/include/c++/4.9.3/bits/hash_bytes.h
+#usr/include/c++/4.9.3/bits/hashtable.h
+#usr/include/c++/4.9.3/bits/hashtable_policy.h
+#usr/include/c++/4.9.3/bits/indirect_array.h
+#usr/include/c++/4.9.3/bits/ios_base.h
+#usr/include/c++/4.9.3/bits/istream.tcc
+#usr/include/c++/4.9.3/bits/list.tcc
+#usr/include/c++/4.9.3/bits/locale_classes.h
+#usr/include/c++/4.9.3/bits/locale_classes.tcc
+#usr/include/c++/4.9.3/bits/locale_facets.h
+#usr/include/c++/4.9.3/bits/locale_facets.tcc
+#usr/include/c++/4.9.3/bits/locale_facets_nonio.h
+#usr/include/c++/4.9.3/bits/locale_facets_nonio.tcc
+#usr/include/c++/4.9.3/bits/localefwd.h
+#usr/include/c++/4.9.3/bits/mask_array.h
+#usr/include/c++/4.9.3/bits/memoryfwd.h
+#usr/include/c++/4.9.3/bits/move.h
+#usr/include/c++/4.9.3/bits/nested_exception.h
+#usr/include/c++/4.9.3/bits/ostream.tcc
+#usr/include/c++/4.9.3/bits/ostream_insert.h
+#usr/include/c++/4.9.3/bits/parse_numbers.h
+#usr/include/c++/4.9.3/bits/postypes.h
+#usr/include/c++/4.9.3/bits/predefined_ops.h
+#usr/include/c++/4.9.3/bits/ptr_traits.h
+#usr/include/c++/4.9.3/bits/random.h
+#usr/include/c++/4.9.3/bits/random.tcc
+#usr/include/c++/4.9.3/bits/range_access.h
+#usr/include/c++/4.9.3/bits/regex.h
+#usr/include/c++/4.9.3/bits/regex.tcc
+#usr/include/c++/4.9.3/bits/regex_automaton.h
+#usr/include/c++/4.9.3/bits/regex_automaton.tcc
+#usr/include/c++/4.9.3/bits/regex_compiler.h
+#usr/include/c++/4.9.3/bits/regex_compiler.tcc
+#usr/include/c++/4.9.3/bits/regex_constants.h
+#usr/include/c++/4.9.3/bits/regex_error.h
+#usr/include/c++/4.9.3/bits/regex_executor.h
+#usr/include/c++/4.9.3/bits/regex_executor.tcc
+#usr/include/c++/4.9.3/bits/regex_scanner.h
+#usr/include/c++/4.9.3/bits/regex_scanner.tcc
+#usr/include/c++/4.9.3/bits/shared_ptr.h
+#usr/include/c++/4.9.3/bits/shared_ptr_base.h
+#usr/include/c++/4.9.3/bits/slice_array.h
+#usr/include/c++/4.9.3/bits/sstream.tcc
+#usr/include/c++/4.9.3/bits/stl_algo.h
+#usr/include/c++/4.9.3/bits/stl_algobase.h
+#usr/include/c++/4.9.3/bits/stl_bvector.h
+#usr/include/c++/4.9.3/bits/stl_construct.h
+#usr/include/c++/4.9.3/bits/stl_deque.h
+#usr/include/c++/4.9.3/bits/stl_function.h
+#usr/include/c++/4.9.3/bits/stl_heap.h
+#usr/include/c++/4.9.3/bits/stl_iterator.h
+#usr/include/c++/4.9.3/bits/stl_iterator_base_funcs.h
+#usr/include/c++/4.9.3/bits/stl_iterator_base_types.h
+#usr/include/c++/4.9.3/bits/stl_list.h
+#usr/include/c++/4.9.3/bits/stl_map.h
+#usr/include/c++/4.9.3/bits/stl_multimap.h
+#usr/include/c++/4.9.3/bits/stl_multiset.h
+#usr/include/c++/4.9.3/bits/stl_numeric.h
+#usr/include/c++/4.9.3/bits/stl_pair.h
+#usr/include/c++/4.9.3/bits/stl_queue.h
+#usr/include/c++/4.9.3/bits/stl_raw_storage_iter.h
+#usr/include/c++/4.9.3/bits/stl_relops.h
+#usr/include/c++/4.9.3/bits/stl_set.h
+#usr/include/c++/4.9.3/bits/stl_stack.h
+#usr/include/c++/4.9.3/bits/stl_tempbuf.h
+#usr/include/c++/4.9.3/bits/stl_tree.h
+#usr/include/c++/4.9.3/bits/stl_uninitialized.h
+#usr/include/c++/4.9.3/bits/stl_vector.h
+#usr/include/c++/4.9.3/bits/stream_iterator.h
+#usr/include/c++/4.9.3/bits/streambuf.tcc
+#usr/include/c++/4.9.3/bits/streambuf_iterator.h
+#usr/include/c++/4.9.3/bits/stringfwd.h
+#usr/include/c++/4.9.3/bits/unique_ptr.h
+#usr/include/c++/4.9.3/bits/unordered_map.h
+#usr/include/c++/4.9.3/bits/unordered_set.h
+#usr/include/c++/4.9.3/bits/uses_allocator.h
+#usr/include/c++/4.9.3/bits/valarray_after.h
+#usr/include/c++/4.9.3/bits/valarray_array.h
+#usr/include/c++/4.9.3/bits/valarray_array.tcc
+#usr/include/c++/4.9.3/bits/valarray_before.h
+#usr/include/c++/4.9.3/bits/vector.tcc
+#usr/include/c++/4.9.3/bitset
+#usr/include/c++/4.9.3/cassert
+#usr/include/c++/4.9.3/ccomplex
+#usr/include/c++/4.9.3/cctype
+#usr/include/c++/4.9.3/cerrno
+#usr/include/c++/4.9.3/cfenv
+#usr/include/c++/4.9.3/cfloat
+#usr/include/c++/4.9.3/chrono
+#usr/include/c++/4.9.3/cinttypes
+#usr/include/c++/4.9.3/ciso646
+#usr/include/c++/4.9.3/climits
+#usr/include/c++/4.9.3/clocale
+#usr/include/c++/4.9.3/cmath
+#usr/include/c++/4.9.3/complex
+#usr/include/c++/4.9.3/complex.h
+#usr/include/c++/4.9.3/condition_variable
+#usr/include/c++/4.9.3/csetjmp
+#usr/include/c++/4.9.3/csignal
+#usr/include/c++/4.9.3/cstdalign
+#usr/include/c++/4.9.3/cstdarg
+#usr/include/c++/4.9.3/cstdbool
+#usr/include/c++/4.9.3/cstddef
+#usr/include/c++/4.9.3/cstdint
+#usr/include/c++/4.9.3/cstdio
+#usr/include/c++/4.9.3/cstdlib
+#usr/include/c++/4.9.3/cstring
+#usr/include/c++/4.9.3/ctgmath
+#usr/include/c++/4.9.3/ctime
+#usr/include/c++/4.9.3/cwchar
+#usr/include/c++/4.9.3/cwctype
+#usr/include/c++/4.9.3/cxxabi.h
+#usr/include/c++/4.9.3/debug
+#usr/include/c++/4.9.3/debug/array
+#usr/include/c++/4.9.3/debug/bitset
+#usr/include/c++/4.9.3/debug/debug.h
+#usr/include/c++/4.9.3/debug/deque
+#usr/include/c++/4.9.3/debug/formatter.h
+#usr/include/c++/4.9.3/debug/forward_list
+#usr/include/c++/4.9.3/debug/functions.h
+#usr/include/c++/4.9.3/debug/list
+#usr/include/c++/4.9.3/debug/macros.h
+#usr/include/c++/4.9.3/debug/map
+#usr/include/c++/4.9.3/debug/map.h
+#usr/include/c++/4.9.3/debug/multimap.h
+#usr/include/c++/4.9.3/debug/multiset.h
+#usr/include/c++/4.9.3/debug/safe_base.h
+#usr/include/c++/4.9.3/debug/safe_iterator.h
+#usr/include/c++/4.9.3/debug/safe_iterator.tcc
+#usr/include/c++/4.9.3/debug/safe_local_iterator.h
+#usr/include/c++/4.9.3/debug/safe_local_iterator.tcc
+#usr/include/c++/4.9.3/debug/safe_sequence.h
+#usr/include/c++/4.9.3/debug/safe_sequence.tcc
+#usr/include/c++/4.9.3/debug/safe_unordered_base.h
+#usr/include/c++/4.9.3/debug/safe_unordered_container.h
+#usr/include/c++/4.9.3/debug/safe_unordered_container.tcc
+#usr/include/c++/4.9.3/debug/set
+#usr/include/c++/4.9.3/debug/set.h
+#usr/include/c++/4.9.3/debug/string
+#usr/include/c++/4.9.3/debug/unordered_map
+#usr/include/c++/4.9.3/debug/unordered_set
+#usr/include/c++/4.9.3/debug/vector
+#usr/include/c++/4.9.3/decimal
+#usr/include/c++/4.9.3/decimal/decimal
+#usr/include/c++/4.9.3/decimal/decimal.h
+#usr/include/c++/4.9.3/deque
+#usr/include/c++/4.9.3/exception
+#usr/include/c++/4.9.3/experimental
+#usr/include/c++/4.9.3/experimental/optional
+#usr/include/c++/4.9.3/experimental/string_view
+#usr/include/c++/4.9.3/experimental/string_view.tcc
+#usr/include/c++/4.9.3/ext
+#usr/include/c++/4.9.3/ext/algorithm
+#usr/include/c++/4.9.3/ext/aligned_buffer.h
+#usr/include/c++/4.9.3/ext/alloc_traits.h
+#usr/include/c++/4.9.3/ext/array_allocator.h
+#usr/include/c++/4.9.3/ext/atomicity.h
+#usr/include/c++/4.9.3/ext/bitmap_allocator.h
+#usr/include/c++/4.9.3/ext/cast.h
+#usr/include/c++/4.9.3/ext/cmath
+#usr/include/c++/4.9.3/ext/codecvt_specializations.h
+#usr/include/c++/4.9.3/ext/concurrence.h
+#usr/include/c++/4.9.3/ext/debug_allocator.h
+#usr/include/c++/4.9.3/ext/enc_filebuf.h
+#usr/include/c++/4.9.3/ext/extptr_allocator.h
+#usr/include/c++/4.9.3/ext/functional
+#usr/include/c++/4.9.3/ext/hash_map
+#usr/include/c++/4.9.3/ext/hash_set
+#usr/include/c++/4.9.3/ext/iterator
+#usr/include/c++/4.9.3/ext/malloc_allocator.h
+#usr/include/c++/4.9.3/ext/memory
+#usr/include/c++/4.9.3/ext/mt_allocator.h
+#usr/include/c++/4.9.3/ext/new_allocator.h
+#usr/include/c++/4.9.3/ext/numeric
+#usr/include/c++/4.9.3/ext/numeric_traits.h
+#usr/include/c++/4.9.3/ext/pb_ds
+#usr/include/c++/4.9.3/ext/pb_ds/assoc_container.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/bin_search_tree_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/node_iterators.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/point_iterators.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/r_erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/rotate_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/bin_search_tree_/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/entry_cmp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/entry_pred.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/point_const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/resize_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binary_heap_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_/binomial_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/binomial_heap_base_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/binomial_heap_base_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/branch_policy
+#usr/include/c++/4.9.3/ext/pb_ds/detail/branch_policy/branch_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/branch_policy/null_node_metadata.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/branch_policy/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/cc_ht_map_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/cmp_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/cond_key_dtor_entry_dealtor.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/debug_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/debug_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/entry_list_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/erase_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/erase_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/find_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/insert_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/insert_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/resize_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/resize_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/resize_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/size_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cc_hash_table_map_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/cond_dealtor.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/container_base_dispatch.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/debug_map_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/eq_fn
+#usr/include/c++/4.9.3/ext/pb_ds/detail/eq_fn/eq_by_less.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/eq_fn/hash_eq_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/debug_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/debug_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/erase_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/erase_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/find_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/find_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/gp_ht_map_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/insert_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/insert_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/iterator_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/resize_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/resize_no_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/resize_store_hash_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/gp_hash_table_map_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/direct_mask_range_hashing_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/direct_mod_range_hashing_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/linear_probe_fn_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/mask_based_range_hashing.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/mod_based_range_hashing.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/probe_fn_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/quadratic_probe_fn_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/ranged_hash_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/ranged_probe_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/sample_probe_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/sample_range_hashing.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/sample_ranged_hash_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/hash_fn/sample_ranged_probe_fn.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/left_child_next_sibling_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/node.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/point_const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/left_child_next_sibling_heap_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/constructor_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/entry_metadata_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/lu_map_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_map_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_policy
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_policy/lu_counter_metadata.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/list_update_policy/sample_update_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/node_iterators.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/ov_tree_map_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/ov_tree_map_/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/pairing_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pairing_heap_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/insert_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/iterators_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/pat_trie_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/pat_trie_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/policy_access_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/r_erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/rotate_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/split_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/synth_access_traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/pat_trie_/update_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/priority_queue_base_dispatch.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/node.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/rb_tree_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rb_tree_map_/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/rc.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/rc_binomial_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/rc_binomial_heap_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/cc_hash_max_collision_check_resize_trigger_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/hash_exponential_size_policy_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_size_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/hash_prime_size_policy_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/hash_standard_resize_policy_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/sample_resize_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/sample_resize_trigger.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/resize_policy/sample_size_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/info_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/node.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/splay_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/splay_tree_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/splay_tree_/traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/standard_policies.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/constructors_destructor_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/debug_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/erase_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/find_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/insert_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/split_join_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/thin_heap_.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/thin_heap_/trace_fn_imps.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/tree_policy
+#usr/include/c++/4.9.3/ext/pb_ds/detail/tree_policy/node_metadata_selector.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/tree_policy/order_statistics_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/tree_policy/sample_tree_node_update.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/tree_trace_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/node_metadata_selector.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/order_statistics_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/prefix_search_node_update_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/sample_trie_access_traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/sample_trie_node_update.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/trie_policy_base.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/trie_policy/trie_string_access_traits_imp.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/type_utils.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/types_traits.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/unordered_iterator
+#usr/include/c++/4.9.3/ext/pb_ds/detail/unordered_iterator/const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/unordered_iterator/iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/unordered_iterator/point_const_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/detail/unordered_iterator/point_iterator.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/exception.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/hash_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/list_update_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/priority_queue.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/tag_and_trait.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/tree_policy.hpp
+#usr/include/c++/4.9.3/ext/pb_ds/trie_policy.hpp
+#usr/include/c++/4.9.3/ext/pod_char_traits.h
+#usr/include/c++/4.9.3/ext/pointer.h
+#usr/include/c++/4.9.3/ext/pool_allocator.h
+#usr/include/c++/4.9.3/ext/random
+#usr/include/c++/4.9.3/ext/random.tcc
+#usr/include/c++/4.9.3/ext/rb_tree
+#usr/include/c++/4.9.3/ext/rc_string_base.h
+#usr/include/c++/4.9.3/ext/rope
+#usr/include/c++/4.9.3/ext/ropeimpl.h
+#usr/include/c++/4.9.3/ext/slist
+#usr/include/c++/4.9.3/ext/sso_string_base.h
+#usr/include/c++/4.9.3/ext/stdio_filebuf.h
+#usr/include/c++/4.9.3/ext/stdio_sync_filebuf.h
+#usr/include/c++/4.9.3/ext/string_conversions.h
+#usr/include/c++/4.9.3/ext/throw_allocator.h
+#usr/include/c++/4.9.3/ext/type_traits.h
+#usr/include/c++/4.9.3/ext/typelist.h
+#usr/include/c++/4.9.3/ext/vstring.h
+#usr/include/c++/4.9.3/ext/vstring.tcc
+#usr/include/c++/4.9.3/ext/vstring_fwd.h
+#usr/include/c++/4.9.3/ext/vstring_util.h
+#usr/include/c++/4.9.3/fenv.h
+#usr/include/c++/4.9.3/forward_list
+#usr/include/c++/4.9.3/fstream
+#usr/include/c++/4.9.3/functional
+#usr/include/c++/4.9.3/future
+#usr/include/c++/4.9.3/initializer_list
+#usr/include/c++/4.9.3/iomanip
+#usr/include/c++/4.9.3/ios
+#usr/include/c++/4.9.3/iosfwd
+#usr/include/c++/4.9.3/iostream
+#usr/include/c++/4.9.3/istream
+#usr/include/c++/4.9.3/iterator
+#usr/include/c++/4.9.3/limits
+#usr/include/c++/4.9.3/list
+#usr/include/c++/4.9.3/locale
+#usr/include/c++/4.9.3/map
+#usr/include/c++/4.9.3/memory
+#usr/include/c++/4.9.3/mutex
+#usr/include/c++/4.9.3/new
+#usr/include/c++/4.9.3/numeric
+#usr/include/c++/4.9.3/ostream
+#usr/include/c++/4.9.3/parallel
+#usr/include/c++/4.9.3/parallel/algo.h
+#usr/include/c++/4.9.3/parallel/algobase.h
+#usr/include/c++/4.9.3/parallel/algorithm
+#usr/include/c++/4.9.3/parallel/algorithmfwd.h
+#usr/include/c++/4.9.3/parallel/balanced_quicksort.h
+#usr/include/c++/4.9.3/parallel/base.h
+#usr/include/c++/4.9.3/parallel/basic_iterator.h
+#usr/include/c++/4.9.3/parallel/checkers.h
+#usr/include/c++/4.9.3/parallel/compatibility.h
+#usr/include/c++/4.9.3/parallel/compiletime_settings.h
+#usr/include/c++/4.9.3/parallel/equally_split.h
+#usr/include/c++/4.9.3/parallel/features.h
+#usr/include/c++/4.9.3/parallel/find.h
+#usr/include/c++/4.9.3/parallel/find_selectors.h
+#usr/include/c++/4.9.3/parallel/for_each.h
+#usr/include/c++/4.9.3/parallel/for_each_selectors.h
+#usr/include/c++/4.9.3/parallel/iterator.h
+#usr/include/c++/4.9.3/parallel/list_partition.h
+#usr/include/c++/4.9.3/parallel/losertree.h
+#usr/include/c++/4.9.3/parallel/merge.h
+#usr/include/c++/4.9.3/parallel/multiseq_selection.h
+#usr/include/c++/4.9.3/parallel/multiway_merge.h
+#usr/include/c++/4.9.3/parallel/multiway_mergesort.h
+#usr/include/c++/4.9.3/parallel/numeric
+#usr/include/c++/4.9.3/parallel/numericfwd.h
+#usr/include/c++/4.9.3/parallel/omp_loop.h
+#usr/include/c++/4.9.3/parallel/omp_loop_static.h
+#usr/include/c++/4.9.3/parallel/par_loop.h
+#usr/include/c++/4.9.3/parallel/parallel.h
+#usr/include/c++/4.9.3/parallel/partial_sum.h
+#usr/include/c++/4.9.3/parallel/partition.h
+#usr/include/c++/4.9.3/parallel/queue.h
+#usr/include/c++/4.9.3/parallel/quicksort.h
+#usr/include/c++/4.9.3/parallel/random_number.h
+#usr/include/c++/4.9.3/parallel/random_shuffle.h
+#usr/include/c++/4.9.3/parallel/search.h
+#usr/include/c++/4.9.3/parallel/set_operations.h
+#usr/include/c++/4.9.3/parallel/settings.h
+#usr/include/c++/4.9.3/parallel/sort.h
+#usr/include/c++/4.9.3/parallel/tags.h
+#usr/include/c++/4.9.3/parallel/types.h
+#usr/include/c++/4.9.3/parallel/unique_copy.h
+#usr/include/c++/4.9.3/parallel/workstealing.h
+#usr/include/c++/4.9.3/profile
+#usr/include/c++/4.9.3/profile/array
+#usr/include/c++/4.9.3/profile/base.h
+#usr/include/c++/4.9.3/profile/bitset
+#usr/include/c++/4.9.3/profile/deque
+#usr/include/c++/4.9.3/profile/forward_list
+#usr/include/c++/4.9.3/profile/impl
+#usr/include/c++/4.9.3/profile/impl/profiler.h
+#usr/include/c++/4.9.3/profile/impl/profiler_algos.h
+#usr/include/c++/4.9.3/profile/impl/profiler_container_size.h
+#usr/include/c++/4.9.3/profile/impl/profiler_hash_func.h
+#usr/include/c++/4.9.3/profile/impl/profiler_hashtable_size.h
+#usr/include/c++/4.9.3/profile/impl/profiler_list_to_slist.h
+#usr/include/c++/4.9.3/profile/impl/profiler_list_to_vector.h
+#usr/include/c++/4.9.3/profile/impl/profiler_map_to_unordered_map.h
+#usr/include/c++/4.9.3/profile/impl/profiler_node.h
+#usr/include/c++/4.9.3/profile/impl/profiler_state.h
+#usr/include/c++/4.9.3/profile/impl/profiler_trace.h
+#usr/include/c++/4.9.3/profile/impl/profiler_vector_size.h
+#usr/include/c++/4.9.3/profile/impl/profiler_vector_to_list.h
+#usr/include/c++/4.9.3/profile/iterator_tracker.h
+#usr/include/c++/4.9.3/profile/list
+#usr/include/c++/4.9.3/profile/map
+#usr/include/c++/4.9.3/profile/map.h
+#usr/include/c++/4.9.3/profile/multimap.h
+#usr/include/c++/4.9.3/profile/multiset.h
+#usr/include/c++/4.9.3/profile/set
+#usr/include/c++/4.9.3/profile/set.h
+#usr/include/c++/4.9.3/profile/unordered_base.h
+#usr/include/c++/4.9.3/profile/unordered_map
+#usr/include/c++/4.9.3/profile/unordered_set
+#usr/include/c++/4.9.3/profile/vector
+#usr/include/c++/4.9.3/queue
+#usr/include/c++/4.9.3/random
+#usr/include/c++/4.9.3/ratio
+#usr/include/c++/4.9.3/regex
+#usr/include/c++/4.9.3/scoped_allocator
+#usr/include/c++/4.9.3/set
+#usr/include/c++/4.9.3/shared_mutex
+#usr/include/c++/4.9.3/sstream
+#usr/include/c++/4.9.3/stack
+#usr/include/c++/4.9.3/stdexcept
+#usr/include/c++/4.9.3/streambuf
+#usr/include/c++/4.9.3/string
+#usr/include/c++/4.9.3/system_error
+#usr/include/c++/4.9.3/tgmath.h
+#usr/include/c++/4.9.3/thread
+#usr/include/c++/4.9.3/tr1
+#usr/include/c++/4.9.3/tr1/array
+#usr/include/c++/4.9.3/tr1/bessel_function.tcc
+#usr/include/c++/4.9.3/tr1/beta_function.tcc
+#usr/include/c++/4.9.3/tr1/ccomplex
+#usr/include/c++/4.9.3/tr1/cctype
+#usr/include/c++/4.9.3/tr1/cfenv
+#usr/include/c++/4.9.3/tr1/cfloat
+#usr/include/c++/4.9.3/tr1/cinttypes
+#usr/include/c++/4.9.3/tr1/climits
+#usr/include/c++/4.9.3/tr1/cmath
+#usr/include/c++/4.9.3/tr1/complex
+#usr/include/c++/4.9.3/tr1/complex.h
+#usr/include/c++/4.9.3/tr1/cstdarg
+#usr/include/c++/4.9.3/tr1/cstdbool
+#usr/include/c++/4.9.3/tr1/cstdint
+#usr/include/c++/4.9.3/tr1/cstdio
+#usr/include/c++/4.9.3/tr1/cstdlib
+#usr/include/c++/4.9.3/tr1/ctgmath
+#usr/include/c++/4.9.3/tr1/ctime
+#usr/include/c++/4.9.3/tr1/ctype.h
+#usr/include/c++/4.9.3/tr1/cwchar
+#usr/include/c++/4.9.3/tr1/cwctype
+#usr/include/c++/4.9.3/tr1/ell_integral.tcc
+#usr/include/c++/4.9.3/tr1/exp_integral.tcc
+#usr/include/c++/4.9.3/tr1/fenv.h
+#usr/include/c++/4.9.3/tr1/float.h
+#usr/include/c++/4.9.3/tr1/functional
+#usr/include/c++/4.9.3/tr1/functional_hash.h
+#usr/include/c++/4.9.3/tr1/gamma.tcc
+#usr/include/c++/4.9.3/tr1/hashtable.h
+#usr/include/c++/4.9.3/tr1/hashtable_policy.h
+#usr/include/c++/4.9.3/tr1/hypergeometric.tcc
+#usr/include/c++/4.9.3/tr1/inttypes.h
+#usr/include/c++/4.9.3/tr1/legendre_function.tcc
+#usr/include/c++/4.9.3/tr1/limits.h
+#usr/include/c++/4.9.3/tr1/math.h
+#usr/include/c++/4.9.3/tr1/memory
+#usr/include/c++/4.9.3/tr1/modified_bessel_func.tcc
+#usr/include/c++/4.9.3/tr1/poly_hermite.tcc
+#usr/include/c++/4.9.3/tr1/poly_laguerre.tcc
+#usr/include/c++/4.9.3/tr1/random
+#usr/include/c++/4.9.3/tr1/random.h
+#usr/include/c++/4.9.3/tr1/random.tcc
+#usr/include/c++/4.9.3/tr1/regex
+#usr/include/c++/4.9.3/tr1/riemann_zeta.tcc
+#usr/include/c++/4.9.3/tr1/shared_ptr.h
+#usr/include/c++/4.9.3/tr1/special_function_util.h
+#usr/include/c++/4.9.3/tr1/stdarg.h
+#usr/include/c++/4.9.3/tr1/stdbool.h
+#usr/include/c++/4.9.3/tr1/stdint.h
+#usr/include/c++/4.9.3/tr1/stdio.h
+#usr/include/c++/4.9.3/tr1/stdlib.h
+#usr/include/c++/4.9.3/tr1/tgmath.h
+#usr/include/c++/4.9.3/tr1/tuple
+#usr/include/c++/4.9.3/tr1/type_traits
+#usr/include/c++/4.9.3/tr1/unordered_map
+#usr/include/c++/4.9.3/tr1/unordered_map.h
+#usr/include/c++/4.9.3/tr1/unordered_set
+#usr/include/c++/4.9.3/tr1/unordered_set.h
+#usr/include/c++/4.9.3/tr1/utility
+#usr/include/c++/4.9.3/tr1/wchar.h
+#usr/include/c++/4.9.3/tr1/wctype.h
+#usr/include/c++/4.9.3/tr2
+#usr/include/c++/4.9.3/tr2/bool_set
+#usr/include/c++/4.9.3/tr2/bool_set.tcc
+#usr/include/c++/4.9.3/tr2/dynamic_bitset
+#usr/include/c++/4.9.3/tr2/dynamic_bitset.tcc
+#usr/include/c++/4.9.3/tr2/ratio
+#usr/include/c++/4.9.3/tr2/type_traits
+#usr/include/c++/4.9.3/tuple
+#usr/include/c++/4.9.3/type_traits
+#usr/include/c++/4.9.3/typeindex
+#usr/include/c++/4.9.3/typeinfo
+#usr/include/c++/4.9.3/unordered_map
+#usr/include/c++/4.9.3/unordered_set
+#usr/include/c++/4.9.3/utility
+#usr/include/c++/4.9.3/valarray
+#usr/include/c++/4.9.3/vector
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/atomic_word.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/basic_file.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/c++allocator.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/c++config.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/c++io.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/c++locale.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/cpu_defines.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/ctype_base.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/ctype_inline.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/cxxabi_tweaks.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/error_constants.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/extc++.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/gthr-default.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/gthr-posix.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/gthr-single.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/gthr.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/messages_members.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/opt_random.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/os_defines.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/stdc++.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/stdtr1c++.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/bits/time_members.h
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/ext
+#usr/include/c++/4.9.3/x86_64-unknown-linux-gnu/ext/opt_random.h
#usr/lib/gcc
#usr/lib/gcc/x86_64-unknown-linux-gnu
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/cc1
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/cc1plus
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/collect2
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/crtbegin.o
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/crtbeginS.o
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/crtbeginT.o
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/crtend.o
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/crtendS.o
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/crtfastmath.o
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/crtprec32.o
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/crtprec64.o
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/crtprec80.o
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/finclude
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include-fixed
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include-fixed/README
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include-fixed/limits.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include-fixed/syslimits.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/ammintrin.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/avxintrin.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/bmmintrin.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/cpuid.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/cross-stdarg.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/emmintrin.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/float.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/immintrin.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/iso646.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/mf-runtime.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/mm3dnow.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/mm_malloc.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/mmintrin-common.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/mmintrin.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/nmmintrin.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/omp.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/pmmintrin.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/smmintrin.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/ssp
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/ssp/ssp.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/ssp/stdio.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/ssp/string.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/ssp/unistd.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/stdarg.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/stdbool.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/stddef.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/stdfix.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/tmmintrin.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/unwind.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/varargs.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/wmmintrin.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/x86intrin.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/include/xmmintrin.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/install-tools
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/install-tools/fixinc.sh
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/install-tools/fixinc_list
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/install-tools/fixincl
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/install-tools/gsyslimits.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/install-tools/include
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/install-tools/include/README
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/install-tools/include/limits.h
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/install-tools/macro_list
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/install-tools/mkheaders
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/install-tools/mkheaders.conf
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/install-tools/mkinstalldirs
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/libgcc.a
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/libgcc_eh.a
-#usr/lib/gcc/x86_64-unknown-linux-gnu/4.4.7/libgcov.a
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/cc1
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/cc1plus
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/collect2
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/crtbegin.o
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/crtbeginS.o
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/crtbeginT.o
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/crtend.o
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/crtendS.o
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/crtfastmath.o
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/crtprec32.o
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/crtprec64.o
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/crtprec80.o
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/finclude
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include-fixed
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include-fixed/README
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include-fixed/limits.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include-fixed/syslimits.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/adxintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/ammintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/avx2intrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/avx512cdintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/avx512erintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/avx512fintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/avx512pfintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/avxintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/bmi2intrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/bmiintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/bmmintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/cilk.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/cilk_api.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/cilk_api_linux.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/cilk_stub.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/cilk_undocumented.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/common.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/holder.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/hyperobject_base.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/metaprogramming.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/reducer.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/reducer_file.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/reducer_list.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/reducer_max.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/reducer_min.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/reducer_min_max.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/reducer_opadd.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/reducer_opand.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/reducer_opmul.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/reducer_opor.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/reducer_opxor.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/reducer_ostream.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cilk/reducer_string.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cpuid.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/cross-stdarg.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/emmintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/f16cintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/float.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/fma4intrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/fmaintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/fxsrintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/ia32intrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/immintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/iso646.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/lwpintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/lzcntintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/mm3dnow.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/mm_malloc.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/mmintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/nmmintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/omp.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/pmmintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/popcntintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/prfchwintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/quadmath.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/quadmath_weak.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/rdseedintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/rtmintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/sanitizer
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/sanitizer/asan_interface.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/sanitizer/common_interface_defs.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/sanitizer/lsan_interface.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/shaintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/smmintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/ssp
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/ssp/ssp.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/ssp/stdio.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/ssp/string.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/ssp/unistd.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/stdalign.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/stdarg.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/stdatomic.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/stdbool.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/stddef.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/stdfix.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/stdint-gcc.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/stdint.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/stdnoreturn.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/tbmintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/tmmintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/unwind.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/varargs.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/wmmintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/x86intrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/xmmintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/xopintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/xsaveintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/xsaveoptintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/include/xtestintrin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/install-tools
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/install-tools/fixinc.sh
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/install-tools/fixinc_list
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/install-tools/fixincl
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/install-tools/gsyslimits.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/install-tools/include
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/install-tools/include/README
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/install-tools/include/limits.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/install-tools/macro_list
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/install-tools/mkheaders
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/install-tools/mkheaders.conf
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/install-tools/mkinstalldirs
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/libgcc.a
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/libgcc_eh.a
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/libgcov.a
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/liblto_plugin.la
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/liblto_plugin.so
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/liblto_plugin.so.0
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/liblto_plugin.so.0.0.0
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/lto-wrapper
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/lto1
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/gengtype
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/gtype.state
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/ada
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/ada/gcc-interface
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/ada/gcc-interface/ada-tree.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/alias.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/all-tree.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/alloc-pool.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/ansidecl.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/attribs.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/auto-host.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/b-header-vars
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/basic-block.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/bitmap.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/builtins.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/bversion.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/c-family
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/c-family/c-common.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/c-family/c-common.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/c-family/c-objc.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/c-family/c-pragma.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/c-family/c-pretty-print.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/c-tree.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/calls.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cfg-flags.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cfgexpand.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cfghooks.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cfgloop.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cgraph.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cif-code.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cilk-builtins.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cilkplus.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/dbxelf.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/elfos.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/glibc-stdint.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/gnu-user.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/i386
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/i386/att.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/i386/biarch64.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/i386/gnu-user-common.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/i386/gnu-user64.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/i386/i386-opts.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/i386/i386-protos.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/i386/i386.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/i386/linux-common.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/i386/linux64.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/i386/stringop.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/i386/unix.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/i386/x86-64.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/i386/x86-tune.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/initfini-array.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/linux-android.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/linux-protos.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/linux.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/config/vxworks-dummy.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/configargs.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/context.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/coretypes.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cp
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cp/cp-tree.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cp/cp-tree.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cp/cxx-pretty-print.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cp/name-lookup.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cp/type-utils.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cppdefault.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/cpplib.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/debug.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/defaults.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/df.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/diagnostic-color.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/diagnostic-core.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/diagnostic.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/diagnostic.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/double-int.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/dumpfile.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/emit-rtl.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/except.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/filenames.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/fixed-value.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/flag-types.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/flags.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/fold-const.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/function.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gcc-plugin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gcc-symtab.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/genrtl.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/ggc.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gimple-builder.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gimple-expr.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gimple-fold.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gimple-iterator.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gimple-low.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gimple-pretty-print.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gimple-ssa.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gimple-walk.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gimple.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gimple.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gimplify-me.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gimplify.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gsstruct.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gtm-builtins.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/gtype-desc.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/hard-reg-set.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/hash-table.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/hashtab.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/highlev-plugin-common.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/hwint.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/incpath.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/input.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/insn-codes.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/insn-constants.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/insn-flags.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/insn-modes.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/insn-notes.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/internal-fn.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/internal-fn.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/intl.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/ipa-prop.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/ipa-ref-inline.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/ipa-ref.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/ipa-reference.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/ipa-utils.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/is-a.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/java
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/java/java-tree.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/langhooks.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/libiberty.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/line-map.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/machmode.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/md5.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/mode-classes.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/objc
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/objc/objc-tree.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/obstack.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/omp-builtins.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/options.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/opts.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/output.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/params.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/params.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/pass-instances.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/pass_manager.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/plugin-api.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/plugin-version.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/plugin.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/plugin.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/pointer-set.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/predict.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/predict.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/prefix.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/pretty-print.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/print-rtl.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/print-tree.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/real.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/realmpfr.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/reg-notes.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/regset.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/resource.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/rtl.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/rtl.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/safe-ctype.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/sanitizer.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/sbitmap.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/splay-tree.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/ssa-iterators.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/statistics.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/stmt.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/stor-layout.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/stringpool.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/symtab.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/sync-builtins.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/system.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/target-hooks-macros.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/target.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/target.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/timevar.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/timevar.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tm-preds.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tm.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tm_p.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/toplev.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-cfg.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-cfgcleanup.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-check.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-core.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-dfa.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-dump.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-eh.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-hasher.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-inline.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-into-ssa.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-iterator.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-nested.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-object-size.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-outof-ssa.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-parloops.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-pass.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-phinodes.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-pretty-print.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-ssa-address.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-ssa-alias.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-ssa-coalesce.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-ssa-dom.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-ssa-loop-ivopts.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-ssa-loop-manip.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-ssa-loop-niter.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-ssa-loop.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-ssa-operands.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-ssa-sccvn.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-ssa-ter.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-ssa-threadedge.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-ssa-threadupdate.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-ssa.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree-ssanames.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/tree.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/treestruct.def
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/varasm.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/vec.h
+#usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/plugin/include/version.h
+#usr/lib/libasan.a
+#usr/lib/libasan.la
+#usr/lib/libasan.so
+usr/lib/libasan.so.1
+usr/lib/libasan.so.1.0.0
+#usr/lib/libasan_preinit.o
+#usr/lib/libatomic.a
+#usr/lib/libatomic.la
+#usr/lib/libatomic.so
+usr/lib/libatomic.so.1
+usr/lib/libatomic.so.1.1.0
+#usr/lib/libcilkrts.a
+#usr/lib/libcilkrts.la
+#usr/lib/libcilkrts.so
+usr/lib/libcilkrts.so.5
+usr/lib/libcilkrts.so.5.0.0
+#usr/lib/libcilkrts.spec
#usr/lib/libgomp.a
#usr/lib/libgomp.la
#usr/lib/libgomp.so
usr/lib/libgomp.so.1
usr/lib/libgomp.so.1.0.0
#usr/lib/libgomp.spec
-#usr/lib/libmudflap.a
-#usr/lib/libmudflap.la
-#usr/lib/libmudflap.so
-usr/lib/libmudflap.so.0
-usr/lib/libmudflap.so.0.0.0
-#usr/lib/libmudflapth.a
-#usr/lib/libmudflapth.la
-#usr/lib/libmudflapth.so
-usr/lib/libmudflapth.so.0
-usr/lib/libmudflapth.so.0.0.0
+#usr/lib/libitm.a
+#usr/lib/libitm.la
+#usr/lib/libitm.so
+usr/lib/libitm.so.1
+usr/lib/libitm.so.1.0.0
+#usr/lib/libitm.spec
+#usr/lib/liblsan.a
+#usr/lib/liblsan.la
+#usr/lib/liblsan.so
+usr/lib/liblsan.so.0
+usr/lib/liblsan.so.0.0.0
+#usr/lib/libquadmath.a
+#usr/lib/libquadmath.la
+#usr/lib/libquadmath.so
+usr/lib/libquadmath.so.0
+usr/lib/libquadmath.so.0.0.0
+#usr/lib/libsanitizer.spec
#usr/lib/libssp.a
#usr/lib/libssp.la
#usr/lib/libssp.so
#usr/lib/libssp_nonshared.a
#usr/lib/libssp_nonshared.la
#usr/lib/libstdc++.a
-usr/lib/libstdc++.so.6.0.13
+usr/lib/libstdc++.so.6.0.20
+#usr/lib/libstdc++.so.6.0.20-gdb.py
#usr/lib/libsupc++.a
#usr/lib/libsupc++.la
-#usr/man
-#usr/man/man1
-#usr/man/man1/cpp.1
-#usr/man/man1/g++.1
-#usr/man/man1/gcc.1
-#usr/man/man1/gcov.1
-#usr/man/man7
-#usr/man/man7/fsf-funding.7
-#usr/man/man7/gfdl.7
-#usr/man/man7/gpl.7
+#usr/lib/libtsan.a
+#usr/lib/libtsan.la
+#usr/lib/libtsan.so
+usr/lib/libtsan.so.0
+usr/lib/libtsan.so.0.0.0
+#usr/lib/libubsan.a
+#usr/lib/libubsan.la
+#usr/lib/libubsan.so
+usr/lib/libubsan.so.0
+usr/lib/libubsan.so.0.0.0
+#usr/lib/libvtv.a
+#usr/lib/libvtv.la
+#usr/lib/libvtv.so
+usr/lib/libvtv.so.0
+usr/lib/libvtv.so.0.0.0
+#usr/share/gcc-4.9.3
+#usr/share/gcc-4.9.3/python
+#usr/share/gcc-4.9.3/python/libstdcxx
+#usr/share/gcc-4.9.3/python/libstdcxx/__init__.py
+#usr/share/gcc-4.9.3/python/libstdcxx/v6
+#usr/share/gcc-4.9.3/python/libstdcxx/v6/__init__.py
+#usr/share/gcc-4.9.3/python/libstdcxx/v6/printers.py
+#usr/share/info/cpp.info
+#usr/share/info/cppinternals.info
+#usr/share/info/gcc.info
+#usr/share/info/gccinstall.info
+#usr/share/info/gccint.info
+#usr/share/info/libgomp.info
+#usr/share/info/libitm.info
+#usr/share/info/libquadmath.info
+#usr/share/man/man1/cpp.1
+#usr/share/man/man1/g++.1
+#usr/share/man/man1/gcc.1
+#usr/share/man/man1/gcov.1
+#usr/share/man/man7/fsf-funding.7
+#usr/share/man/man7/gfdl.7
+#usr/share/man/man7/gpl.7
#etc/rc.d/init.d/cyrus-sasl
etc/rc.d/init.d/dhcp
etc/rc.d/init.d/dhcrelay
+#etc/rc.d/init.d/dnsdist
etc/rc.d/init.d/dnsmasq
etc/rc.d/init.d/fcron
#etc/rc.d/init.d/fetchmail
+++ /dev/null
-etc/system-release
-etc/issue
--- /dev/null
+../../../common/bind
\ No newline at end of file
--- /dev/null
+etc/system-release
+etc/issue
+etc/dracut.conf
+etc/ppp/ip-up
+etc/rc.d/init.d/firewall
+etc/rc.d/init.d/networking/dhcpcd.exe
+etc/modprobe.d/nf_conntrack.conf
+srv/web/ipfire/cgi-bin/logs.cgi/firewalllog.dat
+srv/web/ipfire/cgi-bin/logs.cgi/firewalllogcountry.dat
+srv/web/ipfire/cgi-bin/logs.cgi/firewalllogip.dat
+srv/web/ipfire/cgi-bin/logs.cgi/firewalllogport.dat
+srv/web/ipfire/cgi-bin/logs.cgi/showrequestfromcountry.dat
+srv/web/ipfire/cgi-bin/logs.cgi/showrequestfromip.dat
+srv/web/ipfire/cgi-bin/logs.cgi/showrequestfromport.dat
+srv/web/ipfire/cgi-bin/optionsfw.cgi
+srv/web/ipfire/cgi-bin/ovpnmain.cgi
+srv/web/ipfire/cgi-bin/qos.cgi
+srv/web/ipfire/cgi-bin/webaccess.cgi
+usr/bin/pgrep
+usr/local/bin/qosctrl
+usr/local/bin/timectrl
+var/ipfire/dhcpc/dhcpcd-hooks/10-mtu
--- /dev/null
+../../../common/grep
\ No newline at end of file
--- /dev/null
+../../../common/openvpn
\ No newline at end of file
--- /dev/null
+../../../common/sed
\ No newline at end of file
--- /dev/null
+../../../common/squid
\ No newline at end of file
--- /dev/null
+../../../common/tzdata
\ No newline at end of file
--- /dev/null
+#!/bin/bash
+############################################################################
+# #
+# This file is part of the IPFire Firewall. #
+# #
+# IPFire is free software; you can redistribute it and/or modify #
+# it under the terms of the GNU General Public License as published by #
+# the Free Software Foundation; either version 3 of the License, or #
+# (at your option) any later version. #
+# #
+# IPFire is distributed in the hope that it will be useful, #
+# but WITHOUT ANY WARRANTY; without even the implied warranty of #
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
+# GNU General Public License for more details. #
+# #
+# You should have received a copy of the GNU General Public License #
+# along with IPFire; if not, write to the Free Software #
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA #
+# #
+# Copyright (C) 2016 IPFire-Team <info@ipfire.org>. #
+# #
+############################################################################
+#
+. /opt/pakfire/lib/functions.sh
+/usr/local/bin/backupctrl exclude >/dev/null 2>&1
+
+# Remove old core updates from pakfire cache to save space...
+core=99
+for (( i=1; i<=$core; i++ ))
+do
+ rm -f /var/cache/pakfire/core-upgrade-*-$i.ipfire
+done
+
+# Stop services
+/etc/init.d/squid stop
+/etc/init.d/dnsmasq stop
+
+# Extract files
+extract_files
+
+# Fix hardening flags in grub
+paxctl -mpexs /usr/bin/grub-script-check
+
+# Update Language cache
+# /usr/local/bin/update-lang-cache
+
+# Start services
+/etc/init.d/dnsmasq start
+/etc/init.d/sshd restart
+/etc/init.d/squid start
+
+# Delete old QoS enabled indicator
+rm -f /var/ipfire/qos/enable
+
+# This update need a reboot...
+#touch /var/run/need_reboot
+
+# Finish
+/etc/init.d/fireinfo start
+sendprofile
+# Update grub config to display new core version
+if [ -e /boot/grub/grub.cfg ]; then
+ grub-mkconfig -o /boot/grub/grub.cfg
+fi
+sync
+
+# Don't report the exitcode last command
+exit 0
--- /dev/null
+../../../common/dnsmasq
\ No newline at end of file
--- /dev/null
+../../../common/ntp
\ No newline at end of file
--- /dev/null
+etc/system-release
+etc/issue
+etc/rc.d/init.d/firewall
+etc/modprobe.d/nf_conntrack.conf
+srv/web/ipfire/cgi-bin/logs.cgi/firewalllog.dat
+srv/web/ipfire/cgi-bin/logs.cgi/firewalllogcountry.dat
+srv/web/ipfire/cgi-bin/logs.cgi/firewalllogip.dat
+srv/web/ipfire/cgi-bin/logs.cgi/firewalllogport.dat
+srv/web/ipfire/cgi-bin/logs.cgi/showrequestfromcountry.dat
+srv/web/ipfire/cgi-bin/logs.cgi/showrequestfromip.dat
+srv/web/ipfire/cgi-bin/logs.cgi/showrequestfromport.dat
+srv/web/ipfire/cgi-bin/optionsfw.cgi
+srv/web/ipfire/cgi-bin/ovpnmain.cgi
+srv/web/ipfire/cgi-bin/qos.cgi
+srv/web/ipfire/cgi-bin/webaccess.cgi
+usr/bin/pgrep
+usr/local/bin/qosctrl
+usr/local/bin/timectrl
--- /dev/null
+../../../common/openssh
\ No newline at end of file
--- /dev/null
+boot/config.txt
+etc/alternatives
+etc/collectd.custom
+etc/ipsec.conf
+etc/ipsec.secrets
+etc/ipsec.user.conf
+etc/ipsec.user.secrets
+etc/localtime
+etc/shadow
+etc/snort/snort.conf
+etc/ssh/ssh_config
+etc/ssh/sshd_config
+etc/ssl/openssl.cnf
+etc/sudoers
+etc/sysconfig/firewall.local
+etc/sysconfig/rc.local
+etc/udev/rules.d/30-persistent-network.rules
+srv/web/ipfire/html/proxy.pac
+var/ipfire/dma
+var/ipfire/time
+var/ipfire/ovpn
+var/lib/alternatives
+var/log/cache
+var/state/dhcp/dhcpd.leases
+var/updatecache
--- /dev/null
+usr/bin/dnsdist
+#usr/share/man/man1/dnsdist.1
+etc/rc.d/init.d/dnsdist
#usr/share/man/man5/nanorc.5
#usr/share/nano
usr/share/nano/asm.nanorc
+usr/share/nano/autoconf.nanorc
usr/share/nano/awk.nanorc
usr/share/nano/c.nanorc
#usr/share/nano/changelog.nanorc
usr/share/nano/mgp.nanorc
usr/share/nano/mutt.nanorc
usr/share/nano/nanorc.nanorc
+usr/share/nano/nftables.nanorc
usr/share/nano/objc.nanorc
usr/share/nano/ocaml.nanorc
usr/share/nano/patch.nanorc
#srv/web/owncloud/3rdparty/Console/Getopt.php
#srv/web/owncloud/3rdparty/Jcrop
#srv/web/owncloud/3rdparty/Jcrop/MIT-LICENSE.txt
-#srv/web/owncloud/3rdparty/Jcrop/README.md
#srv/web/owncloud/3rdparty/Jcrop/css
#srv/web/owncloud/3rdparty/Jcrop/css/Jcrop.gif
#srv/web/owncloud/3rdparty/Jcrop/css/jquery.Jcrop.css
#srv/web/owncloud/3rdparty/Patchwork/PHP/Shim/unidata/compatibilityDecomposition.ser
#srv/web/owncloud/3rdparty/Patchwork/PHP/Shim/unidata/lowerCase.ser
#srv/web/owncloud/3rdparty/Patchwork/PHP/Shim/unidata/upperCase.ser
-#srv/web/owncloud/3rdparty/Patchwork/README.md
#srv/web/owncloud/3rdparty/Patchwork/Utf8
#srv/web/owncloud/3rdparty/Patchwork/Utf8.php
#srv/web/owncloud/3rdparty/Patchwork/Utf8/Bootup
#srv/web/owncloud/3rdparty/css/chosen/chosen.css
#srv/web/owncloud/3rdparty/css/strengthify
#srv/web/owncloud/3rdparty/css/strengthify/LICENSE
-#srv/web/owncloud/3rdparty/css/strengthify/README.md
#srv/web/owncloud/3rdparty/css/strengthify/strengthify.css
#srv/web/owncloud/3rdparty/doctrine
#srv/web/owncloud/3rdparty/doctrine/common
#srv/web/owncloud/3rdparty/doctrine/common/.gitmodules
#srv/web/owncloud/3rdparty/doctrine/common/LICENSE
-#srv/web/owncloud/3rdparty/doctrine/common/README.md
#srv/web/owncloud/3rdparty/doctrine/common/UPGRADE_TO_2_1
#srv/web/owncloud/3rdparty/doctrine/common/UPGRADE_TO_2_2
#srv/web/owncloud/3rdparty/doctrine/common/build.properties
#srv/web/owncloud/3rdparty/doctrine/dbal
#srv/web/owncloud/3rdparty/doctrine/dbal/.gitmodules
#srv/web/owncloud/3rdparty/doctrine/dbal/LICENSE
-#srv/web/owncloud/3rdparty/doctrine/dbal/README.md
#srv/web/owncloud/3rdparty/doctrine/dbal/UPGRADE
#srv/web/owncloud/3rdparty/doctrine/dbal/bin
#srv/web/owncloud/3rdparty/doctrine/dbal/bin/doctrine-dbal
#srv/web/owncloud/3rdparty/doctrine/dbal/docs/design/SHARDING.md
#srv/web/owncloud/3rdparty/doctrine/dbal/docs/examples
#srv/web/owncloud/3rdparty/doctrine/dbal/docs/examples/sharding
-#srv/web/owncloud/3rdparty/doctrine/dbal/docs/examples/sharding/README.md
#srv/web/owncloud/3rdparty/doctrine/dbal/docs/examples/sharding/bootstrap.php
#srv/web/owncloud/3rdparty/doctrine/dbal/docs/examples/sharding/composer.json
#srv/web/owncloud/3rdparty/doctrine/dbal/docs/examples/sharding/create_schema.php
#srv/web/owncloud/3rdparty/doctrine/dbal/tests/travis/pgsql.travis.xml
#srv/web/owncloud/3rdparty/doctrine/dbal/tests/travis/sqlite.travis.xml
#srv/web/owncloud/3rdparty/fontawesome
-#srv/web/owncloud/3rdparty/fontawesome/README.md
#srv/web/owncloud/3rdparty/fontawesome/css
#srv/web/owncloud/3rdparty/fontawesome/css/font-awesome-ie7.min.css
#srv/web/owncloud/3rdparty/fontawesome/css/font-awesome.css
#srv/web/owncloud/3rdparty/james-heinrich
#srv/web/owncloud/3rdparty/james-heinrich/getid3
#srv/web/owncloud/3rdparty/james-heinrich/getid3/.gitattributes
-#srv/web/owncloud/3rdparty/james-heinrich/getid3/README.md
#srv/web/owncloud/3rdparty/james-heinrich/getid3/changelog.txt
#srv/web/owncloud/3rdparty/james-heinrich/getid3/composer.json
#srv/web/owncloud/3rdparty/james-heinrich/getid3/dependencies.txt
#srv/web/owncloud/3rdparty/js
#srv/web/owncloud/3rdparty/js/chosen
#srv/web/owncloud/3rdparty/js/chosen/LICENSE.md
-#srv/web/owncloud/3rdparty/js/chosen/README.md
#srv/web/owncloud/3rdparty/js/chosen/VERSION
#srv/web/owncloud/3rdparty/js/chosen/chosen.jquery.js
#srv/web/owncloud/3rdparty/js/chosen/chosen.jquery.min.js
#srv/web/owncloud/3rdparty/js/chosen/chosen.proto.js
#srv/web/owncloud/3rdparty/js/chosen/chosen.proto.min.js
#srv/web/owncloud/3rdparty/js/md5
-#srv/web/owncloud/3rdparty/js/md5/README.md
#srv/web/owncloud/3rdparty/js/md5/md5.js
#srv/web/owncloud/3rdparty/js/md5/md5.min.js
#srv/web/owncloud/3rdparty/js/strengthify
#srv/web/owncloud/3rdparty/js/strengthify/LICENSE
-#srv/web/owncloud/3rdparty/js/strengthify/README.md
#srv/web/owncloud/3rdparty/js/strengthify/jquery.strengthify.js
#srv/web/owncloud/3rdparty/kriswallsmith
#srv/web/owncloud/3rdparty/kriswallsmith/assetic
#srv/web/owncloud/3rdparty/kriswallsmith/assetic/CHANGELOG-1.2.md
#srv/web/owncloud/3rdparty/kriswallsmith/assetic/Gemfile
#srv/web/owncloud/3rdparty/kriswallsmith/assetic/LICENSE
-#srv/web/owncloud/3rdparty/kriswallsmith/assetic/README.md
#srv/web/owncloud/3rdparty/kriswallsmith/assetic/composer.json
#srv/web/owncloud/3rdparty/kriswallsmith/assetic/docs
#srv/web/owncloud/3rdparty/kriswallsmith/assetic/docs/en
#srv/web/owncloud/3rdparty/mcnetic
#srv/web/owncloud/3rdparty/mcnetic/phpzipstreamer
#srv/web/owncloud/3rdparty/mcnetic/phpzipstreamer/COPYING
-#srv/web/owncloud/3rdparty/mcnetic/phpzipstreamer/README.md
#srv/web/owncloud/3rdparty/mcnetic/phpzipstreamer/ZipStreamer.php
#srv/web/owncloud/3rdparty/miniColors
#srv/web/owncloud/3rdparty/miniColors/GPL-LICENSE.txt
#srv/web/owncloud/3rdparty/phpmailer/phpmailer
#srv/web/owncloud/3rdparty/phpmailer/phpmailer/LICENSE
#srv/web/owncloud/3rdparty/phpmailer/phpmailer/PHPMailerAutoload.php
-#srv/web/owncloud/3rdparty/phpmailer/phpmailer/README.md
#srv/web/owncloud/3rdparty/phpmailer/phpmailer/changelog.md
#srv/web/owncloud/3rdparty/phpmailer/phpmailer/class.phpmailer.php
#srv/web/owncloud/3rdparty/phpmailer/phpmailer/class.pop3.php
#srv/web/owncloud/3rdparty/phpseclib/phpseclib/.gitattributes
#srv/web/owncloud/3rdparty/phpseclib/phpseclib/AUTHORS
#srv/web/owncloud/3rdparty/phpseclib/phpseclib/LICENSE
-#srv/web/owncloud/3rdparty/phpseclib/phpseclib/README.md
#srv/web/owncloud/3rdparty/phpseclib/phpseclib/build
#srv/web/owncloud/3rdparty/phpseclib/phpseclib/build/code-sniffer-ruleset-tests.xml
#srv/web/owncloud/3rdparty/phpseclib/phpseclib/build/code-sniffer-ruleset.xml
#srv/web/owncloud/3rdparty/rackspace/php-opencloud/.coveralls.yml
#srv/web/owncloud/3rdparty/rackspace/php-opencloud/CONTRIBUTING.md
#srv/web/owncloud/3rdparty/rackspace/php-opencloud/LICENSE
-#srv/web/owncloud/3rdparty/rackspace/php-opencloud/README.md
#srv/web/owncloud/3rdparty/rackspace/php-opencloud/composer.json
#srv/web/owncloud/3rdparty/rackspace/php-opencloud/docs
#srv/web/owncloud/3rdparty/rackspace/php-opencloud/docs/changelog
#srv/web/owncloud/3rdparty/rackspace/php-opencloud/docs/userguide/Identity/Users.md
#srv/web/owncloud/3rdparty/rackspace/php-opencloud/docs/userguide/Iterators.md
#srv/web/owncloud/3rdparty/rackspace/php-opencloud/docs/userguide/LoadBalancer
-#srv/web/owncloud/3rdparty/rackspace/php-opencloud/docs/userguide/LoadBalancer/README.md
#srv/web/owncloud/3rdparty/rackspace/php-opencloud/docs/userguide/LoadBalancer/USERGUIDE.md
#srv/web/owncloud/3rdparty/rackspace/php-opencloud/docs/userguide/ObjectStore
#srv/web/owncloud/3rdparty/rackspace/php-opencloud/docs/userguide/ObjectStore/Access.md
#srv/web/owncloud/3rdparty/sabre/dav
#srv/web/owncloud/3rdparty/sabre/dav/ChangeLog
#srv/web/owncloud/3rdparty/sabre/dav/LICENSE
-#srv/web/owncloud/3rdparty/sabre/dav/README.md
#srv/web/owncloud/3rdparty/sabre/dav/bin
#srv/web/owncloud/3rdparty/sabre/dav/bin/googlecode_upload.py
#srv/web/owncloud/3rdparty/sabre/dav/bin/migrateto17.php
#srv/web/owncloud/3rdparty/sabre/vobject
#srv/web/owncloud/3rdparty/sabre/vobject/ChangeLog
#srv/web/owncloud/3rdparty/sabre/vobject/LICENSE
-#srv/web/owncloud/3rdparty/sabre/vobject/README.md
#srv/web/owncloud/3rdparty/sabre/vobject/bin
#srv/web/owncloud/3rdparty/sabre/vobject/bin/bench.php
#srv/web/owncloud/3rdparty/sabre/vobject/bin/generateicalendardata.php
#srv/web/owncloud/3rdparty/symfony/console/Symfony/Component/Console/Output/Output.php
#srv/web/owncloud/3rdparty/symfony/console/Symfony/Component/Console/Output/OutputInterface.php
#srv/web/owncloud/3rdparty/symfony/console/Symfony/Component/Console/Output/StreamOutput.php
-#srv/web/owncloud/3rdparty/symfony/console/Symfony/Component/Console/README.md
#srv/web/owncloud/3rdparty/symfony/console/Symfony/Component/Console/Shell.php
#srv/web/owncloud/3rdparty/symfony/console/Symfony/Component/Console/Tester
#srv/web/owncloud/3rdparty/symfony/console/Symfony/Component/Console/Tester/ApplicationTester.php
#srv/web/owncloud/3rdparty/symfony/event-dispatcher/Symfony/Component/EventDispatcher/GenericEvent.php
#srv/web/owncloud/3rdparty/symfony/event-dispatcher/Symfony/Component/EventDispatcher/ImmutableEventDispatcher.php
#srv/web/owncloud/3rdparty/symfony/event-dispatcher/Symfony/Component/EventDispatcher/LICENSE
-#srv/web/owncloud/3rdparty/symfony/event-dispatcher/Symfony/Component/EventDispatcher/README.md
#srv/web/owncloud/3rdparty/symfony/event-dispatcher/Symfony/Component/EventDispatcher/Tests
#srv/web/owncloud/3rdparty/symfony/event-dispatcher/Symfony/Component/EventDispatcher/Tests/ContainerAwareEventDispatcherTest.php
#srv/web/owncloud/3rdparty/symfony/event-dispatcher/Symfony/Component/EventDispatcher/Tests/Debug
#srv/web/owncloud/3rdparty/symfony/process/Symfony/Component/Process/ProcessBuilder.php
#srv/web/owncloud/3rdparty/symfony/process/Symfony/Component/Process/ProcessPipes.php
#srv/web/owncloud/3rdparty/symfony/process/Symfony/Component/Process/ProcessUtils.php
-#srv/web/owncloud/3rdparty/symfony/process/Symfony/Component/Process/README.md
#srv/web/owncloud/3rdparty/symfony/process/Symfony/Component/Process/Tests
#srv/web/owncloud/3rdparty/symfony/process/Symfony/Component/Process/Tests/AbstractProcessTest.php
#srv/web/owncloud/3rdparty/symfony/process/Symfony/Component/Process/Tests/NonStopableProcess.php
#srv/web/owncloud/3rdparty/symfony/routing/Symfony/Component/Routing/Matcher/RedirectableUrlMatcherInterface.php
#srv/web/owncloud/3rdparty/symfony/routing/Symfony/Component/Routing/Matcher/UrlMatcher.php
#srv/web/owncloud/3rdparty/symfony/routing/Symfony/Component/Routing/Matcher/UrlMatcherInterface.php
-#srv/web/owncloud/3rdparty/symfony/routing/Symfony/Component/Routing/README.md
#srv/web/owncloud/3rdparty/symfony/routing/Symfony/Component/Routing/RequestContext.php
#srv/web/owncloud/3rdparty/symfony/routing/Symfony/Component/Routing/RequestContextAwareInterface.php
#srv/web/owncloud/3rdparty/symfony/routing/Symfony/Component/Routing/Route.php
#srv/web/owncloud/3rdparty/timepicker/releases.txt
#srv/web/owncloud/3rdparty/zxcvbn
#srv/web/owncloud/3rdparty/zxcvbn/LICENSE.txt
-#srv/web/owncloud/3rdparty/zxcvbn/README.md
#srv/web/owncloud/3rdparty/zxcvbn/js
#srv/web/owncloud/3rdparty/zxcvbn/js/zxcvbn.js
#srv/web/owncloud/3rdparty/zxcvbn/js/zxcvbn.min.js
#srv/web/owncloud/COPYING-AGPL
#srv/web/owncloud/apps
#srv/web/owncloud/apps/activity
-#srv/web/owncloud/apps/activity/README.md
#srv/web/owncloud/apps/activity/ajax
#srv/web/owncloud/apps/activity/ajax/fetch.php
#srv/web/owncloud/apps/activity/ajax/rssfeed.php
#srv/web/owncloud/apps/activity/appinfo/app.php
#srv/web/owncloud/apps/activity/appinfo/database.xml
#srv/web/owncloud/apps/activity/appinfo/info.xml
+#srv/web/owncloud/apps/activity/appinfo/preupdate.php
#srv/web/owncloud/apps/activity/appinfo/routes.php
#srv/web/owncloud/apps/activity/appinfo/update.php
#srv/web/owncloud/apps/activity/appinfo/version
#srv/web/owncloud/apps/activity/tests/parameterhelpertest.php
#srv/web/owncloud/apps/activity/tests/phpunit.xml
#srv/web/owncloud/apps/activity/tests/usersettingstest.php
-#srv/web/owncloud/apps/admin_dependencies_chk
-#srv/web/owncloud/apps/admin_dependencies_chk/appinfo
-#srv/web/owncloud/apps/admin_dependencies_chk/appinfo/app.php
-#srv/web/owncloud/apps/admin_dependencies_chk/appinfo/info.xml
-#srv/web/owncloud/apps/admin_dependencies_chk/appinfo/version
-#srv/web/owncloud/apps/admin_dependencies_chk/css
-#srv/web/owncloud/apps/admin_dependencies_chk/css/style.css
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/ar.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/ast.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/bg_BG.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/bn_BD.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/ca.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/cs_CZ.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/da.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/de.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/de_CH.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/de_DE.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/el.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/en_GB.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/eo.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/es.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/es_AR.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/es_CL.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/es_MX.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/et_EE.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/eu.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/eu_ES.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/fa.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/fi_FI.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/fr.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/gl.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/hu_HU.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/id.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/is.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/it.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/ja.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/ja_JP.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/jv.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/ka_GE.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/km.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/ko.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/lb.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/lt_LT.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/lv.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/mk.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/nb_NO.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/nl.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/nn_NO.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/pl.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/pt_BR.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/pt_PT.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/ro.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/ru.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/si_LK.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/sk_SK.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/sl.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/sq.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/sr.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/sr@latin.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/sv.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/ta_LK.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/th_TH.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/tr.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/ug.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/uk.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/vi.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/zh_CN.php
-#srv/web/owncloud/apps/admin_dependencies_chk/l10n/zh_TW.php
-#srv/web/owncloud/apps/admin_dependencies_chk/settings.php
-#srv/web/owncloud/apps/admin_dependencies_chk/templates
-#srv/web/owncloud/apps/admin_dependencies_chk/templates/settings.php
#srv/web/owncloud/apps/bookmarks
#srv/web/owncloud/apps/bookmarks/3rdparty
#srv/web/owncloud/apps/bookmarks/3rdparty/css
#srv/web/owncloud/apps/bookmarks/3rdparty/js
#srv/web/owncloud/apps/bookmarks/3rdparty/js/js_tpl.js
#srv/web/owncloud/apps/bookmarks/3rdparty/js/tag-it.js
-#srv/web/owncloud/apps/bookmarks/README.md
#srv/web/owncloud/apps/bookmarks/addBm.php
#srv/web/owncloud/apps/bookmarks/ajax
#srv/web/owncloud/apps/bookmarks/ajax/delBookmark.php
#srv/web/owncloud/apps/calendar/3rdparty/fullcalendar/js/fullcalendar.js
#srv/web/owncloud/apps/calendar/3rdparty/fullcalendar/js/fullcalendar.min.js
#srv/web/owncloud/apps/calendar/3rdparty/fullcalendar/js/gcal.js
-#srv/web/owncloud/apps/calendar/README.md
#srv/web/owncloud/apps/calendar/ajax
#srv/web/owncloud/apps/calendar/ajax/cache
#srv/web/owncloud/apps/calendar/ajax/cache/rescan.php
#srv/web/owncloud/apps/calendar/tests
#srv/web/owncloud/apps/calendar/tests/calendar.php
#srv/web/owncloud/apps/contacts
-#srv/web/owncloud/apps/contacts/.jshintrc
#srv/web/owncloud/apps/contacts/COPYING-README
#srv/web/owncloud/apps/contacts/Changelog
-#srv/web/owncloud/apps/contacts/README.md
#srv/web/owncloud/apps/contacts/admin.php
#srv/web/owncloud/apps/contacts/appinfo
#srv/web/owncloud/apps/contacts/appinfo/app.php
#srv/web/owncloud/apps/contacts/tests/preseed-config.php
#srv/web/owncloud/apps/contacts/tests/setup_owncloud.sh
#srv/web/owncloud/apps/documents
-#srv/web/owncloud/apps/documents/README.md
#srv/web/owncloud/apps/documents/admin.php
#srv/web/owncloud/apps/documents/ajax
#srv/web/owncloud/apps/documents/ajax/admin.php
#srv/web/owncloud/apps/documents/js/3rdparty/resources/dojo/resources/images/dndNoCopy.png
#srv/web/owncloud/apps/documents/js/3rdparty/resources/dojo/resources/images/dndNoMove.png
#srv/web/owncloud/apps/documents/js/3rdparty/resources/dojox
+#srv/web/owncloud/apps/documents/js/3rdparty/resources/dojox/html
+#srv/web/owncloud/apps/documents/js/3rdparty/resources/dojox/html/entities.js
#srv/web/owncloud/apps/documents/js/3rdparty/resources/dojox/layout
#srv/web/owncloud/apps/documents/js/3rdparty/resources/dojox/layout/resources
#srv/web/owncloud/apps/documents/js/3rdparty/resources/dojox/layout/resources/DndGridContainer.css
#srv/web/owncloud/apps/files_encryption/tests/proxy.php
#srv/web/owncloud/apps/files_encryption/tests/share.php
#srv/web/owncloud/apps/files_encryption/tests/stream.php
+#srv/web/owncloud/apps/files_encryption/tests/testcase.php
#srv/web/owncloud/apps/files_encryption/tests/trashbin.php
#srv/web/owncloud/apps/files_encryption/tests/util.php
#srv/web/owncloud/apps/files_encryption/tests/webdav.php
#srv/web/owncloud/apps/files_external/3rdparty/Dropbox/OAuth/Consumer
#srv/web/owncloud/apps/files_external/3rdparty/Dropbox/OAuth/Consumer/Dropbox.php
#srv/web/owncloud/apps/files_external/3rdparty/Dropbox/OAuth/Curl.php
-#srv/web/owncloud/apps/files_external/3rdparty/Dropbox/README.md
#srv/web/owncloud/apps/files_external/3rdparty/Dropbox/autoload.php
#srv/web/owncloud/apps/files_external/3rdparty/aws-sdk-php
#srv/web/owncloud/apps/files_external/3rdparty/aws-sdk-php/Aws
#srv/web/owncloud/apps/files_pdfviewer/3rdparty/pdfjs/pdf.worker.js
#srv/web/owncloud/apps/files_pdfviewer/3rdparty/pdfjs/viewer.css
#srv/web/owncloud/apps/files_pdfviewer/3rdparty/pdfjs/viewer.js
-#srv/web/owncloud/apps/files_pdfviewer/README.md
#srv/web/owncloud/apps/files_pdfviewer/appinfo
#srv/web/owncloud/apps/files_pdfviewer/appinfo/app.php
#srv/web/owncloud/apps/files_pdfviewer/appinfo/info.xml
#srv/web/owncloud/apps/files_sharing/lib/proxy.php
#srv/web/owncloud/apps/files_sharing/lib/readonlycache.php
#srv/web/owncloud/apps/files_sharing/lib/readonlywrapper.php
+#srv/web/owncloud/apps/files_sharing/lib/scanner.php
#srv/web/owncloud/apps/files_sharing/lib/share
#srv/web/owncloud/apps/files_sharing/lib/share/file.php
#srv/web/owncloud/apps/files_sharing/lib/share/folder.php
#srv/web/owncloud/apps/files_sharing/tests/js/shareSpec.js
#srv/web/owncloud/apps/files_sharing/tests/js/sharedfilelistSpec.js
#srv/web/owncloud/apps/files_sharing/tests/permissions.php
+#srv/web/owncloud/apps/files_sharing/tests/propagation.php
#srv/web/owncloud/apps/files_sharing/tests/proxy.php
#srv/web/owncloud/apps/files_sharing/tests/share.php
#srv/web/owncloud/apps/files_sharing/tests/sharedmount.php
#srv/web/owncloud/apps/files_sharing/tests/updater.php
#srv/web/owncloud/apps/files_sharing/tests/watcher.php
#srv/web/owncloud/apps/files_texteditor
-#srv/web/owncloud/apps/files_texteditor/README.md
#srv/web/owncloud/apps/files_texteditor/ajax
#srv/web/owncloud/apps/files_texteditor/ajax/loadfile.php
#srv/web/owncloud/apps/files_texteditor/ajax/savefile.php
#srv/web/owncloud/apps/files_trashbin/appinfo/app.php
#srv/web/owncloud/apps/files_trashbin/appinfo/database.xml
#srv/web/owncloud/apps/files_trashbin/appinfo/info.xml
+#srv/web/owncloud/apps/files_trashbin/appinfo/preupdate.php
#srv/web/owncloud/apps/files_trashbin/appinfo/routes.php
#srv/web/owncloud/apps/files_trashbin/appinfo/update.php
#srv/web/owncloud/apps/files_trashbin/appinfo/version
#srv/web/owncloud/apps/files_videoviewer/src/silverlight/SilverlightMediaElement.csproj.user
#srv/web/owncloud/apps/files_videoviewer/src/silverlight/SilverlightMediaElement.sln
#srv/web/owncloud/apps/firstrunwizard
-#srv/web/owncloud/apps/firstrunwizard/README.md
#srv/web/owncloud/apps/firstrunwizard/ajax
#srv/web/owncloud/apps/firstrunwizard/ajax/disable.php
#srv/web/owncloud/apps/firstrunwizard/ajax/enable.php
#srv/web/owncloud/apps/firstrunwizard/templates/wizard.php
#srv/web/owncloud/apps/firstrunwizard/wizard.php
#srv/web/owncloud/apps/gallery
-#srv/web/owncloud/apps/gallery/README.md
#srv/web/owncloud/apps/gallery/ajax
#srv/web/owncloud/apps/gallery/ajax/gallery.php
#srv/web/owncloud/apps/gallery/ajax/getimages.php
#srv/web/owncloud/apps/templateeditor/templates/settings-admin.php
#srv/web/owncloud/apps/updater
#srv/web/owncloud/apps/updater/COPYING-AGPL
-#srv/web/owncloud/apps/updater/README.md
#srv/web/owncloud/apps/updater/admin.php
#srv/web/owncloud/apps/updater/ajax
#srv/web/owncloud/apps/updater/ajax/backup
#srv/web/owncloud/apps/updater/templates/update.php
#srv/web/owncloud/apps/updater/update.php
#srv/web/owncloud/apps/user_external
-#srv/web/owncloud/apps/user_external/README.md
#srv/web/owncloud/apps/user_external/appinfo
#srv/web/owncloud/apps/user_external/appinfo/app.php
#srv/web/owncloud/apps/user_external/appinfo/database.xml
#srv/web/owncloud/apps/user_ldap/appinfo/update.php
#srv/web/owncloud/apps/user_ldap/appinfo/version
#srv/web/owncloud/apps/user_ldap/command
+#srv/web/owncloud/apps/user_ldap/command/checkuser.php
+#srv/web/owncloud/apps/user_ldap/command/search.php
#srv/web/owncloud/apps/user_ldap/command/setconfig.php
#srv/web/owncloud/apps/user_ldap/command/showconfig.php
+#srv/web/owncloud/apps/user_ldap/command/showremnants.php
#srv/web/owncloud/apps/user_ldap/command/testconfig.php
#srv/web/owncloud/apps/user_ldap/css
#srv/web/owncloud/apps/user_ldap/css/settings.css
#srv/web/owncloud/apps/user_ldap/lib/filesystemhelper.php
#srv/web/owncloud/apps/user_ldap/lib/helper.php
#srv/web/owncloud/apps/user_ldap/lib/ildapwrapper.php
+#srv/web/owncloud/apps/user_ldap/lib/jobs
#srv/web/owncloud/apps/user_ldap/lib/jobs.php
+#srv/web/owncloud/apps/user_ldap/lib/jobs/cleanup.php
#srv/web/owncloud/apps/user_ldap/lib/ldap.php
#srv/web/owncloud/apps/user_ldap/lib/ldaputility.php
#srv/web/owncloud/apps/user_ldap/lib/logwrapper.php
#srv/web/owncloud/apps/user_ldap/lib/proxy.php
#srv/web/owncloud/apps/user_ldap/lib/user
+#srv/web/owncloud/apps/user_ldap/lib/user/deletedusersindex.php
#srv/web/owncloud/apps/user_ldap/lib/user/iusertools.php
#srv/web/owncloud/apps/user_ldap/lib/user/manager.php
+#srv/web/owncloud/apps/user_ldap/lib/user/offlineuser.php
#srv/web/owncloud/apps/user_ldap/lib/user/user.php
#srv/web/owncloud/apps/user_ldap/lib/wizard.php
#srv/web/owncloud/apps/user_ldap/lib/wizardresult.php
#srv/web/owncloud/apps/user_ldap/tests
#srv/web/owncloud/apps/user_ldap/tests/access.php
#srv/web/owncloud/apps/user_ldap/tests/connection.php
-#srv/web/owncloud/apps/user_ldap/tests/data
-#srv/web/owncloud/apps/user_ldap/tests/data/sid.dat
#srv/web/owncloud/apps/user_ldap/tests/group_ldap.php
#srv/web/owncloud/apps/user_ldap/tests/helper.php
+#srv/web/owncloud/apps/user_ldap/tests/jobs
+#srv/web/owncloud/apps/user_ldap/tests/jobs/cleanup.php
#srv/web/owncloud/apps/user_ldap/tests/user
#srv/web/owncloud/apps/user_ldap/tests/user/manager.php
#srv/web/owncloud/apps/user_ldap/tests/user/user.php
#srv/web/owncloud/core/command/status.php
#srv/web/owncloud/core/command/upgrade.php
#srv/web/owncloud/core/command/user
+#srv/web/owncloud/core/command/user/delete.php
#srv/web/owncloud/core/command/user/lastseen.php
#srv/web/owncloud/core/command/user/report.php
#srv/web/owncloud/core/command/user/resetpassword.php
#srv/web/owncloud/core/css/styles.css
#srv/web/owncloud/core/doc
#srv/web/owncloud/core/doc/admin
-#srv/web/owncloud/core/doc/admin/_images
-#srv/web/owncloud/core/doc/admin/_images/antivirus-app.png
-#srv/web/owncloud/core/doc/admin/_images/antivirus-config.png
-#srv/web/owncloud/core/doc/admin/_images/antivirus-daemon-socket.png
-#srv/web/owncloud/core/doc/admin/_images/antivirus-executable.png
-#srv/web/owncloud/core/doc/admin/_images/antivirus-logging.png
-#srv/web/owncloud/core/doc/admin/_images/create_public_share.png
-#srv/web/owncloud/core/doc/admin/_images/documents_app_enable.png
-#srv/web/owncloud/core/doc/admin/_images/encryption1.png
-#srv/web/owncloud/core/doc/admin/_images/encryption2.png
-#srv/web/owncloud/core/doc/admin/_images/encryption3.png
-#srv/web/owncloud/core/doc/admin/_images/encryption4.png
-#srv/web/owncloud/core/doc/admin/_images/encryption5.png
-#srv/web/owncloud/core/doc/admin/_images/encryption6.png
-#srv/web/owncloud/core/doc/admin/_images/encryption7.png
-#srv/web/owncloud/core/doc/admin/_images/encryption8.png
-#srv/web/owncloud/core/doc/admin/_images/encryption9.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-amazons3.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-app-add.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-app-enable.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-app-local.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-app-usermounts.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-dropbox-allowshare.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-dropbox-app.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-dropbox-configapp.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-dropbox-oc.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-dropbox.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-ftp.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-google-drive-0auth.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-google-drive-9.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-google-drive-sdk.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-google-drive.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-google-drive1.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-google-drive2.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-google-drive5.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-google-drive7.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-google-drive8.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-smb.png
-#srv/web/owncloud/core/doc/admin/_images/external-storage-webdav.png
-#srv/web/owncloud/core/doc/admin/_images/install-wizard-advanced.png
-#srv/web/owncloud/core/doc/admin/_images/install-wizard.png
-#srv/web/owncloud/core/doc/admin/_images/ldap-advanced-1-connection.png
-#srv/web/owncloud/core/doc/admin/_images/ldap-advanced-2-directory.png
-#srv/web/owncloud/core/doc/admin/_images/ldap-advanced-3-attributes.png
-#srv/web/owncloud/core/doc/admin/_images/ldap-expert.png
-#srv/web/owncloud/core/doc/admin/_images/ldap-fetched-avatar.png
-#srv/web/owncloud/core/doc/admin/_images/ldap-settings-invalid-oc45.png
-#srv/web/owncloud/core/doc/admin/_images/ldap-settings-valid-oc45.png
-#srv/web/owncloud/core/doc/admin/_images/ldap-wizard-1-server.png
-#srv/web/owncloud/core/doc/admin/_images/ldap-wizard-2-user.png
-#srv/web/owncloud/core/doc/admin/_images/ldap-wizard-3-login.png
-#srv/web/owncloud/core/doc/admin/_images/ldap-wizard-4-group.png
-#srv/web/owncloud/core/doc/admin/_images/lucene-search-enable.png
-#srv/web/owncloud/core/doc/admin/_images/lucene-search-user.png
-#srv/web/owncloud/core/doc/admin/_images/oc_admin_app_page.png
-#srv/web/owncloud/core/doc/admin/_images/preview_images.png
-#srv/web/owncloud/core/doc/admin/_images/remote_shares.png
-#srv/web/owncloud/core/doc/admin/_images/sharing-admin.png
-#srv/web/owncloud/core/doc/admin/_images/sharing-user-local.png
-#srv/web/owncloud/core/doc/admin/_images/sharing-user.png
-#srv/web/owncloud/core/doc/admin/_images/smtp-config-php-sendmail.png
-#srv/web/owncloud/core/doc/admin/_images/smtp-config-smtp.png
-#srv/web/owncloud/core/doc/admin/_images/smtp-config-wizard.png
-#srv/web/owncloud/core/doc/admin/_images/ucs-app-center-install.png
-#srv/web/owncloud/core/doc/admin/_images/ucs-app-center-module.png
-#srv/web/owncloud/core/doc/admin/_images/ucsint.png
-#srv/web/owncloud/core/doc/admin/_images/ucsint1.png
-#srv/web/owncloud/core/doc/admin/_images/ucsint2.png
-#srv/web/owncloud/core/doc/admin/_images/untrusted-domain.png
-#srv/web/owncloud/core/doc/admin/_images/updater-1.png
-#srv/web/owncloud/core/doc/admin/_images/updater-2.png
-#srv/web/owncloud/core/doc/admin/_images/updater-3.png
-#srv/web/owncloud/core/doc/admin/_images/updater-4.png
-#srv/web/owncloud/core/doc/admin/_images/updater-5.png
-#srv/web/owncloud/core/doc/admin/_images/updater-6.png
-#srv/web/owncloud/core/doc/admin/_images/updater-7.png
-#srv/web/owncloud/core/doc/admin/_images/users-config.png
-#srv/web/owncloud/core/doc/admin/_images/users-create.png
-#srv/web/owncloud/core/doc/admin/_images/users-groups.png
-#srv/web/owncloud/core/doc/admin/_images/win7features.jpg
-#srv/web/owncloud/core/doc/admin/_images/winserverroles.jpg
-#srv/web/owncloud/core/doc/admin/_sources
-#srv/web/owncloud/core/doc/admin/_sources/configuration
-#srv/web/owncloud/core/doc/admin/_sources/configuration/auth_ldap.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/background_jobs.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration-antivirus.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_3rdparty.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_apps.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_assets.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_automation.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_config_sample_php.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_custom_clients.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_database.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_encryption.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_file_sharing.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_files_locking.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_knowledgebase.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_language.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_logging.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_mail.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_preview.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_reverseproxy.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuration_users.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuring_big_file_upload.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuring_documents.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/configuring_search.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/custom_mount_config.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/custom_mount_config_gui.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/custom_user_backend.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/index.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/server_to_server_managing.txt
-#srv/web/owncloud/core/doc/admin/_sources/configuration/xsendfile.txt
-#srv/web/owncloud/core/doc/admin/_sources/contents.txt
-#srv/web/owncloud/core/doc/admin/_sources/index.txt
-#srv/web/owncloud/core/doc/admin/_sources/installation
-#srv/web/owncloud/core/doc/admin/_sources/installation/configuration_hiawatha.txt
-#srv/web/owncloud/core/doc/admin/_sources/installation/configuration_lighttpd.txt
-#srv/web/owncloud/core/doc/admin/_sources/installation/configuration_nginx.txt
-#srv/web/owncloud/core/doc/admin/_sources/installation/configuration_yaws.txt
-#srv/web/owncloud/core/doc/admin/_sources/installation/index.txt
-#srv/web/owncloud/core/doc/admin/_sources/installation/installation_appliance.txt
-#srv/web/owncloud/core/doc/admin/_sources/installation/installation_linux.txt
-#srv/web/owncloud/core/doc/admin/_sources/installation/installation_macos.txt
-#srv/web/owncloud/core/doc/admin/_sources/installation/installation_others.txt
-#srv/web/owncloud/core/doc/admin/_sources/installation/installation_source.txt
-#srv/web/owncloud/core/doc/admin/_sources/installation/installation_ucs.txt
-#srv/web/owncloud/core/doc/admin/_sources/installation/installation_windows.txt
-#srv/web/owncloud/core/doc/admin/_sources/installation/installation_wizard.txt
-#srv/web/owncloud/core/doc/admin/_sources/issues
-#srv/web/owncloud/core/doc/admin/_sources/issues/index.txt
-#srv/web/owncloud/core/doc/admin/_sources/maintenance
-#srv/web/owncloud/core/doc/admin/_sources/maintenance/backup.txt
-#srv/web/owncloud/core/doc/admin/_sources/maintenance/convert_db.txt
-#srv/web/owncloud/core/doc/admin/_sources/maintenance/enable_maintenance.txt
-#srv/web/owncloud/core/doc/admin/_sources/maintenance/index.txt
-#srv/web/owncloud/core/doc/admin/_sources/maintenance/migrating.txt
-#srv/web/owncloud/core/doc/admin/_sources/maintenance/restore.txt
-#srv/web/owncloud/core/doc/admin/_sources/maintenance/update.txt
-#srv/web/owncloud/core/doc/admin/_sources/maintenance/upgrade.txt
-#srv/web/owncloud/core/doc/admin/_sources/whats_new_admin.txt
-#srv/web/owncloud/core/doc/admin/_static
-#srv/web/owncloud/core/doc/admin/_static/ajax-loader.gif
-#srv/web/owncloud/core/doc/admin/_static/basic.css
-#srv/web/owncloud/core/doc/admin/_static/bootstrap-responsive.css
-#srv/web/owncloud/core/doc/admin/_static/bootstrap-sphinx.css
-#srv/web/owncloud/core/doc/admin/_static/bootstrap.css
-#srv/web/owncloud/core/doc/admin/_static/bootstrap.js
-#srv/web/owncloud/core/doc/admin/_static/comment-bright.png
-#srv/web/owncloud/core/doc/admin/_static/comment-close.png
-#srv/web/owncloud/core/doc/admin/_static/comment.png
-#srv/web/owncloud/core/doc/admin/_static/doctools.js
-#srv/web/owncloud/core/doc/admin/_static/down-pressed.png
-#srv/web/owncloud/core/doc/admin/_static/down.png
-#srv/web/owncloud/core/doc/admin/_static/file.png
-#srv/web/owncloud/core/doc/admin/_static/img
-#srv/web/owncloud/core/doc/admin/_static/img/glyphicons-halflings-white.png
-#srv/web/owncloud/core/doc/admin/_static/img/glyphicons-halflings.png
-#srv/web/owncloud/core/doc/admin/_static/img/note.svg
-#srv/web/owncloud/core/doc/admin/_static/img/todo.svg
-#srv/web/owncloud/core/doc/admin/_static/jquery.js
-#srv/web/owncloud/core/doc/admin/_static/logo-blue.pdf
-#srv/web/owncloud/core/doc/admin/_static/logo-blue.png
-#srv/web/owncloud/core/doc/admin/_static/minus.png
-#srv/web/owncloud/core/doc/admin/_static/plus.png
-#srv/web/owncloud/core/doc/admin/_static/pygments.css
-#srv/web/owncloud/core/doc/admin/_static/searchtools.js
-#srv/web/owncloud/core/doc/admin/_static/style.css
-#srv/web/owncloud/core/doc/admin/_static/underscore.js
-#srv/web/owncloud/core/doc/admin/_static/up-pressed.png
-#srv/web/owncloud/core/doc/admin/_static/up.png
-#srv/web/owncloud/core/doc/admin/_static/websupport.js
-#srv/web/owncloud/core/doc/admin/configuration
-#srv/web/owncloud/core/doc/admin/configuration/auth_ldap.html
-#srv/web/owncloud/core/doc/admin/configuration/background_jobs.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration-antivirus.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_3rdparty.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_apps.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_assets.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_automation.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_config_sample_php.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_custom_clients.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_database.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_encryption.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_file_sharing.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_files_locking.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_knowledgebase.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_language.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_logging.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_mail.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_preview.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_reverseproxy.html
-#srv/web/owncloud/core/doc/admin/configuration/configuration_users.html
-#srv/web/owncloud/core/doc/admin/configuration/configuring_big_file_upload.html
-#srv/web/owncloud/core/doc/admin/configuration/configuring_documents.html
-#srv/web/owncloud/core/doc/admin/configuration/configuring_search.html
-#srv/web/owncloud/core/doc/admin/configuration/custom_mount_config.html
-#srv/web/owncloud/core/doc/admin/configuration/custom_mount_config_gui.html
-#srv/web/owncloud/core/doc/admin/configuration/custom_user_backend.html
-#srv/web/owncloud/core/doc/admin/configuration/index.html
-#srv/web/owncloud/core/doc/admin/configuration/server_to_server_managing.html
-#srv/web/owncloud/core/doc/admin/configuration/xsendfile.html
-#srv/web/owncloud/core/doc/admin/contents.html
-#srv/web/owncloud/core/doc/admin/genindex.html
#srv/web/owncloud/core/doc/admin/index.html
-#srv/web/owncloud/core/doc/admin/installation
-#srv/web/owncloud/core/doc/admin/installation/configuration_hiawatha.html
-#srv/web/owncloud/core/doc/admin/installation/configuration_lighttpd.html
-#srv/web/owncloud/core/doc/admin/installation/configuration_nginx.html
-#srv/web/owncloud/core/doc/admin/installation/configuration_yaws.html
-#srv/web/owncloud/core/doc/admin/installation/index.html
-#srv/web/owncloud/core/doc/admin/installation/installation_appliance.html
-#srv/web/owncloud/core/doc/admin/installation/installation_linux.html
-#srv/web/owncloud/core/doc/admin/installation/installation_macos.html
-#srv/web/owncloud/core/doc/admin/installation/installation_others.html
-#srv/web/owncloud/core/doc/admin/installation/installation_source.html
-#srv/web/owncloud/core/doc/admin/installation/installation_ucs.html
-#srv/web/owncloud/core/doc/admin/installation/installation_windows.html
-#srv/web/owncloud/core/doc/admin/installation/installation_wizard.html
-#srv/web/owncloud/core/doc/admin/issues
-#srv/web/owncloud/core/doc/admin/issues/index.html
-#srv/web/owncloud/core/doc/admin/maintenance
-#srv/web/owncloud/core/doc/admin/maintenance/backup.html
-#srv/web/owncloud/core/doc/admin/maintenance/convert_db.html
-#srv/web/owncloud/core/doc/admin/maintenance/enable_maintenance.html
-#srv/web/owncloud/core/doc/admin/maintenance/index.html
-#srv/web/owncloud/core/doc/admin/maintenance/migrating.html
-#srv/web/owncloud/core/doc/admin/maintenance/restore.html
-#srv/web/owncloud/core/doc/admin/maintenance/update.html
-#srv/web/owncloud/core/doc/admin/maintenance/upgrade.html
-#srv/web/owncloud/core/doc/admin/objects.inv
-#srv/web/owncloud/core/doc/admin/search.html
-#srv/web/owncloud/core/doc/admin/searchindex.js
-#srv/web/owncloud/core/doc/admin/whats_new_admin.html
+#srv/web/owncloud/core/doc/admin/release
+#srv/web/owncloud/core/doc/admin/release/.buildinfo
+#srv/web/owncloud/core/doc/admin/release/_images
+#srv/web/owncloud/core/doc/admin/release/_images/antivirus-app.png
+#srv/web/owncloud/core/doc/admin/release/_images/antivirus-config.png
+#srv/web/owncloud/core/doc/admin/release/_images/antivirus-daemon-socket.png
+#srv/web/owncloud/core/doc/admin/release/_images/antivirus-executable.png
+#srv/web/owncloud/core/doc/admin/release/_images/antivirus-logging.png
+#srv/web/owncloud/core/doc/admin/release/_images/create_public_share.png
+#srv/web/owncloud/core/doc/admin/release/_images/documents_app_enable.png
+#srv/web/owncloud/core/doc/admin/release/_images/documents_apply_test.png
+#srv/web/owncloud/core/doc/admin/release/_images/encryption1.png
+#srv/web/owncloud/core/doc/admin/release/_images/encryption2.png
+#srv/web/owncloud/core/doc/admin/release/_images/encryption3.png
+#srv/web/owncloud/core/doc/admin/release/_images/encryption4.png
+#srv/web/owncloud/core/doc/admin/release/_images/encryption5.png
+#srv/web/owncloud/core/doc/admin/release/_images/encryption6.png
+#srv/web/owncloud/core/doc/admin/release/_images/encryption7.png
+#srv/web/owncloud/core/doc/admin/release/_images/encryption8.png
+#srv/web/owncloud/core/doc/admin/release/_images/encryption9.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-sites-1.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-sites-2.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-sites-3.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-sites-4.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-sites-5.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-amazons3.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-app-add.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-app-enable.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-app-local.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-app-usermounts.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-dropbox-allowshare.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-dropbox-app.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-dropbox-configapp.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-dropbox-oc.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-dropbox.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-ftp.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-google-drive-0auth.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-google-drive-9.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-google-drive-sdk.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-google-drive.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-google-drive1.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-google-drive2.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-google-drive5.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-google-drive7.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-google-drive8.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-smb.png
+#srv/web/owncloud/core/doc/admin/release/_images/external-storage-webdav.png
+#srv/web/owncloud/core/doc/admin/release/_images/install-wizard-advanced.png
+#srv/web/owncloud/core/doc/admin/release/_images/install-wizard.png
+#srv/web/owncloud/core/doc/admin/release/_images/ldap-advanced-1-connection.png
+#srv/web/owncloud/core/doc/admin/release/_images/ldap-advanced-2-directory.png
+#srv/web/owncloud/core/doc/admin/release/_images/ldap-advanced-3-attributes.png
+#srv/web/owncloud/core/doc/admin/release/_images/ldap-expert.png
+#srv/web/owncloud/core/doc/admin/release/_images/ldap-fetched-avatar.png
+#srv/web/owncloud/core/doc/admin/release/_images/ldap-settings-invalid-oc45.png
+#srv/web/owncloud/core/doc/admin/release/_images/ldap-settings-valid-oc45.png
+#srv/web/owncloud/core/doc/admin/release/_images/ldap-wizard-1-server.png
+#srv/web/owncloud/core/doc/admin/release/_images/ldap-wizard-2-user.png
+#srv/web/owncloud/core/doc/admin/release/_images/ldap-wizard-3-login.png
+#srv/web/owncloud/core/doc/admin/release/_images/ldap-wizard-4-group.png
+#srv/web/owncloud/core/doc/admin/release/_images/lucene-search-enable.png
+#srv/web/owncloud/core/doc/admin/release/_images/lucene-search-user.png
+#srv/web/owncloud/core/doc/admin/release/_images/oc-video-1.png
+#srv/web/owncloud/core/doc/admin/release/_images/oc-video-2.png
+#srv/web/owncloud/core/doc/admin/release/_images/oc_admin_app_page.png
+#srv/web/owncloud/core/doc/admin/release/_images/preview_images.png
+#srv/web/owncloud/core/doc/admin/release/_images/remote_shares.png
+#srv/web/owncloud/core/doc/admin/release/_images/sharing-admin.png
+#srv/web/owncloud/core/doc/admin/release/_images/sharing-user-local.png
+#srv/web/owncloud/core/doc/admin/release/_images/sharing-user.png
+#srv/web/owncloud/core/doc/admin/release/_images/smtp-config-php-sendmail.png
+#srv/web/owncloud/core/doc/admin/release/_images/smtp-config-smtp.png
+#srv/web/owncloud/core/doc/admin/release/_images/smtp-config-wizard.png
+#srv/web/owncloud/core/doc/admin/release/_images/ucs-app-center-install.png
+#srv/web/owncloud/core/doc/admin/release/_images/ucs-app-center-module.png
+#srv/web/owncloud/core/doc/admin/release/_images/ucsint.png
+#srv/web/owncloud/core/doc/admin/release/_images/ucsint1.png
+#srv/web/owncloud/core/doc/admin/release/_images/ucsint2.png
+#srv/web/owncloud/core/doc/admin/release/_images/untrusted-domain.png
+#srv/web/owncloud/core/doc/admin/release/_images/updater-1.png
+#srv/web/owncloud/core/doc/admin/release/_images/updater-2.png
+#srv/web/owncloud/core/doc/admin/release/_images/updater-3.png
+#srv/web/owncloud/core/doc/admin/release/_images/updater-4.png
+#srv/web/owncloud/core/doc/admin/release/_images/updater-5.png
+#srv/web/owncloud/core/doc/admin/release/_images/updater-6.png
+#srv/web/owncloud/core/doc/admin/release/_images/updater-7.png
+#srv/web/owncloud/core/doc/admin/release/_images/users-config.png
+#srv/web/owncloud/core/doc/admin/release/_images/users-create.png
+#srv/web/owncloud/core/doc/admin/release/_images/users-groups.png
+#srv/web/owncloud/core/doc/admin/release/_images/win7features.jpg
+#srv/web/owncloud/core/doc/admin/release/_images/winserverroles.jpg
+#srv/web/owncloud/core/doc/admin/release/_sources
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/activity_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/antivirus_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/automatic_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/background_jobs_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/big_file_upload_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/collaborative_documents_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/config_sample_php_parameters.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/custom_client_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/database_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/email_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/encryption_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/external_sites.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/external_storage_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/external_storage_configuration_gui.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/file_sharing_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/files_locking_enabling.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/harden_server.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/index.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/js_css_asset_management_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/knowledgebase_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/language_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/logging_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/occ_command.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/performance_tips.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/previews_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/reset_admin_password.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/reverse_proxy_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/search_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/server_to_server_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/serving_static_files_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/thirdparty_php_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/user_auth_ftp_smb_imap.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/user_auth_ldap.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/user_auth_ldap_cleanup.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/configuration/user_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/contents.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/index.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/installation
+#srv/web/owncloud/core/doc/admin/release/_sources/installation/appliance_installation.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/installation/apps_management_installation.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/installation/hiawatha_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/installation/index.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/installation/installation_wizard.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/installation/lighttpd_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/installation/linux_installation.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/installation/macos_installation.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/installation/nginx_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/installation/others_installation.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/installation/selinux_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/installation/source_installation.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/installation/ucs_installation.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/installation/windows_installation.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/installation/yaws_configuration.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/issues
+#srv/web/owncloud/core/doc/admin/release/_sources/issues/index.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/maintenance
+#srv/web/owncloud/core/doc/admin/release/_sources/maintenance/backup.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/maintenance/convert_db.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/maintenance/enable_maintenance.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/maintenance/index.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/maintenance/migrating.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/maintenance/restore.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/maintenance/update.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/maintenance/upgrade.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/release_notes.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/videos.txt
+#srv/web/owncloud/core/doc/admin/release/_sources/whats_new_admin.txt
+#srv/web/owncloud/core/doc/admin/release/_static
+#srv/web/owncloud/core/doc/admin/release/_static/ajax-loader.gif
+#srv/web/owncloud/core/doc/admin/release/_static/basic.css
+#srv/web/owncloud/core/doc/admin/release/_static/bootstrap-responsive.css
+#srv/web/owncloud/core/doc/admin/release/_static/bootstrap-sphinx.css
+#srv/web/owncloud/core/doc/admin/release/_static/bootstrap.css
+#srv/web/owncloud/core/doc/admin/release/_static/bootstrap.js
+#srv/web/owncloud/core/doc/admin/release/_static/comment-bright.png
+#srv/web/owncloud/core/doc/admin/release/_static/comment-close.png
+#srv/web/owncloud/core/doc/admin/release/_static/comment.png
+#srv/web/owncloud/core/doc/admin/release/_static/doctools.js
+#srv/web/owncloud/core/doc/admin/release/_static/down-pressed.png
+#srv/web/owncloud/core/doc/admin/release/_static/down.png
+#srv/web/owncloud/core/doc/admin/release/_static/file.png
+#srv/web/owncloud/core/doc/admin/release/_static/img
+#srv/web/owncloud/core/doc/admin/release/_static/img/glyphicons-halflings-white.png
+#srv/web/owncloud/core/doc/admin/release/_static/img/glyphicons-halflings.png
+#srv/web/owncloud/core/doc/admin/release/_static/img/note.svg
+#srv/web/owncloud/core/doc/admin/release/_static/img/todo.svg
+#srv/web/owncloud/core/doc/admin/release/_static/jquery.js
+#srv/web/owncloud/core/doc/admin/release/_static/logo-blue.pdf
+#srv/web/owncloud/core/doc/admin/release/_static/logo-blue.png
+#srv/web/owncloud/core/doc/admin/release/_static/minus.png
+#srv/web/owncloud/core/doc/admin/release/_static/plus.png
+#srv/web/owncloud/core/doc/admin/release/_static/pygments.css
+#srv/web/owncloud/core/doc/admin/release/_static/searchtools.js
+#srv/web/owncloud/core/doc/admin/release/_static/style.css
+#srv/web/owncloud/core/doc/admin/release/_static/underscore.js
+#srv/web/owncloud/core/doc/admin/release/_static/up-pressed.png
+#srv/web/owncloud/core/doc/admin/release/_static/up.png
+#srv/web/owncloud/core/doc/admin/release/_static/websupport.js
+#srv/web/owncloud/core/doc/admin/release/configuration
+#srv/web/owncloud/core/doc/admin/release/configuration/activity_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/antivirus_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/automatic_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/background_jobs_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/big_file_upload_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/collaborative_documents_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/config_sample_php_parameters.html
+#srv/web/owncloud/core/doc/admin/release/configuration/custom_client_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/database_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/email_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/encryption_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/external_sites.html
+#srv/web/owncloud/core/doc/admin/release/configuration/external_storage_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/external_storage_configuration_gui.html
+#srv/web/owncloud/core/doc/admin/release/configuration/file_sharing_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/files_locking_enabling.html
+#srv/web/owncloud/core/doc/admin/release/configuration/harden_server.html
+#srv/web/owncloud/core/doc/admin/release/configuration/index.html
+#srv/web/owncloud/core/doc/admin/release/configuration/js_css_asset_management_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/knowledgebase_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/language_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/logging_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/occ_command.html
+#srv/web/owncloud/core/doc/admin/release/configuration/performance_tips.html
+#srv/web/owncloud/core/doc/admin/release/configuration/previews_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/reset_admin_password.html
+#srv/web/owncloud/core/doc/admin/release/configuration/reverse_proxy_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/search_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/server_to_server_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/serving_static_files_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/thirdparty_php_configuration.html
+#srv/web/owncloud/core/doc/admin/release/configuration/user_auth_ftp_smb_imap.html
+#srv/web/owncloud/core/doc/admin/release/configuration/user_auth_ldap.html
+#srv/web/owncloud/core/doc/admin/release/configuration/user_auth_ldap_cleanup.html
+#srv/web/owncloud/core/doc/admin/release/configuration/user_configuration.html
+#srv/web/owncloud/core/doc/admin/release/contents.html
+#srv/web/owncloud/core/doc/admin/release/genindex.html
+#srv/web/owncloud/core/doc/admin/release/index.html
+#srv/web/owncloud/core/doc/admin/release/installation
+#srv/web/owncloud/core/doc/admin/release/installation/appliance_installation.html
+#srv/web/owncloud/core/doc/admin/release/installation/apps_management_installation.html
+#srv/web/owncloud/core/doc/admin/release/installation/hiawatha_configuration.html
+#srv/web/owncloud/core/doc/admin/release/installation/index.html
+#srv/web/owncloud/core/doc/admin/release/installation/installation_wizard.html
+#srv/web/owncloud/core/doc/admin/release/installation/lighttpd_configuration.html
+#srv/web/owncloud/core/doc/admin/release/installation/linux_installation.html
+#srv/web/owncloud/core/doc/admin/release/installation/macos_installation.html
+#srv/web/owncloud/core/doc/admin/release/installation/nginx_configuration.html
+#srv/web/owncloud/core/doc/admin/release/installation/others_installation.html
+#srv/web/owncloud/core/doc/admin/release/installation/selinux_configuration.html
+#srv/web/owncloud/core/doc/admin/release/installation/source_installation.html
+#srv/web/owncloud/core/doc/admin/release/installation/ucs_installation.html
+#srv/web/owncloud/core/doc/admin/release/installation/windows_installation.html
+#srv/web/owncloud/core/doc/admin/release/installation/yaws_configuration.html
+#srv/web/owncloud/core/doc/admin/release/issues
+#srv/web/owncloud/core/doc/admin/release/issues/index.html
+#srv/web/owncloud/core/doc/admin/release/maintenance
+#srv/web/owncloud/core/doc/admin/release/maintenance/backup.html
+#srv/web/owncloud/core/doc/admin/release/maintenance/convert_db.html
+#srv/web/owncloud/core/doc/admin/release/maintenance/enable_maintenance.html
+#srv/web/owncloud/core/doc/admin/release/maintenance/index.html
+#srv/web/owncloud/core/doc/admin/release/maintenance/migrating.html
+#srv/web/owncloud/core/doc/admin/release/maintenance/restore.html
+#srv/web/owncloud/core/doc/admin/release/maintenance/update.html
+#srv/web/owncloud/core/doc/admin/release/maintenance/upgrade.html
+#srv/web/owncloud/core/doc/admin/release/objects.inv
+#srv/web/owncloud/core/doc/admin/release/release_notes.html
+#srv/web/owncloud/core/doc/admin/release/search.html
+#srv/web/owncloud/core/doc/admin/release/searchindex.js
+#srv/web/owncloud/core/doc/admin/release/videos.html
+#srv/web/owncloud/core/doc/admin/release/whats_new_admin.html
#srv/web/owncloud/core/doc/user
#srv/web/owncloud/core/doc/user/_images
#srv/web/owncloud/core/doc/user/_images/bookmark_addurl.png
#srv/web/owncloud/core/doc/user/_images/bookmark_setting.png
+#srv/web/owncloud/core/doc/user/_images/calendar_caldav_icon.png
+#srv/web/owncloud/core/doc/user/_images/calendar_caldav_ios.png
+#srv/web/owncloud/core/doc/user/_images/calendar_caldav_link.png
#srv/web/owncloud/core/doc/user/_images/calendar_create_event.png
#srv/web/owncloud/core/doc/user/_images/calendar_create_event_repeat.png
#srv/web/owncloud/core/doc/user/_images/calendar_create_event_share.png
#srv/web/owncloud/core/doc/user/_images/contact_vcfpick.jpg
#srv/web/owncloud/core/doc/user/_images/contacts_empty.png
#srv/web/owncloud/core/doc/user/_images/contacts_settings.png
-#srv/web/owncloud/core/doc/user/_images/deleted_files.png
#srv/web/owncloud/core/doc/user/_images/documents_personal_settings.png
-#srv/web/owncloud/core/doc/user/_images/dolphin_webdav.png
#srv/web/owncloud/core/doc/user/_images/download.png
#srv/web/owncloud/core/doc/user/_images/email_address_personal_settings.png
#srv/web/owncloud/core/doc/user/_images/encryption1.png
#srv/web/owncloud/core/doc/user/_images/explorer_webdav.png
#srv/web/owncloud/core/doc/user/_images/files_versioning.png
#srv/web/owncloud/core/doc/user/_images/full_name.png
-#srv/web/owncloud/core/doc/user/_images/gnome3_nautilus_webdav.png
+#srv/web/owncloud/core/doc/user/_images/gear.png
#srv/web/owncloud/core/doc/user/_images/kdes.png
#srv/web/owncloud/core/doc/user/_images/kdes1.png
#srv/web/owncloud/core/doc/user/_images/kdes2.png
#srv/web/owncloud/core/doc/user/_images/users-share-local.png
#srv/web/owncloud/core/doc/user/_images/users-share-local2.png
#srv/web/owncloud/core/doc/user/_images/users-share-public.png
+#srv/web/owncloud/core/doc/user/_images/users-share-public2.jpg
+#srv/web/owncloud/core/doc/user/_images/users-share-public3.jpg
+#srv/web/owncloud/core/doc/user/_images/webdav_dolphin.png
+#srv/web/owncloud/core/doc/user/_images/webdav_gnome3_nautilus.png
#srv/web/owncloud/core/doc/user/_sources
#srv/web/owncloud/core/doc/user/_sources/bookmarks.txt
#srv/web/owncloud/core/doc/user/_sources/contents.txt
#srv/web/owncloud/core/doc/user/_sources/files/sync.txt
#srv/web/owncloud/core/doc/user/_sources/files/versioncontrol.txt
#srv/web/owncloud/core/doc/user/_sources/index.txt
-#srv/web/owncloud/core/doc/user/_sources/installing_apps.txt
#srv/web/owncloud/core/doc/user/_sources/pim
#srv/web/owncloud/core/doc/user/_sources/pim/calendar.txt
#srv/web/owncloud/core/doc/user/_sources/pim/contacts.txt
#srv/web/owncloud/core/doc/user/files/versioncontrol.html
#srv/web/owncloud/core/doc/user/genindex.html
#srv/web/owncloud/core/doc/user/index.html
-#srv/web/owncloud/core/doc/user/installing_apps.html
#srv/web/owncloud/core/doc/user/objects.inv
#srv/web/owncloud/core/doc/user/pim
#srv/web/owncloud/core/doc/user/pim/calendar.html
#srv/web/owncloud/core/js/placeholders.js
#srv/web/owncloud/core/js/select2
#srv/web/owncloud/core/js/select2/LICENSE
-#srv/web/owncloud/core/js/select2/README.md
#srv/web/owncloud/core/js/select2/bower.json
#srv/web/owncloud/core/js/select2/component.json
#srv/web/owncloud/core/js/select2/composer.json
#srv/web/owncloud/core/templates/untrustedDomain.php
#srv/web/owncloud/core/templates/update.admin.php
#srv/web/owncloud/core/templates/update.user.php
+#srv/web/owncloud/core/user
+#srv/web/owncloud/core/user/controller.php
#srv/web/owncloud/cron.php
#srv/web/owncloud/data
#srv/web/owncloud/db_structure.xml
#srv/web/owncloud/lib/l10n/tzm.php
#srv/web/owncloud/lib/l10n/ug.php
#srv/web/owncloud/lib/l10n/uk.php
-#srv/web/owncloud/lib/l10n/ur.php
#srv/web/owncloud/lib/l10n/ur_PK.php
#srv/web/owncloud/lib/l10n/uz.php
#srv/web/owncloud/lib/l10n/vi.php
#srv/web/owncloud/lib/private/preview
#srv/web/owncloud/lib/private/preview.php
#srv/web/owncloud/lib/private/preview/image.php
-#srv/web/owncloud/lib/private/preview/movies.php
+#srv/web/owncloud/lib/private/preview/movie.php
#srv/web/owncloud/lib/private/preview/mp3.php
#srv/web/owncloud/lib/private/preview/office-cl.php
#srv/web/owncloud/lib/private/preview/office.php
#srv/web/owncloud/lib/private/search/result/file.php
#srv/web/owncloud/lib/private/search/result/folder.php
#srv/web/owncloud/lib/private/search/result/image.php
+#srv/web/owncloud/lib/private/security
+#srv/web/owncloud/lib/private/security/crypto.php
+#srv/web/owncloud/lib/private/security/stringutils.php
#srv/web/owncloud/lib/private/server.php
+#srv/web/owncloud/lib/private/servernotavailableexception.php
#srv/web/owncloud/lib/private/serviceunavailableexception.php
#srv/web/owncloud/lib/private/session
#srv/web/owncloud/lib/private/session/internal.php
#srv/web/owncloud/lib/private/template/resourcelocator.php
#srv/web/owncloud/lib/private/template/templatefilelocator.php
#srv/web/owncloud/lib/private/templatelayout.php
+#srv/web/owncloud/lib/private/tempmanager.php
#srv/web/owncloud/lib/private/updater.php
#srv/web/owncloud/lib/private/urlgenerator.php
#srv/web/owncloud/lib/private/user
#srv/web/owncloud/lib/private/user/http.php
#srv/web/owncloud/lib/private/user/interface.php
#srv/web/owncloud/lib/private/user/manager.php
+#srv/web/owncloud/lib/private/user/nouserexception.php
#srv/web/owncloud/lib/private/user/session.php
#srv/web/owncloud/lib/private/user/user.php
#srv/web/owncloud/lib/private/util.php
#srv/web/owncloud/lib/public/isession.php
#srv/web/owncloud/lib/public/itagmanager.php
#srv/web/owncloud/lib/public/itags.php
+#srv/web/owncloud/lib/public/itempmanager.php
#srv/web/owncloud/lib/public/iurlgenerator.php
#srv/web/owncloud/lib/public/iuser.php
#srv/web/owncloud/lib/public/iusermanager.php
#srv/web/owncloud/lib/public/search
#srv/web/owncloud/lib/public/search/provider.php
#srv/web/owncloud/lib/public/search/result.php
+#srv/web/owncloud/lib/public/security
+#srv/web/owncloud/lib/public/security/icrypto.php
+#srv/web/owncloud/lib/public/security/stringutils.php
#srv/web/owncloud/lib/public/share.php
#srv/web/owncloud/lib/public/template.php
#srv/web/owncloud/lib/public/user.php
#srv/web/owncloud/lib/repair/collation.php
#srv/web/owncloud/lib/repair/innodb.php
#srv/web/owncloud/lib/repair/preview.php
+#srv/web/owncloud/lib/repair/repairconfig.php
#srv/web/owncloud/lib/repair/repairmimetypes.php
#srv/web/owncloud/lib/repair/searchlucenetables.php
#srv/web/owncloud/occ
WARNING: translation string unused: advproxy chgwebpwd new password confirm
WARNING: translation string unused: advproxy chgwebpwd old password
WARNING: translation string unused: advproxy chgwebpwd username
-WARNING: translation string unused: advproxy cre disabled
WARNING: translation string unused: advproxy errmsg change fail
WARNING: translation string unused: advproxy errmsg change success
WARNING: translation string unused: advproxy errmsg invalid user
WARNING: translation string unused: advproxy errmsg no password
WARNING: translation string unused: advproxy errmsg password incorrect
-WARNING: translation string unused: advproxy no cre groups
WARNING: translation string unused: advproxy ssadvanced proxy
WARNING: translation string unused: advproxy update notification
WARNING: translation string unused: again
WARNING: translation string unused: advproxy chgwebpwd new password confirm
WARNING: translation string unused: advproxy chgwebpwd old password
WARNING: translation string unused: advproxy chgwebpwd username
-WARNING: translation string unused: advproxy cre disabled
WARNING: translation string unused: advproxy errmsg change fail
WARNING: translation string unused: advproxy errmsg change success
WARNING: translation string unused: advproxy errmsg invalid user
WARNING: translation string unused: advproxy errmsg no password
WARNING: translation string unused: advproxy errmsg password incorrect
-WARNING: translation string unused: advproxy no cre groups
WARNING: translation string unused: advproxy ssadvanced proxy
WARNING: translation string unused: advproxy update information
WARNING: translation string unused: advproxy update notification
WARNING: translation string unused: advproxy chgwebpwd new password confirm
WARNING: translation string unused: advproxy chgwebpwd old password
WARNING: translation string unused: advproxy chgwebpwd username
-WARNING: translation string unused: advproxy cre disabled
WARNING: translation string unused: advproxy errmsg change fail
WARNING: translation string unused: advproxy errmsg change success
WARNING: translation string unused: advproxy errmsg invalid user
WARNING: translation string unused: advproxy errmsg no password
WARNING: translation string unused: advproxy errmsg password incorrect
-WARNING: translation string unused: advproxy no cre groups
WARNING: translation string unused: advproxy ssadvanced proxy
WARNING: translation string unused: advproxy update information
WARNING: translation string unused: advproxy update notification
WARNING: untranslated string: advproxy group required
WARNING: untranslated string: advproxy proxy port transparent
WARNING: untranslated string: age second
+WARNING: untranslated string: application layer gateways
WARNING: untranslated string: atm device
WARNING: untranslated string: attention
WARNING: untranslated string: bit
WARNING: translation string unused: advproxy chgwebpwd new password confirm
WARNING: translation string unused: advproxy chgwebpwd old password
WARNING: translation string unused: advproxy chgwebpwd username
-WARNING: translation string unused: advproxy cre disabled
WARNING: translation string unused: advproxy errmsg change fail
WARNING: translation string unused: advproxy errmsg change success
WARNING: translation string unused: advproxy errmsg invalid user
WARNING: translation string unused: advproxy errmsg no password
WARNING: translation string unused: advproxy errmsg password incorrect
-WARNING: translation string unused: advproxy no cre groups
WARNING: translation string unused: advproxy ssadvanced proxy
WARNING: translation string unused: advproxy update information
WARNING: translation string unused: advproxy update notification
WARNING: untranslated string: advproxy group required
WARNING: untranslated string: advproxy proxy port transparent
WARNING: untranslated string: age second
+WARNING: untranslated string: application layer gateways
WARNING: untranslated string: atm device
WARNING: untranslated string: attention
WARNING: untranslated string: bit
WARNING: translation string unused: advproxy chgwebpwd new password confirm
WARNING: translation string unused: advproxy chgwebpwd old password
WARNING: translation string unused: advproxy chgwebpwd username
-WARNING: translation string unused: advproxy cre disabled
WARNING: translation string unused: advproxy errmsg change fail
WARNING: translation string unused: advproxy errmsg change success
WARNING: translation string unused: advproxy errmsg invalid user
WARNING: translation string unused: advproxy errmsg no password
WARNING: translation string unused: advproxy errmsg password incorrect
-WARNING: translation string unused: advproxy no cre groups
WARNING: translation string unused: advproxy ssadvanced proxy
WARNING: translation string unused: advproxy update information
WARNING: translation string unused: advproxy update notification
WARNING: untranslated string: advproxy basic authentication
WARNING: untranslated string: advproxy group access control
WARNING: untranslated string: advproxy group required
+WARNING: untranslated string: application layer gateways
WARNING: untranslated string: bytes
WARNING: untranslated string: check all
WARNING: untranslated string: dhcp dns enable update
WARNING: translation string unused: advproxy chgwebpwd new password confirm
WARNING: translation string unused: advproxy chgwebpwd old password
WARNING: translation string unused: advproxy chgwebpwd username
-WARNING: translation string unused: advproxy cre disabled
WARNING: translation string unused: advproxy errmsg change fail
WARNING: translation string unused: advproxy errmsg change success
WARNING: translation string unused: advproxy errmsg invalid user
WARNING: translation string unused: advproxy errmsg no password
WARNING: translation string unused: advproxy errmsg password incorrect
-WARNING: translation string unused: advproxy no cre groups
WARNING: translation string unused: advproxy ssadvanced proxy
WARNING: translation string unused: advproxy update information
WARNING: translation string unused: advproxy update notification
WARNING: untranslated string: advproxy basic authentication
WARNING: untranslated string: advproxy group access control
WARNING: untranslated string: advproxy group required
+WARNING: untranslated string: application layer gateways
WARNING: untranslated string: atm device
WARNING: untranslated string: bytes
WARNING: untranslated string: capabilities
WARNING: translation string unused: advproxy chgwebpwd new password confirm
WARNING: translation string unused: advproxy chgwebpwd old password
WARNING: translation string unused: advproxy chgwebpwd username
-WARNING: translation string unused: advproxy cre disabled
WARNING: translation string unused: advproxy errmsg change fail
WARNING: translation string unused: advproxy errmsg change success
WARNING: translation string unused: advproxy errmsg invalid user
WARNING: translation string unused: advproxy errmsg no password
WARNING: translation string unused: advproxy errmsg password incorrect
-WARNING: translation string unused: advproxy no cre groups
WARNING: translation string unused: advproxy ssadvanced proxy
WARNING: translation string unused: advproxy update information
WARNING: translation string unused: advproxy update notification
WARNING: untranslated string: advproxy group required
WARNING: untranslated string: advproxy proxy port transparent
WARNING: untranslated string: age second
+WARNING: untranslated string: application layer gateways
WARNING: untranslated string: atm device
WARNING: untranslated string: attention
WARNING: untranslated string: bit
WARNING: translation string unused: advproxy chgwebpwd new password confirm
WARNING: translation string unused: advproxy chgwebpwd old password
WARNING: translation string unused: advproxy chgwebpwd username
-WARNING: translation string unused: advproxy cre disabled
WARNING: translation string unused: advproxy errmsg change fail
WARNING: translation string unused: advproxy errmsg change success
WARNING: translation string unused: advproxy errmsg invalid user
WARNING: translation string unused: advproxy errmsg no password
WARNING: translation string unused: advproxy errmsg password incorrect
-WARNING: translation string unused: advproxy no cre groups
WARNING: translation string unused: advproxy ssadvanced proxy
WARNING: translation string unused: advproxy update information
WARNING: translation string unused: advproxy update notification
WARNING: untranslated string: advproxy group required
WARNING: untranslated string: advproxy proxy port transparent
WARNING: untranslated string: age second
+WARNING: untranslated string: application layer gateways
WARNING: untranslated string: atm device
WARNING: untranslated string: attention
WARNING: untranslated string: bit
WARNING: translation string unused: advproxy chgwebpwd new password confirm
WARNING: translation string unused: advproxy chgwebpwd old password
WARNING: translation string unused: advproxy chgwebpwd username
-WARNING: translation string unused: advproxy cre disabled
WARNING: translation string unused: advproxy errmsg change fail
WARNING: translation string unused: advproxy errmsg change success
WARNING: translation string unused: advproxy errmsg invalid user
WARNING: translation string unused: advproxy errmsg no password
WARNING: translation string unused: advproxy errmsg password incorrect
-WARNING: translation string unused: advproxy no cre groups
WARNING: translation string unused: advproxy ssadvanced proxy
WARNING: translation string unused: advproxy update information
WARNING: translation string unused: advproxy update notification
WARNING: translation string unused: year-graph
WARNING: translation string unused: yearly firewallhits
WARNING: untranslated string: Scan for Songs
+WARNING: untranslated string: application layer gateways
WARNING: untranslated string: bytes
WARNING: untranslated string: fwhost cust geoipgrp
WARNING: untranslated string: fwhost err hostip
< age shour
< age sminute
< age ssecond
+< application layer gateways
< atm device
< attention
< bit
< age shour
< age sminute
< age ssecond
+< application layer gateways
< Async logging enabled
< atm device
< attention
< age shour
< age sminute
< age ssecond
+< application layer gateways
< atm device
< attention
< bit
< age shour
< age sminute
< age ssecond
+< application layer gateways
< atm device
< attention
< bit
my $errormessage = '';
my @shortmonths = ( 'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug',
- 'Sep', 'Oct', 'Nov', 'Dec' );
+ 'Sep', 'Oct', 'Nov', 'Dec' );
my @longmonths = ( $Lang::tr{'january'}, $Lang::tr{'february'}, $Lang::tr{'march'},
- $Lang::tr{'april'}, $Lang::tr{'may'}, $Lang::tr{'june'}, $Lang::tr{'july'}, $Lang::tr{'august'},
- $Lang::tr{'september'}, $Lang::tr{'october'}, $Lang::tr{'november'},
- $Lang::tr{'december'} );
+ $Lang::tr{'april'}, $Lang::tr{'may'}, $Lang::tr{'june'}, $Lang::tr{'july'}, $Lang::tr{'august'},
+ $Lang::tr{'september'}, $Lang::tr{'october'}, $Lang::tr{'november'},
+ $Lang::tr{'december'} );
my @now = localtime();
my $dow = $now[6];
if ($ENV{'QUERY_STRING'} && $cgiparams{'ACTION'} ne $Lang::tr{'update'})
{
- my @temp = split(',',$ENV{'QUERY_STRING'});
- $start = $temp[0];
- $cgiparams{'MONTH'} = $temp[1];
- $cgiparams{'DAY'} = $temp[2];
+ my @temp = split(',',$ENV{'QUERY_STRING'});
+ $start = $temp[0];
+ $cgiparams{'MONTH'} = $temp[1];
+ $cgiparams{'DAY'} = $temp[2];
}
if (!($cgiparams{'MONTH'} =~ /^(0|1|2|3|4|5|6|7|8|9|10|11)$/) ||
- !($cgiparams{'DAY'} =~ /^(0|1|2|3|4|5|6|7|8|9|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|26|27|28|29|30|31)$/))
+ !($cgiparams{'DAY'} =~ /^(0|1|2|3|4|5|6|7|8|9|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|26|27|28|29|30|31)$/))
{
- $cgiparams{'DAY'} = $now[3];
- $cgiparams{'MONTH'} = $now[4];
+ $cgiparams{'DAY'} = $now[3];
+ $cgiparams{'MONTH'} = $now[4];
}
elsif($cgiparams{'ACTION'} eq '>>')
{
- my @temp_then=();
- my @temp_now = localtime(time);
- $temp_now[4] = $cgiparams{'MONTH'};
- $temp_now[3] = $cgiparams{'DAY'};
- if ($cgiparams{'DAY'}) {
- @temp_then = localtime(POSIX::mktime(@temp_now) + 86400);
- ## Retrieve the same time on the next day +
- ## 86400 seconds in a day
- } else {
- $temp_now[3] = 1;
- $temp_now[4] = ($temp_now[4]+1) %12;
- @temp_then = localtime(POSIX::mktime(@temp_now) );
- $temp_then[3] = 0;
- }
- $cgiparams{'MONTH'} = $temp_then[4];
- $cgiparams{'DAY'} = $temp_then[3];
+ my @temp_then=();
+ my @temp_now = localtime(time);
+ $temp_now[4] = $cgiparams{'MONTH'};
+ $temp_now[3] = $cgiparams{'DAY'};
+ if ($cgiparams{'DAY'}) {
+ @temp_then = localtime(POSIX::mktime(@temp_now) + 86400);
+ ## Retrieve the same time on the next day +
+ ## 86400 seconds in a day
+ } else {
+ $temp_now[3] = 1;
+ $temp_now[4] = ($temp_now[4]+1) %12;
+ @temp_then = localtime(POSIX::mktime(@temp_now) );
+ $temp_then[3] = 0;
+ }
+ $cgiparams{'MONTH'} = $temp_then[4];
+ $cgiparams{'DAY'} = $temp_then[3];
}
elsif($cgiparams{'ACTION'} eq '<<')
{
- my @temp_then=();
- my @temp_now = localtime(time);
- $temp_now[4] = $cgiparams{'MONTH'};
- $temp_now[3] = $cgiparams{'DAY'};
- if ($cgiparams{'DAY'}) {
- @temp_then = localtime(POSIX::mktime(@temp_now) - 86400);
- ## Retrieve the same time on the next day -
- ## 86400 seconds in a day
- } else {
- $temp_now[3] = 1;
- $temp_now[4] = ($temp_now[4]-1) %12;
- @temp_then = localtime(POSIX::mktime(@temp_now) );
- $temp_then[3] = 0;
- }
- $cgiparams{'MONTH'} = $temp_then[4];
- $cgiparams{'DAY'} = $temp_then[3];
+ my @temp_then=();
+ my @temp_now = localtime(time);
+ $temp_now[4] = $cgiparams{'MONTH'};
+ $temp_now[3] = $cgiparams{'DAY'};
+ if ($cgiparams{'DAY'}) {
+ @temp_then = localtime(POSIX::mktime(@temp_now) - 86400);
+ ## Retrieve the same time on the next day -
+ ## 86400 seconds in a day
+ } else {
+ $temp_now[3] = 1;
+ $temp_now[4] = ($temp_now[4]-1) %12;
+ @temp_then = localtime(POSIX::mktime(@temp_now) );
+ $temp_then[3] = 0;
+ }
+ $cgiparams{'MONTH'} = $temp_then[4];
+ $cgiparams{'DAY'} = $temp_then[3];
}
# Find in which file.gz is the log. Can be calculated because WEEKLY ROTATING of access.log
my $date = $cgiparams{'DAY'} == 0 ? '' : $cgiparams{'DAY'} <= 9 ? "0$cgiparams{'DAY'}" : "$cgiparams{'DAY'}";
{
- my $xday;
-
- # Calculate time. If future date, calculate for past year !!!
- if (( $cgiparams{'MONTH'} eq $now[4]) && ($cgiparams{'DAY'} > $now[3]) ||
- ( $cgiparams{'MONTH'} > $now[4] ) ) {
- $xday = POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1901 );
- $date = "$longmonths[$cgiparams{'MONTH'}] $date, ". int($year-1);
- } else {
- $xday = POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1900 );
- $date = "$longmonths[$cgiparams{'MONTH'}] $date, $year";
- }
-
- # calculate end of active week (saturday 23H59)
- my @then = ();
- @then = localtime(time());
- my $sunday = POSIX::mktime( 0, 0, 0, @then[3], @then[4], @then[5]);
- $sunday += (6-$then[6]) * 86400;
-
- # Convert delta in second to full weeks
- $gzindex = int (($sunday-$xday)/604800 );
+ my $xday;
+
+ # Calculate time. If future date, calculate for past year !!!
+ if (( $cgiparams{'MONTH'} eq $now[4]) && ($cgiparams{'DAY'} > $now[3]) ||
+ ( $cgiparams{'MONTH'} > $now[4] ) ) {
+ $xday = POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1901 );
+ $date = "$longmonths[$cgiparams{'MONTH'}] $date, ". int($year-1);
+ } else {
+ $xday = POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1900 );
+ $date = "$longmonths[$cgiparams{'MONTH'}] $date, $year";
+ }
+
+ # calculate end of active week (saturday 23H59)
+ my @then = ();
+ @then = localtime(time());
+ my $sunday = POSIX::mktime( 0, 0, 0, @then[3], @then[4], @then[5]);
+ $sunday += (6-$then[6]) * 86400;
+
+ # Convert delta in second to full weeks
+ $gzindex = int (($sunday-$xday)/604800 );
}
-
+
my $monthstr = $shortmonths[$cgiparams{'MONTH'}];
my $daystr = $cgiparams{'DAY'} == 0 ? '..' : $cgiparams{'DAY'} <= 9 ? " $cgiparams{'DAY'}" : "$cgiparams{'DAY'}";
-
+
my $lines = 0;
my @log=();
my $loop = 1;
my $filestr = 0;
-my $lastdatetime; # for debug
+my $lastdatetime; # for debug
my $search_for_end = 0;
-
+
while ($gzindex >=0 && $loop) {
- # calculate file name
- if ($gzindex == 0) {
- $filestr = "/var/log/messages";
- } else {
- $filestr = "/var/log/messages.$gzindex";
- $filestr = "$filestr.gz" if -f "$filestr.gz";
- }
- # now read file if existing
- if (open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr))) {
- #&General::log("reading $filestr");
- READ:while (<FILE>) {
- my $line = $_;
- if ($line =~ /^${monthstr} ${daystr} ..:..:.. [\w\-]+ kernel:.*IN=.*$/) {
- # when standart viewing, just keep in memory the correct slice
- # it starts a '$start' and size is $viewport
- # If export, then keep all lines...
- if ($cgiparams{'ACTION'} eq $Lang::tr{'export'}){
- $log[$lines++] = "$line";
- } else {
- if ($lines++ < ($start + $Header::viewsize)) {
- push(@log,"$line");
- if (@log > $Header::viewsize) {
- shift (@log);
- }
- #} else { dont do this optimisation, need to count lines !
- # $datetime = $maxtime; # we have read viewsize lines, stop main loop
- # last READ; # exit read file
- }
- }
- $search_for_end = 1; # we find the start of slice, can look for end now
- } else {
- if ($search_for_end == 1) {
- #finish read files when date is over (test month equality only)
- $line =~ /^(...) (..) ..:..:..*$/;
- $loop = 0 if ( ($1 ne $monthstr) || ( ($daystr ne '..') && ($daystr ne $2) ) );
- }
- }
- }
- close (FILE);
- }
- $gzindex--; # will try next gz file eg 40,39,38,.... because it may have holes when ipcop stopped
- # for a long time
+ # calculate file name
+ if ($gzindex == 0) {
+ $filestr = "/var/log/messages";
+ } else {
+ $filestr = "/var/log/messages.$gzindex";
+ $filestr = "$filestr.gz" if -f "$filestr.gz";
+ }
+ # now read file if existing
+ if (open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr))) {
+ #&General::log("reading $filestr");
+ READ:while (<FILE>) {
+ my $line = $_;
+ if ($line =~ /^${monthstr} ${daystr} ..:..:.. [\w\-]+ kernel:.*IN=.*$/) {
+ # when standart viewing, just keep in memory the correct slice
+ # it starts a '$start' and size is $viewport
+ # If export, then keep all lines...
+ if ($cgiparams{'ACTION'} eq $Lang::tr{'export'}){
+ $log[$lines++] = "$line";
+ } else {
+ if ($lines++ < ($start + $Header::viewsize)) {
+ push(@log,"$line");
+ if (@log > $Header::viewsize) {
+ shift (@log);
+ }
+ #} else { dont do this optimisation, need to count lines !
+ # $datetime = $maxtime; # we have read viewsize lines, stop main loop
+ # last READ; # exit read file
+ }
+ }
+ $search_for_end = 1; # we find the start of slice, can look for end now
+ } else {
+ if ($search_for_end == 1) {
+ #finish read files when date is over (test month equality only)
+ $line =~ /^(...) (..) ..:..:..*$/;
+ $loop = 0 if ( ($1 ne $monthstr) || ( ($daystr ne '..') && ($daystr ne $2) ) );
+ }
+ }
+ }
+ close (FILE);
+ }
+ $gzindex--; # will try next gz file eg 40,39,38,.... because it may have holes when ipcop stopped
+ # for a long time
}# while
# $errormessage = "$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
if ($cgiparams{'ACTION'} eq $Lang::tr{'export'})
{
- print "Content-type: text/plain\n\n";
- print "IPFire firewall log\r\n";
- print "$Lang::{'date'}: $date\r\n\r\n";
-
- if ($logsettings{'LOGVIEW_REVERSE'} eq 'on') { @log = reverse @log; }
-
- foreach $_ (@log)
- {
- /^... (..) (..:..:..) [\w\-]+ kernel:.*(IN=.*)$/;
- my $day = $1;
- $day =~ tr / /0/;
- my $time = $cgiparams{'DAY'} ? "$2" : "$day/$2" ;
- print "$time $3\r\n";
-
- }
- exit 0;
+ print "Content-type: text/plain\n\n";
+ print "IPFire firewall log\r\n";
+ print "$Lang::{'date'}: $date\r\n\r\n";
+
+ if ($logsettings{'LOGVIEW_REVERSE'} eq 'on') { @log = reverse @log; }
+
+ foreach $_ (@log)
+ {
+ /^... (..) (..:..:..) [\w\-]+ kernel:.*(IN=.*)$/;
+ my $day = $1;
+ $day =~ tr / /0/;
+ my $time = $cgiparams{'DAY'} ? "$2" : "$day/$2" ;
+ print "$time $3\r\n";
+
+ }
+ exit 0;
}
&Header::showhttpheaders();
&Header::openbigbox('100%', 'left', '', $errormessage);
if ($errormessage) {
- &Header::openbox('100%', 'left', $Lang::tr{'error messages'});
- print "<font class='base'>$errormessage </font>\n";
- &Header::closebox();
+ &Header::openbox('100%', 'left', $Lang::tr{'error messages'});
+ print "<font class='base'>$errormessage </font>\n";
+ &Header::closebox();
}
&Header::openbox('100%', 'left', "$Lang::tr{'settings'}");
<form method='post' action='$ENV{'SCRIPT_NAME'}'>
<table width='100%'>
<tr>
- <td width='10%' class='base'>$Lang::tr{'month'}: </td>
- <td width='10%'>
- <select name='MONTH'>
+ <td width='10%' class='base'>$Lang::tr{'month'}: </td>
+ <td width='10%'>
+ <select name='MONTH'>
END
;
for (my $month = 0; $month < 12; $month++)
{
- print "\t<option ";
- if ($month == $cgiparams{'MONTH'}) {
- print "selected='selected' "; }
- print "value='$month'>$longmonths[$month]</option>\n";
+ print "\t<option ";
+ if ($month == $cgiparams{'MONTH'}) {
+ print "selected='selected' ";
+ }
+ print "value='$month'>$longmonths[$month]</option>\n";
}
print <<END
- </select>
- </td>
- <td width='10%' class='base' align='right'> $Lang::tr{'day'}: </td>
- <td width='40%'>
- <select name='DAY'>
+ </select>
+ </td>
+ <td width='10%' class='base' align='right'> $Lang::tr{'day'}: </td>
+ <td width='40%'>
+ <select name='DAY'>
END
;
print "<option value='0'>$Lang::tr{'all'}</option>\n";
for (my $day = 1; $day <= 31; $day++)
{
- print "\t<option ";
- if ($day == $cgiparams{'DAY'}) {
- print "selected='selected' "; }
- print "value='$day'>$day</option>\n";
+ print "\t<option ";
+ if ($day == $cgiparams{'DAY'}) {
+ print "selected='selected' ";
+ }
+ print "value='$day'>$day</option>\n";
}
print <<END
</select>
$start = 0 if ($start < 0);
my $prev;
- if ($start == 0) {
- $prev = -1;
- } else {
- $prev = $start - ${Header::viewsize};
- $prev = 0 if ( $prev < 0);
- }
-
+if ($start == 0) {
+ $prev = -1;
+} else {
+ $prev = $start - ${Header::viewsize};
+ $prev = 0 if ( $prev < 0);
+}
+
my $next;
- if ($start == $lastPageIndex) {
- $next = -1;
- } else {
- $next = $start + ${Header::viewsize};
- $next = $lines - ${Header::viewsize} if ($next >= $lines - ${Header::viewsize});
- }
+if ($start == $lastPageIndex) {
+ $next = -1;
+} else {
+ $next = $start + ${Header::viewsize};
+ $next = $lines - ${Header::viewsize} if ($next >= $lines - ${Header::viewsize});
+}
if ($logsettings{'LOGVIEW_REVERSE'} eq 'on') { @log = reverse @log; }
if ($lines != 0) { &oldernewer(); }
print <<END
<table width='100%' class='tbl'>
<tr>
- <th align='center' class='boldbase'><b>$Lang::tr{'time'}</b></th>
- <th align='center' class='boldbase'><b>$Lang::tr{'chain'}</b></th>
- <th align='center' class='boldbase'><b>$Lang::tr{'iface'}</b></th>
- <th align='center' class='boldbase'><b>$Lang::tr{'proto'}</b></th>
- <th align='center' class='boldbase'><b>$Lang::tr{'source'}<br/>$Lang::tr{'destination'}</b></th>
- <th align='center' class='boldbase'><b>$Lang::tr{'src port'}<br />$Lang::tr{'dst port'}</b></th>
- <th align='center' class='boldbase'><b>$Lang::tr{'country'}</b></th>
- <th align='center' class='boldbase'><b>$Lang::tr{'mac address'}</b></th>
+ <th align='center' class='boldbase'><b>$Lang::tr{'time'}</b></th>
+ <th align='center' class='boldbase'><b>$Lang::tr{'chain'}</b></th>
+ <th align='center' class='boldbase'><b>$Lang::tr{'iface'}</b></th>
+ <th align='center' class='boldbase'><b>$Lang::tr{'proto'}</b></th>
+ <th align='center' class='boldbase'><b>$Lang::tr{'source'}<br/>$Lang::tr{'destination'}</b></th>
+ <th align='center' class='boldbase'><b>$Lang::tr{'src port'}<br />$Lang::tr{'dst port'}</b></th>
+ <th align='center' class='boldbase'><b>$Lang::tr{'country'}</b></th>
+ <th align='center' class='boldbase'><b>$Lang::tr{'mac address'}</b></th>
</tr>
END
;
$lines = 0;
foreach $_ (@log)
{
- /^... (..) (..:..:..) [\w\-]+ kernel:(.*)(IN=.*)$/;
- my $day = $1;
- $day =~ tr / /0/;
- my $time = $cgiparams{'DAY'} ? "$2" : "$day/$2" ;
- my $comment = $3;
- my $packet = $4;
-
- my ($iface, $srcaddr, $dstaddr, $macaddr, $proto, $srcport, $dstport);
- $iface=$1 if $packet =~ /IN=(\w+)/;
- $srcaddr=$1 if $packet =~ /SRC=([\d\.]+)/;
- $dstaddr=$1 if $packet =~ /DST=([\d\.]+)/;
- $macaddr=$1 if $packet =~ /MAC=([\w+\:]+)/;
- $proto=$1 if $packet =~ /PROTO=(\w+)/;
- $srcport=$1 if $packet =~ /SPT=(\d+)/;
- $dstport=$1 if $packet =~ /DPT=(\d+)/;
-
- my $gi = Geo::IP::PurePerl->new();
- my $ccode = $gi->country_code_by_name($srcaddr);
- my $fcode = lc($ccode);
-
- my $servi = uc(getservbyport($srcport, lc($proto)));
- if ($servi ne '' && $srcport < 1024) {
- $srcport = "$srcport($servi)"; }
- $servi = uc(getservbyport($dstport, lc($proto)));
- if ($servi ne '' && $dstport < 1024) {
- $dstport = "$dstport($servi)";}
- my @mactemp = split(/:/,$macaddr);
- $macaddr = "$mactemp[6]:$mactemp[7]:$mactemp[8]:$mactemp[9]:$mactemp[10]:$mactemp[11]";
- my $col="";
- if ($lines % 2) {
- print "<tr>";
- $col="bgcolor='$color{'color20'}'"; }
- else {
- print "<tr>";
- $col="bgcolor='$color{'color22'}'"; }
- print <<END
-
- <td align='center' $col>$time</td>
- <td align='center' $col>$comment</td>
- <td align='center' $col>$iface</td>
- <td align='center' $col>$proto</td>
- <td align='center' $col><a href='/cgi-bin/ipinfo.cgi?ip=$srcaddr'>$srcaddr</a><br /><a href='/cgi-bin/ipinfo.cgi?ip=$dstaddr'>$dstaddr</a></td>
- <td align='center' $col>$srcport<br/>$dstport</td>
+ # If ipv6 uses a bridge, PHYSIN= contains the relevant iface information
+ # otherwise use IN=
+ my $packet = '';
+ if ($_ =~ /^... (..) (..:..:..) [\w\-]+ kernel:(.*)(IN=.*)(PHYSIN=.*)$/) { $packet = $5; }
+ elsif ($_ =~ /^... (..) (..:..:..) [\w\-]+ kernel:(.*)(IN=.*)$/) { $packet = $4; }
+ my $day = $1;
+ $day =~ tr / /0/;
+ my $time = $cgiparams{'DAY'} ? "$2" : "$day/$2" ;
+ my $chain = $3;
+
+ my ($iface, $srcaddr, $dstaddr, $macaddr, $proto, $srcport, $dstport);
+ if ($packet =~ /PHYSIN=(\w+)/) { $iface=$1; } elsif ($packet =~ /IN=(\w+)/) { $iface = $1; }
+ # Identify whether ipv4 or ipv6. Both are mutally exclusive.
+ if ($packet =~ /SRC\=(([\d]{1,3})(\.([\d]{1,3})){3})/) { $srcaddr=$1; }
+ if ($packet =~ /SRC\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/) { $srcaddr=$1; }
+ if ($packet =~ /DST\=(([\d]{1,3})(\.([\d]{1,3})){3})/) { $dstaddr=$1; }
+ if ($packet =~ /DST\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/) { $dstaddr=$1; }
+ $macaddr=$1 if $packet =~ /MAC=([\w+\:]+)/;
+ $proto=$1 if $packet =~ /PROTO=(\w+)/;
+ $srcport=$1 if $packet =~ /SPT=(\d+)/;
+ $dstport=$1 if $packet =~ /DPT=(\d+)/;
+
+ my $gi = Geo::IP::PurePerl->new();
+ my $ccode = $gi->country_code_by_name($srcaddr);
+ my $fcode = lc($ccode);
+
+ my $servi = uc(getservbyport($srcport, lc($proto)));
+ if ($servi ne '' && $srcport < 1024) {
+ $srcport = "$srcport($servi)";
+ }
+ $servi = uc(getservbyport($dstport, lc($proto)));
+ if ($servi ne '' && $dstport < 1024) {
+ $dstport = "$dstport($servi)";
+ }
+ my @mactemp = split(/:/,$macaddr);
+ $macaddr = "$mactemp[6]:$mactemp[7]:$mactemp[8]:$mactemp[9]:$mactemp[10]:$mactemp[11]";
+ my $col="";
+ if ($lines % 2) {
+ print "<tr>";
+ $col="bgcolor='$color{'color20'}'";
+ }
+ else {
+ print "<tr>";
+ $col="bgcolor='$color{'color22'}'";
+ }
+ print <<END
+
+ <td align='center' $col>$time</td>
+ <td align='center' $col>$chain</td>
+ <td align='center' $col>$iface</td>
+ <td align='center' $col>$proto</td>
+ <td align='center' $col><a href='/cgi-bin/ipinfo.cgi?ip=$srcaddr'>$srcaddr</a><br /><a href='/cgi-bin/ipinfo.cgi?ip=$dstaddr'>$dstaddr</a></td>
+ <td align='center' $col>$srcport<br/>$dstport</td>
END
-;
+ ;
# Get flag icon for of the country.
my $flag_icon = &GeoIP::get_flag_icon($fcode);
- if ( $flag_icon) {
+ if ( $flag_icon) {
print "<td align='center' $col><a href='../country.cgi#$fcode'><img src='$flag_icon' border='0' align='absmiddle' alt='$ccode'></a></td>";
} else {
print "<td align='center' $col></td>";
}
- print <<END
- <td align='center' $col>$macaddr</td>
-</tr>
+ print <<END
+ <td align='center' $col>$macaddr</td>
+ </tr>
END
- ;
- $lines++;
+ ;
+ $lines++;
}
print "</table>";
sub oldernewer
{
-print <<END
-<table width='100%'>
-<tr>
+ print <<END
+ <table width='100%'>
+ <tr>
END
-;
+ ;
-print "<td align='center' width='50%'>";
-if ($prev != -1) {
- print "<a href='/cgi-bin/logs.cgi/firewalllog.dat?0,$cgiparams{'MONTH'},$cgiparams{'DAY'}'>$Lang::tr{'first'}</a> ";
- print "<a href='/cgi-bin/logs.cgi/firewalllog.dat?$prev,$cgiparams{'MONTH'},$cgiparams{'DAY'}'>$Lang::tr{'older'}</a>"; }
-else {
- print "$Lang::tr{'first'} $Lang::tr{'older'}"; }
-print "</td>\n";
-
-print "<td align='center' width='50%'>";
-if ($next >= 0) {
- print "<a href='/cgi-bin/logs.cgi/firewalllog.dat?$next,$cgiparams{'MONTH'},$cgiparams{'DAY'}'>$Lang::tr{'newer'}</a> ";
- print "<a href='/cgi-bin/logs.cgi/firewalllog.dat?$lastPageIndex,$cgiparams{'MONTH'},$cgiparams{'DAY'}'>$Lang::tr{'last'}</a>"; }
-else {
- print "$Lang::tr{'newer'} $Lang::tr{'last'} "; }
-print "</td>\n";
+ print "<td align='center' width='50%'>";
+ if ($prev != -1) {
+ print "<a href='/cgi-bin/logs.cgi/firewalllog.dat?0,$cgiparams{'MONTH'},$cgiparams{'DAY'}'>$Lang::tr{'first'}</a> ";
+ print "<a href='/cgi-bin/logs.cgi/firewalllog.dat?$prev,$cgiparams{'MONTH'},$cgiparams{'DAY'}'>$Lang::tr{'older'}</a>";
+ }
+ else {
+ print "$Lang::tr{'first'} $Lang::tr{'older'}";
+ }
+ print "</td>\n";
-print <<END
-</tr>
-</table>
+ print "<td align='center' width='50%'>";
+ if ($next >= 0) {
+ print "<a href='/cgi-bin/logs.cgi/firewalllog.dat?$next,$cgiparams{'MONTH'},$cgiparams{'DAY'}'>$Lang::tr{'newer'}</a> ";
+ print "<a href='/cgi-bin/logs.cgi/firewalllog.dat?$lastPageIndex,$cgiparams{'MONTH'},$cgiparams{'DAY'}'>$Lang::tr{'last'}</a>";
+ }
+ else {
+ print "$Lang::tr{'newer'} $Lang::tr{'last'} ";
+ }
+ print "</td>\n";
+
+ print <<END
+ </tr>
+ </table>
END
-;
+ ;
}
# page inspired from the initial firewalllog.dat
#
# Modified for IPFire by Christian Schmidt
-# and Michael Tremer (www.ipfire.org)
+# and Michael Tremer (www.ipfire.org)
use strict;
use Geo::IP::PurePerl;
$cgiparams{'sortcolumn'} = 1;
my @shortmonths = ( 'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug',
- 'Sep', 'Oct', 'Nov', 'Dec' );
+ 'Sep', 'Oct', 'Nov', 'Dec' );
my @longmonths = ( $Lang::tr{'january'}, $Lang::tr{'february'}, $Lang::tr{'march'},
- $Lang::tr{'april'}, $Lang::tr{'may'}, $Lang::tr{'june'}, $Lang::tr{'july'}, $Lang::tr{'august'},
- $Lang::tr{'september'}, $Lang::tr{'october'}, $Lang::tr{'november'},
- $Lang::tr{'december'} );
+ $Lang::tr{'april'}, $Lang::tr{'may'}, $Lang::tr{'june'}, $Lang::tr{'july'}, $Lang::tr{'august'},
+ $Lang::tr{'september'}, $Lang::tr{'october'}, $Lang::tr{'november'},
+ $Lang::tr{'december'} );
my @now = localtime();
my $dow = $now[6];
if ($cgiparams{'ACTION'} eq $Lang::tr{'save'})
{
- &General::writehash("${General::swroot}/fwlogs/ipsettings", \%settings);
+ &General::writehash("${General::swroot}/fwlogs/ipsettings", \%settings);
}
my $start = -1;
if ($ENV{'QUERY_STRING'} && $cgiparams{'ACTION'} ne $Lang::tr{'update'})
{
- my @temp = split(',',$ENV{'QUERY_STRING'});
- $start = $temp[0];
- $cgiparams{'MONTH'} = $temp[1];
- $cgiparams{'DAY'} = $temp[2];
+ my @temp = split(',',$ENV{'QUERY_STRING'});
+ $start = $temp[0];
+ $cgiparams{'MONTH'} = $temp[1];
+ $cgiparams{'DAY'} = $temp[2];
}
if (!($cgiparams{'MONTH'} =~ /^(0|1|2|3|4|5|6|7|8|9|10|11)$/) ||
!($cgiparams{'DAY'} =~ /^(1|2|3|4|5|6|7|8|9|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|26|27|28|29|30|31)$/))
{
- $cgiparams{'DAY'} = $now[3];
- $cgiparams{'MONTH'} = $now[4];
+ $cgiparams{'DAY'} = $now[3];
+ $cgiparams{'MONTH'} = $now[4];
}
elsif($cgiparams{'ACTION'} eq '>>')
{
- my @temp_then=();
- my @temp_now = localtime(time);
- $temp_now[4] = $cgiparams{'MONTH'};
- $temp_now[3] = $cgiparams{'DAY'};
- @temp_then = localtime(POSIX::mktime(@temp_now) + 86400);
- ## Retrieve the same time on the next day -
- ## 86400 seconds in a day
- $cgiparams{'MONTH'} = $temp_then[4];
- $cgiparams{'DAY'} = $temp_then[3];
+ my @temp_then=();
+ my @temp_now = localtime(time);
+ $temp_now[4] = $cgiparams{'MONTH'};
+ $temp_now[3] = $cgiparams{'DAY'};
+ @temp_then = localtime(POSIX::mktime(@temp_now) + 86400);
+ ## Retrieve the same time on the next day -
+ ## 86400 seconds in a day
+ $cgiparams{'MONTH'} = $temp_then[4];
+ $cgiparams{'DAY'} = $temp_then[3];
}
elsif($cgiparams{'ACTION'} eq '<<')
{
- my @temp_then=();
- my @temp_now = localtime(time);
- $temp_now[4] = $cgiparams{'MONTH'};
- $temp_now[3] = $cgiparams{'DAY'};
- @temp_then = localtime(POSIX::mktime(@temp_now) - 86400);
- ## Retrieve the same time on the previous day -
- ## 86400 seconds in a day
- $cgiparams{'MONTH'} = $temp_then[4];
- $cgiparams{'DAY'} = $temp_then[3];
+ my @temp_then=();
+ my @temp_now = localtime(time);
+ $temp_now[4] = $cgiparams{'MONTH'};
+ $temp_now[3] = $cgiparams{'DAY'};
+ @temp_then = localtime(POSIX::mktime(@temp_now) - 86400);
+ ## Retrieve the same time on the previous day -
+ ## 86400 seconds in a day
+ $cgiparams{'MONTH'} = $temp_then[4];
+ $cgiparams{'DAY'} = $temp_then[3];
}
if (($cgiparams{'DAY'} ne $now[3]) || ($cgiparams{'MONTH'} ne $now[4]))
{
- my @then = ();
- if ( ( $cgiparams{'MONTH'} eq $now[4]) && ($cgiparams{'DAY'} > $now[3]) ||
- ( $cgiparams{'MONTH'} > $now[4] ) ) {
- @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1901 ));
- } else {
- @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1900 ));
- }
- $tdoy = $then[7];
- my $lastleap=($year-1)%4;
- if ($tdoy>$doy) {
- if ($lastleap == 0 && $tdoy < 60) {
- $doy=$tdoy+366;
- } else {
- $doy=$doy+365;
- }
- }
+ my @then = ();
+ if ( ( $cgiparams{'MONTH'} eq $now[4]) && ($cgiparams{'DAY'} > $now[3]) ||
+ ( $cgiparams{'MONTH'} > $now[4] ) ) {
+ @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1901 ));
+ } else {
+ @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1900 ));
+ }
+ $tdoy = $then[7];
+ my $lastleap=($year-1)%4;
+ if ($tdoy>$doy) {
+ if ($lastleap == 0 && $tdoy < 60) {
+ $doy=$tdoy+366;
+ } else {
+ $doy=$doy+365;
+ }
+ }
}
my $datediff=0;
my $dowd=0;
my $multifile=0;
if ($tdoy ne $doy) {
- $datediff=int(($doy-$tdoy)/7);
- $dowd=($doy-$tdoy)%7;
- if (($dow-$dowd)<1) {
- $datediff=$datediff+1;
- }
- if (($dow-$dowd)==0) {
- $multifile=1;
- }
+ $datediff=int(($doy-$tdoy)/7);
+ $dowd=($doy-$tdoy)%7;
+ if (($dow-$dowd)<1) {
+ $datediff=$datediff+1;
+ }
+ if (($dow-$dowd)==0) {
+ $multifile=1;
+ }
}
my $monthstr = $shortmonths[$cgiparams{'MONTH'}];
my $day = $cgiparams{'DAY'};
my $daystr='';
if ($day <= 9) {
- $daystr = " $day"; }
+ $daystr = " $day";
+}
else {
- $daystr = $day;
+ $daystr = $day;
}
my $skip=0;
my $filestr='';
if ($datediff==0) {
- $filestr="/var/log/messages";
+ $filestr="/var/log/messages";
} else {
- $filestr="/var/log/messages.$datediff";
- $filestr = "$filestr.gz" if -f "$filestr.gz";
+ $filestr="/var/log/messages.$datediff";
+ $filestr = "$filestr.gz" if -f "$filestr.gz";
}
if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
- $errormessage = "$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
- $skip=1;
- # Note: This is in case the log does not exist for that date
+ $errormessage = "$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
+ $skip=1;
+ # Note: This is in case the log does not exist for that date
}
my $lines = 0;
my @log=();
if (!$skip)
{
- while (<FILE>)
- {
- if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
- $log[$lines] = $_;
- $lines++;
- }
- }
- close (FILE);
+ while (<FILE>)
+ {
+ if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
+ $log[$lines] = $_;
+ $lines++;
+ }
+ }
+ close (FILE);
}
$skip=0;
if ($multifile) {
- $datediff=$datediff-1;
- if ($datediff==0) {
- $filestr="/var/log/messages";
- } else {
- $filestr="/var/log/messages.$datediff";
- $filestr = "$filestr.gz" if -f "$filestr.gz";
- }
- if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
- $errormessage="$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
- $skip=1;
- }
- if (!$skip) {
- while (<FILE>) {
- if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
- $log[$lines] = $_;
- $lines++;
- }
- }
- close (FILE);
- }
+ $datediff=$datediff-1;
+ if ($datediff==0) {
+ $filestr="/var/log/messages";
+ } else {
+ $filestr="/var/log/messages.$datediff";
+ $filestr = "$filestr.gz" if -f "$filestr.gz";
+ }
+ if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
+ $errormessage="$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
+ $skip=1;
+ }
+ if (!$skip) {
+ while (<FILE>) {
+ if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
+ $log[$lines] = $_;
+ $lines++;
+ }
+ }
+ close (FILE);
+ }
}
my $MODNAME="fwlogs";
if ($errormessage) {
- &Header::openbox('100%', 'left', $Lang::tr{'error messages'});
- print "<font class='base'>$errormessage </font>\n";
- &Header::closebox();
+ &Header::openbox('100%', 'left', $Lang::tr{'error messages'});
+ print "<font class='base'>$errormessage </font>\n";
+ &Header::closebox();
}
&Header::openbox('100%', 'left', "$Lang::tr{'settings'}");
<form method='post' action='$ENV{'SCRIPT_NAME'}'>
<table width='100%'>
<tr>
- <td width='10%' class='base'>$Lang::tr{'month'}: </td>
- <td width='10%'>
- <select name='MONTH'>
+ <td width='10%' class='base'>$Lang::tr{'month'}: </td>
+ <td width='10%'>
+ <select name='MONTH'>
END
;
my $month;
for ($month = 0; $month < 12; $month++)
{
- print "\t<option ";
- if ($month == $cgiparams{'MONTH'}) {
- print "selected='selected' "; }
- print "value='$month'>$longmonths[$month]</option>\n";
+ print "\t<option ";
+ if ($month == $cgiparams{'MONTH'}) {
+ print "selected='selected' "; }
+ print "value='$month'>$longmonths[$month]</option>\n";
}
print <<END
- </select>
- </td>
- <td width='10%' class='base' align='right'> $Lang::tr{'day'}: </td>
- <td width='40%'>
- <select name='DAY'>
+ </select>
+ </td>
+ <td width='10%' class='base' align='right'> $Lang::tr{'day'}: </td>
+ <td width='40%'>
+ <select name='DAY'>
END
;
for ($day = 1; $day <= 31; $day++)
{
- print "\t<option ";
- if ($day == $cgiparams{'DAY'}) {
- print "selected='selected' "; }
- print "value='$day'>$day</option>\n";
+ print "\t<option ";
+ if ($day == $cgiparams{'DAY'}) {
+ print "selected='selected' "; }
+ print "value='$day'>$day</option>\n";
}
if( $cgiparams{'pienumber'} != 0){$pienumber=$cgiparams{'pienumber'};}
if( $cgiparams{'otherspie'} != 0){$otherspie=$cgiparams{'otherspie'};}
if( $cgiparams{'showpie'} != 0){$showpie=$cgiparams{'showpie'};}
if( $cgiparams{'sortcolumn'} != 0){$sortcolumn=$cgiparams{'sortcolumn'};}
-
print <<END
</select>
</td>
foreach $_ (@log)
{
- /^... (..) (..:..:..) [\w\-]+ kernel:(.*)(IN=.*)$/;
- my $packet = $4;
- $packet =~ /IN=(\w+)/; my $iface=$1; if ( $1 =~ /2./ ){ $iface="";}
- $packet =~ /SRC=([\d\.]+)/; my $srcaddr=$1;
-
- if($iface eq $red_interface) {
- if($srcaddr ne '') {
- my $ccode = $gi->country_code_by_name($srcaddr);
- if( $ccode eq '') {
- $ccode = 'unknown';
- }
- $tabjc{$ccode} = $tabjc{$ccode} + 1 ;
- if(($tabjc{$ccode} == 1) && ($lines < $pienumber)) { $lines = $lines + 1; }
- $linesjc++;
- }
- }
- else {
- if($iface ne '') {
- $tabjc{$iface} = $tabjc{$iface} + 1 ;
- if(($tabjc{$iface} == 1) && ($lines < $pienumber)) { $lines = $lines + 1; }
- $linesjc++;
- }
- }
+ # If ipv6 uses bridge, use PHYSIN for iface, otherwise IN
+ if (/^... (..) (..:..:..) [\w\-]+ kernel:(.*)(PHYSIN=.*)$/) {}
+ elsif (/^... (..) (..:..:..) [\w\-]+ kernel:(.*)(IN=.*)$/) {}
+ my $packet = $4;
+ my $iface = '';
+ if ($packet =~ /PHYSIN=(\w+)/) { $iface = $1; } elsif ($packet =~ /IN=(\w+)/) { $iface = $1; }
+ if ( $1 =~ /2./ ) { $iface=''; }
+ my $srcaddr = '';
+ # Find ipv4 and ipv6 addresses
+ if ($packet =~ /SRC\=(([\d]{1,3})(\.([\d]{1,3})){3})/) { $srcaddr = $1; }
+ elsif ($packet =~ /SRC\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/) { $srcaddr = $1; }
+
+ if($iface eq $red_interface) {
+ # Traffic from red
+ if($srcaddr ne '') {
+ # srcaddr is set
+ my $ccode = $gi->country_code_by_name($srcaddr);
+ if ($ccode eq '') {
+ $ccode = 'unknown';
+ }
+ $tabjc{$ccode} = $tabjc{$ccode} + 1;
+ if(($tabjc{$ccode} == 1) && ($lines < $pienumber)) { $lines = $lines + 1; }
+ $linesjc++;
+ }
+ }
+ else {
+ # Traffic not from red
+ if($iface ne '') {
+ $tabjc{$iface} = $tabjc{$iface} + 1 ;
+ if(($tabjc{$iface} == 1) && ($lines < $pienumber)) { $lines = $lines + 1; }
+ $linesjc++;
+ }
+ else {
+ # What to do with empty iface lines?
+ # This probably is traffic from ipfire itself (IN= OUT=XY)?
+ }
+ }
}
$pienumber = $lines;
my $indice=0;
my @tabjc2;
-if ($sortcolumn == 1)
-{
- @tabjc2 = sort { $b <=> $a } values (%tabjc);
+if ($sortcolumn == 1) {
+ @tabjc2 = sort { $b <=> $a } values (%tabjc);
}
-else
-{
- @tabjc2 = sort { $a <=> $b } keys (%tabjc);
+else {
+ @tabjc2 = sort { $a <=> $b } keys (%tabjc);
}
my $colour=1;
#ips sort by hits number
my $v;
-if ($sortcolumn == 1)
-{
- for ($v=0;$v<$pienumber;$v++){
- findkey($tabjc2[$v]);
- }
+if ($sortcolumn == 1) {
+ for ($v=0;$v<$pienumber;$v++){
+ findkey($tabjc2[$v]);
+ }
}
-else
-{
- foreach $v (@tabjc2) {
- $key[$indice] = $v;
- $value[$indice] = $tabjc{$v};
- $indice++;
- }
+else {
+ foreach $v (@tabjc2) {
+ $key[$indice] = $v;
+ $value[$indice] = $tabjc{$v};
+ $indice++;
+ }
}
my @ips;
if($cgiparams{'otherspie'} == 2 ){}
else{
- my $numothers;
- for($o=0;$o<$pienumber;$o++){
- $numothers = $numothers + $numb[$o];
- }
- $numothers = $linesjc - $numothers;
- if ($numothers > 0) {
- $ips[$pienumber]="$Lang::tr{'otherip'}";
- $numb[$pienumber] = $numothers;
- }
+ my $numothers;
+ for($o=0;$o<$pienumber;$o++){
+ $numothers = $numothers + $numb[$o];
+ }
+ $numothers = $linesjc - $numothers;
+ if ($numothers > 0) {
+ $ips[$pienumber]="$Lang::tr{'otherip'}";
+ $numb[$pienumber] = $numothers;
+ }
}
my @data = (\@ips,\@numb);
&General::readhash("/srv/web/ipfire/html/themes/".$mainsettings{'THEME'}."/include/colors.txt", \%color);
if ($showpie != 2 && $pienumber <= 50 && $pienumber != 0) {
- my $mygraph = GD::Graph::pie->new(500, 350);
- $mygraph->set(
- 'title' => '',
- 'pie_height' => 50,
- 'start_angle' => 89
- ) or warn $mygraph->error;
-
- $mygraph->set_value_font(GD::gdMediumBoldFont);
- $mygraph->set( dclrs => [ "$color{'color1'}" , "$color{'color2'}" , "$color{'color3'}" , "$color{'color4'}" , "$color{'color5'}" , "$color{'color6'}" , "$color{'color7'}" , "$color{'color8'}" , "$color{'color9'}" , "$color{'color10'}" ] );
- my $myimage = $mygraph->plot(\@data) or die $mygraph->error;
-
- my @filenames = glob("/srv/web/ipfire/html/graphs/fwlog-country*.png");
- unlink(@filenames);
- my $imagerandom = rand(1000000);
- my $imagename = "/srv/web/ipfire/html/graphs/fwlog-country$imagerandom.png";
- open(FILE,">$imagename");
- print FILE $myimage->png;
- close(FILE);
- #####################################################
- print "<div style='text-align:center;'>";
- print "<img src='/graphs/fwlog-country$imagerandom.png'>";
- print "</div>";
+ my $mygraph = GD::Graph::pie->new(500, 350);
+ $mygraph->set(
+ 'title' => '',
+ 'pie_height' => 50,
+ 'start_angle' => 89
+ ) or warn $mygraph->error;
+
+ $mygraph->set_value_font(GD::gdMediumBoldFont);
+ $mygraph->set( dclrs => [ "$color{'color1'}" , "$color{'color2'}" , "$color{'color3'}" , "$color{'color4'}" , "$color{'color5'}" , "$color{'color6'}" , "$color{'color7'}" , "$color{'color8'}" , "$color{'color9'}" , "$color{'color10'}" ] );
+ my $myimage = $mygraph->plot(\@data) or die $mygraph->error;
+
+ my @filenames = glob("/srv/web/ipfire/html/graphs/fwlog-country*.png");
+ unlink(@filenames);
+ my $imagerandom = rand(1000000);
+ my $imagename = "/srv/web/ipfire/html/graphs/fwlog-country$imagerandom.png";
+ open(FILE,">$imagename");
+ print FILE $myimage->png;
+ close(FILE);
+ #####################################################
+ print "<div style='text-align:center;'>";
+ print "<img src='/graphs/fwlog-country$imagerandom.png'>";
+ print "</div>";
}
-
print <<END
<table width='100%' class='tbl'>
<tr>
for($s=0;$s<$lines;$s++)
{
- $show++;
- $percent = $value[$s] * 100 / $linesjc;
- $percent = sprintf("%.f", $percent);
- $total = $total + $value[$s];
- my $colorIndex = $color % 10;
- if($colorIndex == 0) {
- $colorIndex = 10;
- }
- $col="bgcolor='$color{\"color$colorIndex\"}'";
- $color++;
- print "<tr>";
-
- print "<td align='center' $col>";
-
- # Dont show details button for "unknown" location.
- if ($key[$s] ne 'unknown') {
- print"<form method='post' action='showrequestfromcountry.dat'>";
- print"<input type='hidden' name='MONTH' value='$cgiparams{'MONTH'}'>";
- print"<input type='hidden' name='DAY' value='$cgiparams{'DAY'}'>";
- print"<input type='hidden' name='country' value='$key[$s]'>";
- print"<input type='submit' value='details'></form>";
- }
-
- if($key[$s] eq 'blue0' || $key[$s] eq 'green0' || $key[$s] eq 'orange0') {
- print "<td align='center' $col>$key[$s]</td>";
- }
- else {
- my $fcode = lc($key[$s]);
-
- # Get flag icon for of the country.
- my $flag_icon = &GeoIP::get_flag_icon($fcode);
-
- if($flag_icon) {
- print "<td align='center' $col><a href='/cgi-bin/country.cgi#$fcode'><img src='$flag_icon' border='0' align='absmiddle' alt='$key[$s]' title='$key[$s]'></a></td>";
- } else {
+ $show++;
+ $percent = $value[$s] * 100 / $linesjc;
+ $percent = sprintf("%.f", $percent);
+ $total = $total + $value[$s];
+ # colors are numbered 1 to 10
+ my $colorIndex = ($color % 10) + 1;
+ $col="bgcolor='$color{\"color$colorIndex\"}'";
+ $color++;
+ print "<tr>";
+
+ print "<td align='center' $col>";
+
+ # Dont show details button for "unknown" location.
+ if ($key[$s] ne 'unknown') {
+ print"<form method='post' action='showrequestfromcountry.dat'>";
+ print"<input type='hidden' name='MONTH' value='$cgiparams{'MONTH'}'>";
+ print"<input type='hidden' name='DAY' value='$cgiparams{'DAY'}'>";
+ print"<input type='hidden' name='country' value='$key[$s]'>";
+ print"<input type='submit' value='details'></form>";
+ }
+ elsif ($key[$s] eq 'unknown') {
+ print "unknown";
+ }
+ # Looks dangerous to use hardcoded interface names here. Probably needs fixing.
+ if ($key[$s] eq 'blue0' || $key[$s] eq 'green0' || $key[$s] eq 'orange0' ) {
print "<td align='center' $col>$key[$s]</td>";
- }
- }
- print "<td align='center' $col>$value[$s]</td>";
- print "<td align='center' $col>$percent</td>";
- print "</tr>";
+ }
+ else {
+ my $fcode = lc($key[$s]);
+
+ # Get flag icon for of the country.
+ my $flag_icon = &GeoIP::get_flag_icon($fcode);
+
+ if($flag_icon) {
+ print "<td align='center' $col><a href='/cgi-bin/country.cgi#$fcode'><img src='$flag_icon' border='0' align='absmiddle' alt='$key[$s]' title='$key[$s]'></a></td>";
+ } else {
+ print "<td align='center' $col>$key[$s]</td>";
+ }
+ }
+ print "<td align='center' $col>$value[$s]</td>";
+ print "<td align='center' $col>$percent</td>";
+ print "</tr>";
}
if($cgiparams{'otherspie'} == 2 ){}
else{
- my $colorIndex = $color % 10;
- if($colorIndex == 0) {
- $colorIndex = 10;
- }
- $col="bgcolor='$color{\"color$colorIndex\"}'";
- print "<tr>";
-
-if ( $linesjc ne "0")
-{
-my $dif;
-$dif = $linesjc - $total;
-$percent = $dif * 100 / $linesjc;
-$percent = sprintf("%.f", $percent);
-print <<END
-<td align='center' $col></TD>
-<td align='center' $col>$Lang::tr{'other countries'}</td>
-<td align='center' $col>$dif</TD>
-<td align='center' $col>$percent</TD>
-</tr>
+ # colors are numbered 1 to 10
+ my $colorIndex = ($color % 10) + 1;
+ $col="bgcolor='$color{\"color$colorIndex\"}'";
+ print "<tr>";
+
+ if ( $linesjc ne "0")
+ {
+ my $dif;
+ $dif = $linesjc - $total;
+ $percent = $dif * 100 / $linesjc;
+ $percent = sprintf("%.f", $percent);
+ print <<END
+ <td align='center' $col></TD>
+ <td align='center' $col>$Lang::tr{'other countries'}</td>
+ <td align='center' $col>$dif</TD>
+ <td align='center' $col>$percent</TD>
+ </tr>
END
-;
-}
+ ;
+ }
}
print <<END
</TABLE>
&Header::closepage();
sub findkey {
- my $v;
- foreach $v (@keytabjc) {
- if ($tabjc{$v} eq $_[0]) {
- delete $tabjc{$v};
- $key[$indice] = "$v";
- $value[$indice] = $_[0];
- $indice++;
- last;
- }
- }
+ my $v;
+ foreach $v (@keytabjc) {
+ if ($tabjc{$v} eq $_[0]) {
+ delete $tabjc{$v};
+ $key[$indice] = "$v";
+ $value[$indice] = $_[0];
+ $indice++;
+ last;
+ }
+ }
}
sub checkversion {
- #Automatic Updates is disabled
- return "0","0";
+ #Automatic Updates is disabled
+ return "0","0";
}
# page inspired from the initial firewalllog.dat
#
# Modified for IPFire by Christian Schmidt
-# and Michael Tremer (www.ipfire.org)
+# and Michael Tremer (www.ipfire.org)
use strict;
use Geo::IP::PurePerl;
$cgiparams{'sortcolumn'} = 1;
my @shortmonths = ( 'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug',
- 'Sep', 'Oct', 'Nov', 'Dec' );
+ 'Sep', 'Oct', 'Nov', 'Dec' );
my @longmonths = ( $Lang::tr{'january'}, $Lang::tr{'february'}, $Lang::tr{'march'},
- $Lang::tr{'april'}, $Lang::tr{'may'}, $Lang::tr{'june'}, $Lang::tr{'july'}, $Lang::tr{'august'},
- $Lang::tr{'september'}, $Lang::tr{'october'}, $Lang::tr{'november'},
- $Lang::tr{'december'} );
+ $Lang::tr{'april'}, $Lang::tr{'may'}, $Lang::tr{'june'}, $Lang::tr{'july'}, $Lang::tr{'august'},
+ $Lang::tr{'september'}, $Lang::tr{'october'}, $Lang::tr{'november'},
+ $Lang::tr{'december'} );
my @now = localtime();
my $dow = $now[6];
if ($cgiparams{'ACTION'} eq $Lang::tr{'save'})
{
- &General::writehash("${General::swroot}/fwlogs/ipsettings", \%settings);
+ &General::writehash("${General::swroot}/fwlogs/ipsettings", \%settings);
}
my $start = -1;
if ($ENV{'QUERY_STRING'} && $cgiparams{'ACTION'} ne $Lang::tr{'update'})
{
- my @temp = split(',',$ENV{'QUERY_STRING'});
- $start = $temp[0];
- $cgiparams{'MONTH'} = $temp[1];
- $cgiparams{'DAY'} = $temp[2];
+ my @temp = split(',',$ENV{'QUERY_STRING'});
+ $start = $temp[0];
+ $cgiparams{'MONTH'} = $temp[1];
+ $cgiparams{'DAY'} = $temp[2];
}
if (!($cgiparams{'MONTH'} =~ /^(0|1|2|3|4|5|6|7|8|9|10|11)$/) ||
!($cgiparams{'DAY'} =~ /^(1|2|3|4|5|6|7|8|9|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|26|27|28|29|30|31)$/))
{
- $cgiparams{'DAY'} = $now[3];
- $cgiparams{'MONTH'} = $now[4];
+ $cgiparams{'DAY'} = $now[3];
+ $cgiparams{'MONTH'} = $now[4];
}
elsif($cgiparams{'ACTION'} eq '>>')
{
- my @temp_then=();
- my @temp_now = localtime(time);
- $temp_now[4] = $cgiparams{'MONTH'};
- $temp_now[3] = $cgiparams{'DAY'};
- @temp_then = localtime(POSIX::mktime(@temp_now) + 86400);
- ## Retrieve the same time on the next day -
- ## 86400 seconds in a day
- $cgiparams{'MONTH'} = $temp_then[4];
- $cgiparams{'DAY'} = $temp_then[3];
+ my @temp_then=();
+ my @temp_now = localtime(time);
+ $temp_now[4] = $cgiparams{'MONTH'};
+ $temp_now[3] = $cgiparams{'DAY'};
+ @temp_then = localtime(POSIX::mktime(@temp_now) + 86400);
+ ## Retrieve the same time on the next day -
+ ## 86400 seconds in a day
+ $cgiparams{'MONTH'} = $temp_then[4];
+ $cgiparams{'DAY'} = $temp_then[3];
}
elsif($cgiparams{'ACTION'} eq '<<')
{
- my @temp_then=();
- my @temp_now = localtime(time);
- $temp_now[4] = $cgiparams{'MONTH'};
- $temp_now[3] = $cgiparams{'DAY'};
- @temp_then = localtime(POSIX::mktime(@temp_now) - 86400);
- ## Retrieve the same time on the previous day -
- ## 86400 seconds in a day
- $cgiparams{'MONTH'} = $temp_then[4];
- $cgiparams{'DAY'} = $temp_then[3];
+ my @temp_then=();
+ my @temp_now = localtime(time);
+ $temp_now[4] = $cgiparams{'MONTH'};
+ $temp_now[3] = $cgiparams{'DAY'};
+ @temp_then = localtime(POSIX::mktime(@temp_now) - 86400);
+ ## Retrieve the same time on the previous day -
+ ## 86400 seconds in a day
+ $cgiparams{'MONTH'} = $temp_then[4];
+ $cgiparams{'DAY'} = $temp_then[3];
}
if (($cgiparams{'DAY'} ne $now[3]) || ($cgiparams{'MONTH'} ne $now[4]))
{
- my @then = ();
- if ( ( $cgiparams{'MONTH'} eq $now[4]) && ($cgiparams{'DAY'} > $now[3]) ||
- ( $cgiparams{'MONTH'} > $now[4] ) ) {
- @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1901 ));
- } else {
- @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1900 ));
- }
- $tdoy = $then[7];
- my $lastleap=($year-1)%4;
- if ($tdoy>$doy) {
- if ($lastleap == 0 && $tdoy < 60) {
- $doy=$tdoy+366;
- } else {
- $doy=$doy+365;
- }
- }
+ my @then = ();
+ if ( ( $cgiparams{'MONTH'} eq $now[4]) && ($cgiparams{'DAY'} > $now[3]) ||
+ ( $cgiparams{'MONTH'} > $now[4] ) ) {
+ @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1901 ));
+ } else {
+ @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1900 ));
+ }
+ $tdoy = $then[7];
+ my $lastleap=($year-1)%4;
+ if ($tdoy>$doy) {
+ if ($lastleap == 0 && $tdoy < 60) {
+ $doy=$tdoy+366;
+ } else {
+ $doy=$doy+365;
+ }
+ }
}
my $datediff=0;
my $dowd=0;
my $multifile=0;
if ($tdoy ne $doy) {
- $datediff=int(($doy-$tdoy)/7);
- $dowd=($doy-$tdoy)%7;
- if (($dow-$dowd)<1) {
- $datediff=$datediff+1;
- }
- if (($dow-$dowd)==0) {
- $multifile=1;
- }
+ $datediff=int(($doy-$tdoy)/7);
+ $dowd=($doy-$tdoy)%7;
+ if (($dow-$dowd)<1) {
+ $datediff=$datediff+1;
+ }
+ if (($dow-$dowd)==0) {
+ $multifile=1;
+ }
}
my $monthstr = $shortmonths[$cgiparams{'MONTH'}];
my $day = $cgiparams{'DAY'};
my $daystr='';
if ($day <= 9) {
- $daystr = " $day"; }
+ $daystr = " $day"; }
else {
- $daystr = $day;
+ $daystr = $day;
}
my $skip=0;
my $filestr='';
if ($datediff==0) {
- $filestr="/var/log/messages";
+ $filestr="/var/log/messages";
} else {
$filestr="/var/log/messages.$datediff";
$filestr = "$filestr.gz" if -f "$filestr.gz";
}
if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
- $errormessage = "$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
- $skip=1;
- # Note: This is in case the log does not exist for that date
+ $errormessage = "$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
+ $skip=1;
+ # Note: This is in case the log does not exist for that date
}
my $lines = 0;
my @log=();
if (!$skip)
{
- while (<FILE>)
- {
- if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
- $log[$lines] = $_;
- $lines++;
- }
- }
- close (FILE);
+ while (<FILE>)
+ {
+ if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
+ $log[$lines] = $_;
+ $lines++;
+ }
+ }
+ close (FILE);
}
$skip=0;
if ($multifile) {
- $datediff=$datediff-1;
- if ($datediff==0) {
- $filestr="/var/log/messages";
- } else {
- $filestr="/var/log/messages.$datediff";
- $filestr = "$filestr.gz" if -f "$filestr.gz";
- }
- if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
- $errormessage="$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
- $skip=1;
- }
- if (!$skip) {
- while (<FILE>) {
- if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
- $log[$lines] = $_;
- $lines++;
- }
- }
- close (FILE);
- }
+ $datediff=$datediff-1;
+ if ($datediff==0) {
+ $filestr="/var/log/messages";
+ } else {
+ $filestr="/var/log/messages.$datediff";
+ $filestr = "$filestr.gz" if -f "$filestr.gz";
+ }
+ if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
+ $errormessage="$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
+ $skip=1;
+ }
+ if (!$skip) {
+ while (<FILE>) {
+ if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
+ $log[$lines] = $_;
+ $lines++;
+ }
+ }
+ close (FILE);
+ }
}
my $MODNAME="fwlogs";
if ($errormessage) {
- &Header::openbox('100%', 'left', $Lang::tr{'error messages'});
- print "<font class='base'>$errormessage </font>\n";
- &Header::closebox();
+ &Header::openbox('100%', 'left', $Lang::tr{'error messages'});
+ print "<font class='base'>$errormessage </font>\n";
+ &Header::closebox();
}
&Header::openbox('100%', 'left', "$Lang::tr{'settings'}");
<form method='post' action='$ENV{'SCRIPT_NAME'}'>
<table width='100%'>
<tr>
- <td width='10%' class='base'>$Lang::tr{'month'}: </td>
- <td width='10%'>
- <select name='MONTH'>
+ <td width='10%' class='base'>$Lang::tr{'month'}: </td>
+ <td width='10%'>
+ <select name='MONTH'>
END
;
my $month;
for ($month = 0; $month < 12; $month++)
{
- print "\t<option ";
- if ($month == $cgiparams{'MONTH'}) {
- print "selected='selected' "; }
- print "value='$month'>$longmonths[$month]</option>\n";
+ print "\t<option ";
+ if ($month == $cgiparams{'MONTH'}) {
+ print "selected='selected' ";
+ }
+ print "value='$month'>$longmonths[$month]</option>\n";
}
print <<END
- </select>
- </td>
- <td width='10%' class='base' align='right'> $Lang::tr{'day'}: </td>
- <td width='40%'>
- <select name='DAY'>
+ </select>
+ </td>
+ <td width='10%' class='base' align='right'> $Lang::tr{'day'}: </td>
+ <td width='40%'>
+ <select name='DAY'>
END
;
for ($day = 1; $day <= 31; $day++)
{
- print "\t<option ";
- if ($day == $cgiparams{'DAY'}) {
- print "selected='selected' "; }
- print "value='$day'>$day</option>\n";
+ print "\t<option ";
+ if ($day == $cgiparams{'DAY'}) {
+ print "selected='selected' ";
+ }
+ print "value='$day'>$day</option>\n";
}
if( $cgiparams{'pienumber'} != 0){$pienumber=$cgiparams{'pienumber'};}
$lines = 0;
foreach $_ (@log)
{
- if($_ =~ /SRC\=([\d\.]+)/){
- $tabjc{$1} = $tabjc{$1} + 1 ;
- if(($tabjc{$1} == 1) && ($lines < $pienumber)) { $lines = $lines + 1; }
- $linesjc++;
- }
+ # Extract ipv4 or ipv6 address
+ if (($_ =~ /SRC\=(([\d]{1,3})(\.([\d]{1,3})){3})/) or ($_ =~ /SRC\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/)) {
+ $tabjc{$1} = $tabjc{$1} + 1 ;
+ if(($tabjc{$1} == 1) && ($lines < $pienumber)) { $lines = $lines + 1; }
+ $linesjc++;
+ }
}
$pienumber = $lines;
if ($sortcolumn == 1)
{
- @tabjc2 = sort { $b <=> $a } values (%tabjc);
+ @tabjc2 = sort { $b <=> $a } values (%tabjc);
}
else
{
- @tabjc2 = sort { $a <=> $b } keys (%tabjc);
+ @tabjc2 = sort { $a <=> $b } keys (%tabjc);
}
my $colour=1;
if ($sortcolumn == 1)
{
- for ($v=0;$v<$pienumber;$v++){
- findkey($tabjc2[$v]);
- }
+ for ($v=0;$v<$pienumber;$v++){
+ findkey($tabjc2[$v]);
+ }
}
else
{
- foreach $v (@tabjc2) {
- $key[$indice] = $v;
- $value[$indice] = $tabjc{$v};
- $indice++;
- }
+ foreach $v (@tabjc2) {
+ $key[$indice] = $v;
+ $value[$indice] = $tabjc{$v};
+ $indice++;
+ }
}
my @ips;
if($cgiparams{'otherspie'} == 2 ){}
else{
- my $numothers;
- for($o=0;$o<$pienumber;$o++){
- $numothers = $numothers + $numb[$o];
- }
- $numothers = $linesjc - $numothers;
- if ($numothers > 0) {
- $ips[$pienumber]="$Lang::tr{'otherip'}";
- $numb[$pienumber] = $numothers;
- }
+ my $numothers;
+ for($o=0;$o<$pienumber;$o++){
+ $numothers = $numothers + $numb[$o];
+ }
+ $numothers = $linesjc - $numothers;
+ if ($numothers > 0) {
+ $ips[$pienumber]="$Lang::tr{'otherip'}";
+ $numb[$pienumber] = $numothers;
+ }
}
my @data = (\@ips,\@numb);
&General::readhash("/srv/web/ipfire/html/themes/".$mainsettings{'THEME'}."/include/colors.txt", \%color);
if ($showpie != 2 && $pienumber <= 50 && $pienumber != 0) {
- my $mygraph = GD::Graph::pie->new(500, 350);
- $mygraph->set(
- 'title' => '',
- 'pie_height' => 50,
- 'start_angle' => 89
- ) or warn $mygraph->error;
-
- $mygraph->set_value_font(GD::gdMediumBoldFont);
- $mygraph->set( dclrs => [ "$color{'color1'}" , "$color{'color2'}" , "$color{'color3'}" , "$color{'color4'}" , "$color{'color5'}" , "$color{'color6'}" , "$color{'color7'}" , "$color{'color8'}" , "$color{'color9'}" , "$color{'color10'}" ] );
- my $myimage = $mygraph->plot(\@data) or die $mygraph->error;
-
- my @filenames = glob("/srv/web/ipfire/html/graphs/fwlog-ip*.png");
- unlink(@filenames);
- my $imagerandom = rand(1000000);
- my $imagename = "/srv/web/ipfire/html/graphs/fwlog-ip$imagerandom.png";
- open(FILE,">$imagename");
- print FILE $myimage->png;
- close(FILE);
- #####################################################
- print "<div style='text-align:center'>";
- print "<img src='/graphs/fwlog-ip$imagerandom.png'>";
- print "</div>";
+ my $mygraph = GD::Graph::pie->new(500, 350);
+ $mygraph->set(
+ 'title' => '',
+ 'pie_height' => 50,
+ 'start_angle' => 89
+ ) or warn $mygraph->error;
+
+ $mygraph->set_value_font(GD::gdMediumBoldFont);
+ $mygraph->set( dclrs => [ "$color{'color1'}" , "$color{'color2'}" , "$color{'color3'}" , "$color{'color4'}" , "$color{'color5'}" , "$color{'color6'}" , "$color{'color7'}" , "$color{'color8'}" , "$color{'color9'}" , "$color{'color10'}" ] );
+ my $myimage = $mygraph->plot(\@data) or die $mygraph->error;
+
+ my @filenames = glob("/srv/web/ipfire/html/graphs/fwlog-ip*.png");
+ unlink(@filenames);
+ my $imagerandom = rand(1000000);
+ my $imagename = "/srv/web/ipfire/html/graphs/fwlog-ip$imagerandom.png";
+ open(FILE,">$imagename");
+ print FILE $myimage->png;
+ close(FILE);
+ #####################################################
+ print "<div style='text-align:center'>";
+ print "<img src='/graphs/fwlog-ip$imagerandom.png'>";
+ print "</div>";
}
print <<END
for($s=0;$s<$lines;$s++)
{
- $show++;
- $percent = $value[$s] * 100 / $linesjc;
- $percent = sprintf("%.f", $percent);
- $total = $total + $value[$s];
- my $colorIndex = $color % 10;
- if($colorIndex == 0) {
- $colorIndex = 10;
- }
- $col="bgcolor='$color{\"color$colorIndex\"}'";
- print "<tr>";
+ $show++;
+ $percent = $value[$s] * 100 / $linesjc;
+ $percent = sprintf("%.f", $percent);
+ $total = $total + $value[$s];
+ # colors are numbered 1 to 10
+ my $colorIndex = ($color % 10) + 1;
+ $col="bgcolor='$color{\"color$colorIndex\"}'";
+ print "<tr>";
+
+ my $gi = Geo::IP::PurePerl->new();
+ my $ccode = $gi->country_code_by_name($key[$s]);
+ my $fcode = lc($ccode);
- my $gi = Geo::IP::PurePerl->new();
- my $ccode = $gi->country_code_by_name($key[$s]);
- my $fcode = lc($ccode);
-
- $color++;
- print "<td align='center' $col><form method='post' action='showrequestfromip.dat'><input type='hidden' name='MONTH' value='$cgiparams{'MONTH'}'> <input type='hidden' name='DAY' value='$cgiparams{'DAY'}'> <input type='hidden' name='ip' value='$key[$s]'> <input type='submit' value='$Lang::tr{'details'}'></form></td>";
- print "<td align='center' $col><a href='/cgi-bin/ipinfo.cgi?ip=$key[$s]'>$key[$s]</a></td>";
-
- # Get flag icon for of the country.
- my $flag_icon = &GeoIP::get_flag_icon($ccode);
-
- if ( $flag_icon ) {
- print "<td align='center' $col><a href='/cgi-bin/country.cgi#$fcode'><img src='$flag_icon' border='0' align='absmiddle' alt='$ccode' title='$ccode'></a></td>";
- } else {
- print "<td align='center' $col></td>";
- }
-
- print "<td align='center' $col>$value[$s]</td>";
- print "<td align='center' $col>$percent</td>";
- print "</tr>";
- }
+ $color++;
+ print "<td align='center' $col><form method='post' action='showrequestfromip.dat'><input type='hidden' name='MONTH' value='$cgiparams{'MONTH'}'> <input type='hidden' name='DAY' value='$cgiparams{'DAY'}'> <input type='hidden' name='ip' value='$key[$s]'> <input type='submit' value='$Lang::tr{'details'}'></form></td>";
+ print "<td align='center' $col><a href='/cgi-bin/ipinfo.cgi?ip=$key[$s]'>$key[$s]</a></td>";
+
+ # Get flag icon for of the country.
+ my $flag_icon = &GeoIP::get_flag_icon($ccode);
+
+ if ( $flag_icon ) {
+ print "<td align='center' $col><a href='/cgi-bin/country.cgi#$fcode'><img src='$flag_icon' border='0' align='absmiddle' alt='$ccode' title='$ccode'></a></td>";
+ } else {
+ print "<td align='center' $col></td>";
+ }
+
+ print "<td align='center' $col>$value[$s]</td>";
+ print "<td align='center' $col>$percent</td>";
+ print "</tr>";
+}
if($cgiparams{'otherspie'} == 2 ){}
else{
- my $colorIndex = $color % 10;
- if($colorIndex == 0) {
- $colorIndex = 10;
- }
- $col="bgcolor='$color{\"color$colorIndex\"}'";
- print "<tr>";
-
-if ( $linesjc ne "0")
-{
-my $dif;
-$dif = $linesjc - $total;
-$percent = $dif * 100 / $linesjc;
-$percent = sprintf("%.f", $percent);
-print <<END
-<td align='center' $col></td>
-<td align='center' $col>$Lang::tr{'otherip'}</td>
-<td align='center' $col></td>
-<td align='center' $col>$dif</td>
-<td align='center' $col>$percent</td>
-</tr>
+ # colors are numbered 1 to 10
+ my $colorIndex = ($color % 10) + 1;
+ $col="bgcolor='$color{\"color$colorIndex\"}'";
+ print "<tr>";
+
+ if ( $linesjc ne "0")
+ {
+ my $dif;
+ $dif = $linesjc - $total;
+ $percent = $dif * 100 / $linesjc;
+ $percent = sprintf("%.f", $percent);
+ print <<END
+ <td align='center' $col></td>
+ <td align='center' $col>$Lang::tr{'otherip'}</td>
+ <td align='center' $col></td>
+ <td align='center' $col>$dif</td>
+ <td align='center' $col>$percent</td>
+ </tr>
END
-;
-}
+ ;
+ }
}
print <<END
</table>
&Header::closepage();
sub findkey {
- my $v;
- foreach $v (@keytabjc) {
- if ($tabjc{$v} eq $_[0]) {
- delete $tabjc{$v};
- $key[$indice] = "$v";
- $value[$indice] = $_[0];
- $indice++;
- last;
- }
- }
+ my $v;
+ foreach $v (@keytabjc) {
+ if ($tabjc{$v} eq $_[0]) {
+ delete $tabjc{$v};
+ $key[$indice] = "$v";
+ $value[$indice] = $_[0];
+ $indice++;
+ last;
+ }
+ }
}
sub checkversion {
- #Automatic Updates is disabled
- return "0","0";
+ #Automatic Updates is disabled
+ return "0","0";
}
# page inspired from the initial firewalllog.dat
#
# Modified for IPFire by Christian Schmidt
-# and Michael Tremer (www.ipfire.org)
+# and Michael Tremer (www.ipfire.org)
use strict;
$cgiparams{'sortcolumn'} = 1;
my @shortmonths = ( 'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug',
- 'Sep', 'Oct', 'Nov', 'Dec' );
+ 'Sep', 'Oct', 'Nov', 'Dec' );
my @longmonths = ( $Lang::tr{'january'}, $Lang::tr{'february'}, $Lang::tr{'march'},
- $Lang::tr{'april'}, $Lang::tr{'may'}, $Lang::tr{'june'}, $Lang::tr{'july'}, $Lang::tr{'august'},
- $Lang::tr{'september'}, $Lang::tr{'october'}, $Lang::tr{'november'},
- $Lang::tr{'december'} );
+ $Lang::tr{'april'}, $Lang::tr{'may'}, $Lang::tr{'june'}, $Lang::tr{'july'}, $Lang::tr{'august'},
+ $Lang::tr{'september'}, $Lang::tr{'october'}, $Lang::tr{'november'},
+ $Lang::tr{'december'} );
my @now = localtime();
my $dow = $now[6];
if ($cgiparams{'ACTION'} eq $Lang::tr{'save'})
{
- &General::writehash("${General::swroot}/fwlogs/portsettings", \%settings);
+ &General::writehash("${General::swroot}/fwlogs/portsettings", \%settings);
}
my $start = -1;
if ($ENV{'QUERY_STRING'} && $cgiparams{'ACTION'} ne $Lang::tr{'update'})
{
- my @temp = split(',',$ENV{'QUERY_STRING'});
- $start = $temp[0];
- $cgiparams{'MONTH'} = $temp[1];
- $cgiparams{'DAY'} = $temp[2];
+ my @temp = split(',',$ENV{'QUERY_STRING'});
+ $start = $temp[0];
+ $cgiparams{'MONTH'} = $temp[1];
+ $cgiparams{'DAY'} = $temp[2];
}
if (!($cgiparams{'MONTH'} =~ /^(0|1|2|3|4|5|6|7|8|9|10|11)$/) ||
!($cgiparams{'DAY'} =~ /^(1|2|3|4|5|6|7|8|9|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|26|27|28|29|30|31)$/))
{
- $cgiparams{'DAY'} = $now[3];
- $cgiparams{'MONTH'} = $now[4];
+ $cgiparams{'DAY'} = $now[3];
+ $cgiparams{'MONTH'} = $now[4];
}
elsif($cgiparams{'ACTION'} eq '>>')
{
- my @temp_then=();
- my @temp_now = localtime(time);
- $temp_now[4] = $cgiparams{'MONTH'};
- $temp_now[3] = $cgiparams{'DAY'};
- @temp_then = localtime(POSIX::mktime(@temp_now) + 86400);
- ## Retrieve the same time on the next day -
- ## 86400 seconds in a day
- $cgiparams{'MONTH'} = $temp_then[4];
- $cgiparams{'DAY'} = $temp_then[3];
+ my @temp_then=();
+ my @temp_now = localtime(time);
+ $temp_now[4] = $cgiparams{'MONTH'};
+ $temp_now[3] = $cgiparams{'DAY'};
+ @temp_then = localtime(POSIX::mktime(@temp_now) + 86400);
+ ## Retrieve the same time on the next day -
+ ## 86400 seconds in a day
+ $cgiparams{'MONTH'} = $temp_then[4];
+ $cgiparams{'DAY'} = $temp_then[3];
}
elsif($cgiparams{'ACTION'} eq '<<')
{
- my @temp_then=();
- my @temp_now = localtime(time);
- $temp_now[4] = $cgiparams{'MONTH'};
- $temp_now[3] = $cgiparams{'DAY'};
- @temp_then = localtime(POSIX::mktime(@temp_now) - 86400);
- ## Retrieve the same time on the previous day -
- ## 86400 seconds in a day
- $cgiparams{'MONTH'} = $temp_then[4];
- $cgiparams{'DAY'} = $temp_then[3];
+ my @temp_then=();
+ my @temp_now = localtime(time);
+ $temp_now[4] = $cgiparams{'MONTH'};
+ $temp_now[3] = $cgiparams{'DAY'};
+ @temp_then = localtime(POSIX::mktime(@temp_now) - 86400);
+ ## Retrieve the same time on the previous day -
+ ## 86400 seconds in a day
+ $cgiparams{'MONTH'} = $temp_then[4];
+ $cgiparams{'DAY'} = $temp_then[3];
}
if (($cgiparams{'DAY'} ne $now[3]) || ($cgiparams{'MONTH'} ne $now[4]))
{
- my @then = ();
- if ( ( $cgiparams{'MONTH'} eq $now[4]) && ($cgiparams{'DAY'} > $now[3]) ||
- ( $cgiparams{'MONTH'} > $now[4] ) ) {
- @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1901 ));
- } else {
- @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1900 ));
- }
- $tdoy = $then[7];
- my $lastleap=($year-1)%4;
- if ($tdoy>$doy) {
- if ($lastleap == 0 && $tdoy < 60) {
- $doy=$tdoy+366;
- } else {
- $doy=$doy+365;
- }
- }
+ my @then = ();
+ if ( ( $cgiparams{'MONTH'} eq $now[4]) && ($cgiparams{'DAY'} > $now[3]) ||
+ ( $cgiparams{'MONTH'} > $now[4] ) ) {
+ @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1901 ));
+ } else {
+ @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1900 ));
+ }
+ $tdoy = $then[7];
+ my $lastleap=($year-1)%4;
+ if ($tdoy>$doy) {
+ if ($lastleap == 0 && $tdoy < 60) {
+ $doy=$tdoy+366;
+ } else {
+ $doy=$doy+365;
+ }
+ }
}
my $datediff=0;
my $dowd=0;
my $multifile=0;
if ($tdoy ne $doy) {
- $datediff=int(($doy-$tdoy)/7);
- $dowd=($doy-$tdoy)%7;
- if (($dow-$dowd)<1) {
- $datediff=$datediff+1;
- }
- if (($dow-$dowd)==0) {
- $multifile=1;
- }
+ $datediff=int(($doy-$tdoy)/7);
+ $dowd=($doy-$tdoy)%7;
+ if (($dow-$dowd)<1) {
+ $datediff=$datediff+1;
+ }
+ if (($dow-$dowd)==0) {
+ $multifile=1;
+ }
}
my $monthstr = $shortmonths[$cgiparams{'MONTH'}];
my $day = $cgiparams{'DAY'};
my $daystr='';
if ($day <= 9) {
- $daystr = " $day"; }
+ $daystr = " $day"; }
else {
- $daystr = $day;
+ $daystr = $day;
}
my $skip=0;
my $filestr='';
if ($datediff==0) {
- $filestr="/var/log/messages";
+ $filestr="/var/log/messages";
} else {
- $filestr="/var/log/messages.$datediff";
- $filestr = "$filestr.gz" if -f "$filestr.gz";
+ $filestr="/var/log/messages.$datediff";
+ $filestr = "$filestr.gz" if -f "$filestr.gz";
}
if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
- $errormessage = "$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
- $skip=1;
- # Note: This is in case the log does not exist for that date
+ $errormessage = "$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
+ $skip=1;
+ # Note: This is in case the log does not exist for that date
}
my $lines = 0;
my @log=();
if (!$skip)
{
- while (<FILE>)
- {
- if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
- $log[$lines] = $_;
- $lines++;
- }
- }
- close (FILE);
+ while (<FILE>)
+ {
+ if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
+ $log[$lines] = $_;
+ $lines++;
+ }
+ }
+ close (FILE);
}
$skip=0;
if ($multifile) {
- $datediff=$datediff-1;
- if ($datediff==0) {
- $filestr="/var/log/messages";
- } else {
- $filestr="/var/log/messages.$datediff";
- $filestr = "$filestr.gz" if -f "$filestr.gz";
- }
- if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
- $errormessage="$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
- $skip=1;
- }
- if (!$skip) {
- while (<FILE>) {
- if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
- $log[$lines] = $_;
- $lines++;
- }
- }
- close (FILE);
- }
+ $datediff=$datediff-1;
+ if ($datediff==0) {
+ $filestr="/var/log/messages";
+ } else {
+ $filestr="/var/log/messages.$datediff";
+ $filestr = "$filestr.gz" if -f "$filestr.gz";
+ }
+ if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
+ $errormessage="$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
+ $skip=1;
+ }
+ if (!$skip) {
+ while (<FILE>) {
+ if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
+ $log[$lines] = $_;
+ $lines++;
+ }
+ }
+ close (FILE);
+ }
}
my $MODNAME="fwlogs";
&Header::openbigbox('100%', 'left', '', $errormessage);
if ($errormessage) {
- &Header::openbox('100%', 'left', $Lang::tr{'error messages'});
- print "<font class='base'>$errormessage </font>\n";
- &Header::closebox();
+ &Header::openbox('100%', 'left', $Lang::tr{'error messages'});
+ print "<font class='base'>$errormessage </font>\n";
+ &Header::closebox();
}
&Header::openbox('100%', 'left', "$Lang::tr{'settings'}");
<form method='post' action='$ENV{'SCRIPT_NAME'}'>
<table width='100%'>
<tr>
- <td width='10%' class='base'>$Lang::tr{'month'}: </td>
- <td width='10%'>
- <select name='MONTH'>
+ <td width='10%' class='base'>$Lang::tr{'month'}: </td>
+ <td width='10%'>
+ <select name='MONTH'>
END
;
my $month;
for ($month = 0; $month < 12; $month++)
{
- print "\t<option ";
- if ($month == $cgiparams{'MONTH'}) {
- print "selected='selected' "; }
- print "value='$month'>$longmonths[$month]</option>\n";
+ print "\t<option ";
+ if ($month == $cgiparams{'MONTH'}) {
+ print "selected='selected' "; }
+ print "value='$month'>$longmonths[$month]</option>\n";
}
print <<END
- </select>
- </td>
- <td width='10%' class='base' align='right'> $Lang::tr{'day'}: </td>
- <td width='40%'>
- <select name='DAY'>
+ </select>
+ </td>
+ <td width='10%' class='base' align='right'> $Lang::tr{'day'}: </td>
+ <td width='40%'>
+ <select name='DAY'>
END
;
for ($day = 1; $day <= 31; $day++)
{
- print "\t<option ";
- if ($day == $cgiparams{'DAY'}) {
- print "selected='selected' "; }
- print "value='$day'>$day</option>\n";
+ print "\t<option ";
+ if ($day == $cgiparams{'DAY'}) {
+ print "selected='selected' "; }
+ print "value='$day'>$day</option>\n";
}
if( $cgiparams{'pienumber'} != 0){$pienumber=$cgiparams{'pienumber'};}
$lines = 0;
foreach $_ (@log)
{
- if($_ =~ /DPT\=([\d\.]+)/){
- $tabjc{$1} = $tabjc{$1} + 1 ;
- if(($tabjc{$1} == 1) && ($lines < $pienumber)) { $lines = $lines + 1; }
- $linesjc++;
- }
+ if($_ =~ /DPT\=([\d\.]+)/){
+ $tabjc{$1} = $tabjc{$1} + 1 ;
+ if(($tabjc{$1} == 1) && ($lines < $pienumber)) { $lines = $lines + 1; }
+ $linesjc++;
+ }
}
$pienumber = $lines;
if ($sortcolumn == 1)
{
- @tabjc2 = sort { $b <=> $a } values (%tabjc);
+ @tabjc2 = sort { $b <=> $a } values (%tabjc);
}
else
{
- @tabjc2 = sort { $a <=> $b } keys (%tabjc);
+ @tabjc2 = sort { $a <=> $b } keys (%tabjc);
}
my $color=10;
if ($sortcolumn == 1)
{
- for ($v=0;$v<$pienumber;$v++){
- findkey($tabjc2[$v]);
- }
+ for ($v=0;$v<$pienumber;$v++){
+ findkey($tabjc2[$v]);
+ }
}
else
{
- foreach $v (@tabjc2) {
- $key[$indice] = $v;
- $value[$indice] = $tabjc{$v};
- $indice++;
- }
+ foreach $v (@tabjc2) {
+ $key[$indice] = $v;
+ $value[$indice] = $tabjc{$v};
+ $indice++;
+ }
}
my @ports;
if($cgiparams{'otherspie'} == 2 ){}
else{
- my $numothers;
- for($o=0;$o<$pienumber;$o++){
- $numothers = $numothers + $numb[$o];
- }
- $numothers = $linesjc - $numothers;
- if ($numothers > 0) {
- $ports[$pienumber]="$Lang::tr{'otherport'}";
- $numb[$pienumber] = $numothers;
- }
+ my $numothers;
+ for($o=0;$o<$pienumber;$o++){
+ $numothers = $numothers + $numb[$o];
+ }
+ $numothers = $linesjc - $numothers;
+ if ($numothers > 0) {
+ $ports[$pienumber]="$Lang::tr{'otherport'}";
+ $numb[$pienumber] = $numothers;
+ }
}
my @data = (\@ports,\@numb);
&General::readhash("/srv/web/ipfire/html/themes/".$mainsettings{'THEME'}."/include/colors.txt", \%color);
if ($showpie != 2 && $pienumber <= 50 && $pienumber != 0) {
- my $mygraph = GD::Graph::pie->new(500, 350);
- $mygraph->set(
- 'title' => '',
- 'pie_height' => 50,
- 'start_angle' => 89
- ) or warn $mygraph->error;
-
- $mygraph->set_value_font(GD::gdMediumBoldFont);
- $mygraph->set( dclrs => [ "$color{'color1'}" , "$color{'color2'}" , "$color{'color3'}" , "$color{'color4'}" , "$color{'color5'}" , "$color{'color6'}" , "$color{'color7'}" , "$color{'color8'}" , "$color{'color9'}" , "$color{'color10'}" ] );
- my $myimage = $mygraph->plot(\@data) or die $mygraph->error;
-
- my @filenames = glob("/srv/web/ipfire/html/graphs/fwlog-port*.png");
- unlink(@filenames);
- my $imagerandom = rand(1000000);
- my $imagename = "/srv/web/ipfire/html/graphs/fwlog-port$imagerandom.png";
- open(FILE,">$imagename");
- print FILE $myimage->png;
- close(FILE);
- #####################################################
- print "<div style='text-align:center'>";
- print "<img src='/graphs/fwlog-port$imagerandom.png'>";
- print "</div>";
+ my $mygraph = GD::Graph::pie->new(500, 350);
+ $mygraph->set(
+ 'title' => '',
+ 'pie_height' => 50,
+ 'start_angle' => 89
+ ) or warn $mygraph->error;
+
+ $mygraph->set_value_font(GD::gdMediumBoldFont);
+ $mygraph->set( dclrs => [ "$color{'color1'}" , "$color{'color2'}" , "$color{'color3'}" , "$color{'color4'}" , "$color{'color5'}" , "$color{'color6'}" , "$color{'color7'}" , "$color{'color8'}" , "$color{'color9'}" , "$color{'color10'}" ] );
+ my $myimage = $mygraph->plot(\@data) or die $mygraph->error;
+
+ my @filenames = glob("/srv/web/ipfire/html/graphs/fwlog-port*.png");
+ unlink(@filenames);
+ my $imagerandom = rand(1000000);
+ my $imagename = "/srv/web/ipfire/html/graphs/fwlog-port$imagerandom.png";
+ open(FILE,">$imagename");
+ print FILE $myimage->png;
+ close(FILE);
+ #####################################################
+ print "<div style='text-align:center'>";
+ print "<img src='/graphs/fwlog-port$imagerandom.png'>";
+ print "</div>";
}
print <<END
for($s=0;$s<$lines;$s++)
{
- $show++;
- $percent = $value[$s] * 100 / $linesjc;
- $percent = sprintf("%.f", $percent);
- $total = $total + $value[$s];
- my $colorIndex = $color % 10;
- if($colorIndex == 0) {
- $colorIndex = 10;
- }
- $col="bgcolor='$color{\"color$colorIndex\"}'";
- print "<tr>";
-
- $color++;
- print "<td align='center' $col><form method='post' action='showrequestfromport.dat'><input type='hidden' name='MONTH' value='$cgiparams{'MONTH'}'> <input type='hidden' name='DAY' value='$cgiparams{'DAY'}'> <input type='hidden' name='port' value='$key[$s]'> <input type='submit' value='$Lang::tr{'details'}'></form></td>";
- print "<td align='center' $col>$key[$s]</td>";
- print "<td align='center' $col>$value[$s]</td>";
- print "<td align='center' $col>$percent</td>";
- print "</tr>";
+ $show++;
+ $percent = $value[$s] * 100 / $linesjc;
+ $percent = sprintf("%.f", $percent);
+ $total = $total + $value[$s];
+ # colors are numbered 1 to 10
+ my $colorIndex = ($color % 10) + 1;
+ $col="bgcolor='$color{\"color$colorIndex\"}'";
+ print "<tr>";
+
+ $color++;
+ print "<td align='center' $col><form method='post' action='showrequestfromport.dat'><input type='hidden' name='MONTH' value='$cgiparams{'MONTH'}'> <input type='hidden' name='DAY' value='$cgiparams{'DAY'}'> <input type='hidden' name='port' value='$key[$s]'> <input type='submit' value='$Lang::tr{'details'}'></form></td>";
+ print "<td align='center' $col>$key[$s]</td>";
+ print "<td align='center' $col>$value[$s]</td>";
+ print "<td align='center' $col>$percent</td>";
+ print "</tr>";
}
if($cgiparams{'otherspie'} == 2 ){}
else{
- my $colorIndex = $color % 10;
- if($colorIndex == 0) {
- $colorIndex = 10;
- }
- $col="bgcolor='$color{\"color$colorIndex\"}'";
- print "<tr>";
-
-if ( $linesjc ne "0")
-{
-my $dif;
-$dif = $linesjc - $total;
-$percent = $dif * 100 / $linesjc;
-$percent = sprintf("%.f", $percent);
-print <<END
-<td align='center' $col></td>
-<td align='center' $col>$Lang::tr{'otherport'}</td>
-<td align='center' $col>$dif</td>
-<td align='center' $col>$percent</td>
-</tr>
+ # colors are numbered 1 to 10
+ my $colorIndex = ($color % 10) + 1;
+ $col="bgcolor='$color{\"color$colorIndex\"}'";
+ print "<tr>";
+
+ if ( $linesjc ne "0") {
+ my $dif;
+ $dif = $linesjc - $total;
+ $percent = $dif * 100 / $linesjc;
+ $percent = sprintf("%.f", $percent);
+ print <<END
+ <td align='center' $col></td>
+ <td align='center' $col>$Lang::tr{'otherport'}</td>
+ <td align='center' $col>$dif</td>
+ <td align='center' $col>$percent</td>
+ </tr>
END
-;
-}
+ ;
+ }
}
print <<END
</table>
&Header::closepage();
sub findkey {
- my $v;
- foreach $v (@keytabjc) {
- if ($tabjc{$v} eq $_[0]) {
- delete $tabjc{$v};
- $key[$indice] = "$v";
- $value[$indice] = $_[0];
- $indice++;
- last;
- }
- }
+ my $v;
+ foreach $v (@keytabjc) {
+ if ($tabjc{$v} eq $_[0]) {
+ delete $tabjc{$v};
+ $key[$indice] = "$v";
+ $value[$indice] = $_[0];
+ $indice++;
+ last;
+ }
+ }
}
sub checkversion {
- #Automatic Updates is disabled
- return "0","0";
+ #Automatic Updates is disabled
+ return "0","0";
}
}
elsif($cgiparams{'ACTION'} eq '>>')
{
- my @temp_then=();
- my @temp_now = localtime(time);
- $temp_now[4] = $cgiparams{'MONTH'};
- $temp_now[3] = $cgiparams{'DAY'};
- @temp_then = localtime(POSIX::mktime(@temp_now) + 86400);
- ## Retrieve the same time on the next day -
- ## 86400 seconds in a day
- $cgiparams{'MONTH'} = $temp_then[4];
- $cgiparams{'DAY'} = $temp_then[3];
+ my @temp_then=();
+ my @temp_now = localtime(time);
+ $temp_now[4] = $cgiparams{'MONTH'};
+ $temp_now[3] = $cgiparams{'DAY'};
+ @temp_then = localtime(POSIX::mktime(@temp_now) + 86400);
+ ## Retrieve the same time on the next day -
+ ## 86400 seconds in a day
+ $cgiparams{'MONTH'} = $temp_then[4];
+ $cgiparams{'DAY'} = $temp_then[3];
}
elsif($cgiparams{'ACTION'} eq '<<')
{
- my @temp_then=();
- my @temp_now = localtime(time);
- $temp_now[4] = $cgiparams{'MONTH'};
- $temp_now[3] = $cgiparams{'DAY'};
- @temp_then = localtime(POSIX::mktime(@temp_now) - 86400);
- ## Retrieve the same time on the previous day -
- ## 86400 seconds in a day
- $cgiparams{'MONTH'} = $temp_then[4];
- $cgiparams{'DAY'} = $temp_then[3];
+ my @temp_then=();
+ my @temp_now = localtime(time);
+ $temp_now[4] = $cgiparams{'MONTH'};
+ $temp_now[3] = $cgiparams{'DAY'};
+ @temp_then = localtime(POSIX::mktime(@temp_now) - 86400);
+ ## Retrieve the same time on the previous day -
+ ## 86400 seconds in a day
+ $cgiparams{'MONTH'} = $temp_then[4];
+ $cgiparams{'DAY'} = $temp_then[3];
}
if (($cgiparams{'DAY'} ne $now[3]) || ($cgiparams{'MONTH'} ne $now[4]))
{
- my @then = ();
- if ( ( $cgiparams{'MONTH'} eq $now[4]) && ($cgiparams{'DAY'} > $now[3]) ||
- ( $cgiparams{'MONTH'} > $now[4] ) ) {
- @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1901 ));
- } else {
- @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1900 ));
- }
- $tdoy = $then[7];
- my $lastleap=($year-1)%4;
- if ($tdoy>$doy) {
- if ($lastleap == 0 && $tdoy < 60) {
- $doy=$tdoy+366;
- } else {
- $doy=$doy+365;
- }
- }
+ my @then = ();
+ if ( ( $cgiparams{'MONTH'} eq $now[4]) && ($cgiparams{'DAY'} > $now[3]) ||
+ ( $cgiparams{'MONTH'} > $now[4] ) ) {
+ @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1901 ));
+ } else {
+ @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1900 ));
+ }
+ $tdoy = $then[7];
+ my $lastleap=($year-1)%4;
+ if ($tdoy>$doy) {
+ if ($lastleap == 0 && $tdoy < 60) {
+ $doy=$tdoy+366;
+ } else {
+ $doy=$doy+365;
+ }
+ }
}
my $datediff=0;
my $dowd=0;
my $multifile=0;
if ($tdoy ne $doy) {
- $datediff=int(($doy-$tdoy)/7);
- $dowd=($doy-$tdoy)%7;
- if (($dow-$dowd)<1) {
- $datediff=$datediff+1;
- }
- if (($dow-$dowd)==0) {
- $multifile=1;
- }
+ $datediff=int(($doy-$tdoy)/7);
+ $dowd=($doy-$tdoy)%7;
+ if (($dow-$dowd)<1) {
+ $datediff=$datediff+1;
+ }
+ if (($dow-$dowd)==0) {
+ $multifile=1;
+ }
}
my $monthstr = $shortmonths[$cgiparams{'MONTH'}];
my $skip=0;
my $filestr='';
if ($datediff==0) {
- $filestr="/var/log/messages";
+ $filestr="/var/log/messages";
} else {
- $filestr="/var/log/messages.$datediff";
- $filestr = "$filestr.gz" if -f "$filestr.gz";
+ $filestr="/var/log/messages.$datediff";
+ $filestr = "$filestr.gz" if -f "$filestr.gz";
}
if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
- $errormessage = "$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
- $skip=1;
- # Note: This is in case the log does not exist for that date
+ $errormessage = "$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
+ $skip=1;
+ # Note: This is in case the log does not exist for that date
}
my $lines = 0;
my @log=();
if (!$skip)
{
- while (<FILE>)
- {
- if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
- my $packet = $2;
- $packet =~ /IN=(\w+)/; my $iface=$1; if ( $1 =~ /2./ ){ $iface="";}
- $packet =~ /SRC=([\d\.]+)/; my $srcaddr=$1;
-
- if($iface eq $country) {
- $log[$lines] = $_;
- $lines++;
- }
- elsif($srcaddr ne '') {
- my $ccode = $gi->country_code_by_name($srcaddr);
- if($ccode eq $country){
- $log[$lines] = $_;
- $lines++;
- }
- }
+ while (<FILE>) {
+ # First check whether valid log line (date, day)
+ if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
+ # If ipv6 uses bridge, then use PHYSIN otherwise use IN
+ if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(PHYSIN=.*)$/) {}
+ elsif (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {}
+ my $packet = $2;
+ my $iface = '';
+ my $srcaddr = '';
+ # If ipv6 uses bridge, use PHYSIN otherwise IN
+ if ($packet =~ /PHYSIN=(\w+)/) { $iface = $1; } elsif ($packet =~ /IN=(\w+)/) { $iface = $1; }
+ # Extract ipv4 and ipv6 addresses
+ if (($packet =~ /SRC\=(([\d]{1,3})(\.([\d]{1,3})){3})/) or ($packet =~ /SRC\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/)) {
+ $srcaddr = $1;
+ }
+
+ if($iface eq $country) {
+ # iface matches country code
+ $log[$lines] = $_;
+ $lines++;
+ }
+ elsif($srcaddr ne '') {
+ # or srcaddr matches country code
+ my $ccode = $gi->country_code_by_name($srcaddr);
+ if($ccode eq uc($country)){
+ $log[$lines] = $_;
+ $lines++;
+ }
+ }
}
}
close (FILE);
$skip=0;
if ($multifile) {
- $datediff=$datediff-1;
- if ($datediff==0) {
- $filestr="/var/log/messages";
- } else {
- $filestr="/var/log/messages.$datediff";
- $filestr = "$filestr.gz" if -f "$filestr.gz";
- }
- if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
- $errormessage="$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
- $skip=1;
- }
- if (!$skip) {
+ $datediff=$datediff-1;
+ if ($datediff==0) {
+ $filestr="/var/log/messages";
+ } else {
+ $filestr="/var/log/messages.$datediff";
+ $filestr = "$filestr.gz" if -f "$filestr.gz";
+ }
+ if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
+ $errormessage="$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
+ $skip=1;
+ }
+ if (!$skip) {
while (<FILE>) {
- if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
- if($_ =~ /SRC\=([\d\.]+)/){
- my $srcaddr=$1;
- my $ccode = $gi->country_code_by_name($srcaddr);
- if($ccode eq $country){
- $log[$lines] = $_;
- $lines++;
- }
- }
+ # Check if valid log line (date, day)
+ if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
+ my $iface = '';
+ # If ipv6 uses bridge, then use PHYSIN otherwise IN
+ if ($_ =~ /PHYSIN=(\w+)/) { $iface = $1; } elsif ($_ =~ /IN=(\w+)/) { $iface = $1; }
+
+ if($iface eq $country) {
+ # iface matches country code
+ $log[$lines] = $_;
+ $lines++;
+ }
+ # extract ipv4 and ipv6 address
+ elsif (($_ =~ /SRC\=(([\d]{1,3})(\.([\d]{1,3})){3})/) or ($_ =~ /SRC\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/)) {
+ my $srcaddr=$1;
+ my $ccode = $gi->country_code_by_name($srcaddr);
+ if($ccode eq uc($country)){
+ # or srcaddr matches country code
+ $log[$lines] = $_;
+ $lines++;
+ }
+ }
}
}
close (FILE);
{
print "\t<option ";
if ($month == $cgiparams{'MONTH'}) {
- print "selected='selected' "; }
+ print "selected='selected' ";
+ }
print "value='$month'>$longmonths[$month]</option>\n";
}
print <<END
print "<p><b>$Lang::tr{'firewall hits'} $longmonthstr $daystr: $lines</b></p>";
if ($start == -1) {
- $start = $lines - ${Header::viewsize}; }
+ $start = $lines - ${Header::viewsize};
+}
if ($start >= $lines - ${Header::viewsize}) { $start = $lines - ${Header::viewsize}; };
if ($start < 0) { $start = 0; }
$lines = 0;
foreach $_ (@slice)
{
- $a = $_;
- /^... (..) (..:..:..) [\w\-]+ kernel:(.*)(IN=.*)$/;
- my $packet = $4;
- $packet =~ /IN=(\w+)/; my $iface=$1; if ( $1 =~ /2./ ){ $iface="";}
- $packet =~ /SRC=([\d\.]+)/; my $srcaddr=$1;
-
- if($iface eq $country || $srcaddr ne '') {
- my $ccode;
- if($iface ne $country) {
- $ccode = $gi->country_code_by_name($srcaddr);
- }
- if($iface eq $country || $ccode eq $country) {
- my $chain = '';
- my $in = '-'; my $out = '-';
- my $srcaddr = ''; my $dstaddr = '';
- my $protostr = '';
- my $srcport = ''; my $dstport = '';
-
- $_ =~ /(^.* ..:..:..) [\w\-]+ kernel:(.*)(IN=.*)$/;
- my $timestamp = $1; my $chain = $2; my $packet = $3;
- $timestamp =~ /(...) (..) (..:..:..)/;
- my $month = $1; my $day = $2; my $time = $3;
-
- if ($a =~ /IN\=(\w+)/) { $iface = $1; }
- if ($a =~ /OUT\=(\w+)/) { $out = $1; }
- if ($a =~ /SRC\=([\d\.]+)/) { $srcaddr = $1; }
- if ($a =~ /DST\=([\d\.]+)/) { $dstaddr = $1; }
- if ($a =~ /PROTO\=(\w+)/) { $protostr = $1; }
- my $protostrlc = lc($protostr);
- if ($a =~ /SPT\=([\d\.]+)/){ $srcport = $1; }
- if ($a =~ /DPT\=([\d\.]+)/){ $dstport = $1; }
-
- if ($lines % 2) {
- print "<tr bgcolor='${Header::table1colour}'>\n"; }
- else {
- print "<tr bgcolor='${Header::table2colour}'>\n"; }
- print <<END
- <td align='center'>$time</td>
- <td align='center'>$chain</td>
- <td align='center'>$iface</td>
- <td align='center'>$protostr</td>
- <td align='center'>
- <table width='100%' cellpadding='0' cellspacing='0'><tr>
- <td align='center'><a href='/cgi-bin/ipinfo.cgi?ip=$srcaddr'>$srcaddr</a></td>
- </tr></table>
- </td>
- <td align='center'>$srcport</td>
- <td align='center'>
- <table width='100%' cellpadding='0' cellspacing='0'><tr>
- <td align='center'><a href='/cgi-bin/ipinfo.cgi?ip=$dstaddr'>$dstaddr</a></td>
- </tr></table>
- </td>
- <td align='center'>$dstport</td>
- </tr>
+ $a = $_;
+ # If ipv6 uses bridge, use PHYSIN otherwise use IN
+ if (/^... (..) (..:..:..) [\w\-]+ kernel:(.*)(PHYSIN=.*)$/) {}
+ elsif (/^... (..) (..:..:..) [\w\-]+ kernel:(.*)(IN=.*)$/) {};
+ my $packet = $4;
+ my $iface = '';
+ # If ipv6 uses bridge, use PHYSIN otherwise use IN
+ if ($packet =~ /PHYSIN=(\w+)/) { $iface = $1; } elsif ($packet =~ /IN=(\w+)/) { $iface = $1; }
+ if ( $1 =~ /2./ ){ $iface=""; }
+ my $srcaddr = '';
+ # Extract ipv4 and ipv6 addresses
+ if (($packet =~ /SRC\=(([\d]{1,3})(\.([\d]{1,3})){3})/) or ($packet =~ /SRC\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/)) {
+ $srcaddr = $1;
+ };
+
+ if($iface eq $country || $srcaddr ne '') {
+ my $ccode='';
+ if($iface ne $country) {
+ $ccode = $gi->country_code_by_name($srcaddr);
+ }
+ if($iface eq $country || $ccode eq uc($country)) {
+ my $chain = '';
+ my $in = '-'; my $out = '-';
+ my $srcaddr = ''; my $dstaddr = '';
+ my $protostr = '';
+ my $srcport = ''; my $dstport = '';
+
+ # If ipv6 uses bridge, the use PHYSIN otherwise use IN
+ if ($_ =~ /(^.* ..:..:..) [\w\-]+ kernel:(.*)(IN=.*)(PHYSIN=.*)$/) {}
+ elsif ($_ =~ /(^.* ..:..:..) [\w\-]+ kernel:(.*)(IN=.*)$/) {}
+ my $timestamp = $1; my $chain = $2; my $packet = $3;
+ $timestamp =~ /(...) (..) (..:..:..)/;
+ my $month = $1; my $day = $2; my $time = $3;
+
+ # If ipv6 uses bridge, use PHYSIN and PHYSOUT, otherwise use IN and OUT
+ if ($a =~ /PHYSIN=(\w+)/) { $iface = $1; } elsif ($a =~ /IN=(\w+)/) { $iface = $1; }
+ if ($a =~ /PHYSOUT=(\w+)/) { $out = $1; } elsif ($a =~ /OUT=(\w+)/) { $out = $1; }
+ # Extract ipv4 and ipv6 addresses
+ if (($a =~ /SRC\=(([\d]{1,3})(\.([\d]{1,3})){3})/) or ($a =~ /SRC\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/)) { $srcaddr = $1; }
+ if (($a =~ /DST\=(([\d]{1,3})(\.([\d]{1,3})){3})/) or ($a =~ /DST\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/)) { $dstaddr = $1; }
+ if ($a =~ /PROTO\=(\w+)/) { $protostr = $1; }
+ my $protostrlc = lc($protostr);
+ if ($a =~ /SPT\=([\d\.]+)/){ $srcport = $1; }
+ if ($a =~ /DPT\=([\d\.]+)/){ $dstport = $1; }
+
+ if ($lines % 2) {
+ print "<tr bgcolor='${Header::table1colour}'>\n";
+ }
+ else {
+ print "<tr bgcolor='${Header::table2colour}'>\n";
+ }
+ print <<END
+ <td align='center'>$time</td>
+ <td align='center'>$chain</td>
+ <td align='center'>$iface</td>
+ <td align='center'>$protostr</td>
+ <td align='center'>
+ <table width='100%' cellpadding='0' cellspacing='0'><tr>
+ <td align='center'><a href='/cgi-bin/ipinfo.cgi?ip=$srcaddr'>$srcaddr</a></td>
+ </tr></table>
+ </td>
+ <td align='center'>$srcport</td>
+ <td align='center'>
+ <table width='100%' cellpadding='0' cellspacing='0'><tr>
+ <td align='center'><a href='/cgi-bin/ipinfo.cgi?ip=$dstaddr'>$dstaddr</a></td>
+ </tr></table>
+ </td>
+ <td align='center'>$dstport</td>
+ </tr>
END
- ;
- $lines++;
- }
- }
+ ;
+ $lines++;
+ }
+ }
}
print <<END
sub oldernewer
{
- print <<END
- <table width='100%'>
- <tr>
+ print <<END
+ <table width='100%'>
+ <tr>
END
-;
+ ;
- print "<td align='center' width='50%'>";
- if ($prev != -1) {
- print "<a href='/cgi-bin/logs.cgi/showrequestfromcountry.dat?$prev,$cgiparams{'MONTH'},$cgiparams{'DAY'},$cgiparams{country}'>$Lang::tr{'older'}</a>"; }
- else {
- print "$Lang::tr{'older'}"; }
- print "</td>\n";
+ print "<td align='center' width='50%'>";
+ if ($prev != -1) {
+ print "<a href='/cgi-bin/logs.cgi/showrequestfromcountry.dat?$prev,$cgiparams{'MONTH'},$cgiparams{'DAY'},$cgiparams{country}'>$Lang::tr{'older'}</a>";
+ }
+ else {
+ print "$Lang::tr{'older'}";
+ }
+ print "</td>\n";
- print "<td align='center' width='50%'>";
- if ($next != -1) {
- print "<a href='/cgi-bin/logs.cgi/showrequestfromcountry.dat?$next,$cgiparams{'MONTH'},$cgiparams{'DAY'},$cgiparams{country}'>$Lang::tr{'newer'}</a>"; }
- else {
- print "$Lang::tr{'newer'}"; }
- print "</td>\n";
+ print "<td align='center' width='50%'>";
+ if ($next != -1) {
+ print "<a href='/cgi-bin/logs.cgi/showrequestfromcountry.dat?$next,$cgiparams{'MONTH'},$cgiparams{'DAY'},$cgiparams{country}'>$Lang::tr{'newer'}</a>";
+ }
+ else {
+ print "$Lang::tr{'newer'}";
+ }
-print <<END
- </tr>
- </table>
+ print "</td>\n";
+ print <<END
+ </tr>
+ </table>
END
-;
+ ;
}
}
elsif($cgiparams{'ACTION'} eq '>>')
{
- my @temp_then=();
- my @temp_now = localtime(time);
- $temp_now[4] = $cgiparams{'MONTH'};
- $temp_now[3] = $cgiparams{'DAY'};
- @temp_then = localtime(POSIX::mktime(@temp_now) + 86400);
- ## Retrieve the same time on the next day -
- ## 86400 seconds in a day
- $cgiparams{'MONTH'} = $temp_then[4];
- $cgiparams{'DAY'} = $temp_then[3];
+ my @temp_then=();
+ my @temp_now = localtime(time);
+ $temp_now[4] = $cgiparams{'MONTH'};
+ $temp_now[3] = $cgiparams{'DAY'};
+ @temp_then = localtime(POSIX::mktime(@temp_now) + 86400);
+ ## Retrieve the same time on the next day -
+ ## 86400 seconds in a day
+ $cgiparams{'MONTH'} = $temp_then[4];
+ $cgiparams{'DAY'} = $temp_then[3];
}
elsif($cgiparams{'ACTION'} eq '<<')
{
- my @temp_then=();
- my @temp_now = localtime(time);
- $temp_now[4] = $cgiparams{'MONTH'};
- $temp_now[3] = $cgiparams{'DAY'};
- @temp_then = localtime(POSIX::mktime(@temp_now) - 86400);
- ## Retrieve the same time on the previous day -
- ## 86400 seconds in a day
- $cgiparams{'MONTH'} = $temp_then[4];
- $cgiparams{'DAY'} = $temp_then[3];
+ my @temp_then=();
+ my @temp_now = localtime(time);
+ $temp_now[4] = $cgiparams{'MONTH'};
+ $temp_now[3] = $cgiparams{'DAY'};
+ @temp_then = localtime(POSIX::mktime(@temp_now) - 86400);
+ ## Retrieve the same time on the previous day -
+ ## 86400 seconds in a day
+ $cgiparams{'MONTH'} = $temp_then[4];
+ $cgiparams{'DAY'} = $temp_then[3];
}
if (($cgiparams{'DAY'} ne $now[3]) || ($cgiparams{'MONTH'} ne $now[4]))
{
- my @then = ();
- if ( ( $cgiparams{'MONTH'} eq $now[4]) && ($cgiparams{'DAY'} > $now[3]) ||
- ( $cgiparams{'MONTH'} > $now[4] ) ) {
- @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1901 ));
- } else {
- @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1900 ));
- }
- $tdoy = $then[7];
- my $lastleap=($year-1)%4;
- if ($tdoy>$doy) {
- if ($lastleap == 0 && $tdoy < 60) {
- $doy=$tdoy+366;
- } else {
- $doy=$doy+365;
- }
- }
+ my @then = ();
+ if ( ( $cgiparams{'MONTH'} eq $now[4]) && ($cgiparams{'DAY'} > $now[3]) ||
+ ( $cgiparams{'MONTH'} > $now[4] ) ) {
+ @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1901 ));
+ } else {
+ @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1900 ));
+ }
+ $tdoy = $then[7];
+ my $lastleap=($year-1)%4;
+ if ($tdoy>$doy) {
+ if ($lastleap == 0 && $tdoy < 60) {
+ $doy=$tdoy+366;
+ } else {
+ $doy=$doy+365;
+ }
+ }
}
my $datediff=0;
my $dowd=0;
my $multifile=0;
if ($tdoy ne $doy) {
- $datediff=int(($doy-$tdoy)/7);
- $dowd=($doy-$tdoy)%7;
- if (($dow-$dowd)<1) {
- $datediff=$datediff+1;
- }
- if (($dow-$dowd)==0) {
- $multifile=1;
- }
+ $datediff=int(($doy-$tdoy)/7);
+ $dowd=($doy-$tdoy)%7;
+ if (($dow-$dowd)<1) {
+ $datediff=$datediff+1;
+ }
+ if (($dow-$dowd)==0) {
+ $multifile=1;
+ }
}
my $monthstr = $shortmonths[$cgiparams{'MONTH'}];
my $skip=0;
my $filestr='';
if ($datediff==0) {
- $filestr="/var/log/messages";
+ $filestr="/var/log/messages";
} else {
$filestr="/var/log/messages.$datediff";
$filestr = "$filestr.gz" if -f "$filestr.gz";
}
if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
- $errormessage = "$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
- $skip=1;
- # Note: This is in case the log does not exist for that date
+ $errormessage = "$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
+ $skip=1;
+ # Note: This is in case the log does not exist for that date
}
my $lines = 0;
my @log=();
if (!$skip)
{
- while (<FILE>)
- {
+ while (<FILE>) {
if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
- if($_ =~ /SRC\=([\d\.]+)/){
- if($1 eq $ip){
- $log[$lines] = $_;
- $lines++;
- }
- }
+ if (($_ =~ /SRC\=(([\d]{1,3})(\.([\d]{1,3})){3})/) or ($_ =~ /SRC\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/)) {
+ if($1 eq $ip){
+ $log[$lines] = $_;
+ $lines++;
+ }
+ }
}
}
close (FILE);
$skip=0;
if ($multifile) {
- $datediff=$datediff-1;
- if ($datediff==0) {
- $filestr="/var/log/messages";
- } else {
- $filestr="/var/log/messages.$datediff";
- $filestr = "$filestr.gz" if -f "$filestr.gz";
- }
- if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
- $errormessage="$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
- $skip=1;
- }
- if (!$skip) {
+ $datediff=$datediff-1;
+ if ($datediff==0) {
+ $filestr="/var/log/messages";
+ } else {
+ $filestr="/var/log/messages.$datediff";
+ $filestr = "$filestr.gz" if -f "$filestr.gz";
+ }
+ if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
+ $errormessage="$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
+ $skip=1;
+ }
+ if (!$skip) {
while (<FILE>) {
- if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
- if($_ =~ /SRC\=([\d\.]+)/){
- if($1 eq $ip){
- $log[$lines] = $_;
- $lines++;
- }
- }
+ if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
+ if (($_ =~ /SRC\=(([\d]{1,3})(\.([\d]{1,3})){3})/) or ($_ =~ /SRC\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/)) {
+ if($1 eq $ip){
+ $log[$lines] = $_;
+ $lines++;
+ }
+ }
}
}
close (FILE);
print "<p><b>$Lang::tr{'firewall hits'} $longmonthstr $daystr: $lines</b></p>";
if ($start == -1) {
- $start = $lines - ${Header::viewsize}; }
+ $start = $lines - ${Header::viewsize};
+}
if ($start >= $lines - ${Header::viewsize}) { $start = $lines - ${Header::viewsize}; };
if ($start < 0) { $start = 0; }
if ($logsettings{'LOGVIEW_REVERSE'} eq 'on') { @slice = reverse @slice; }
$lines = 0;
-foreach $_ (@slice)
-{
- $a = $_;
- if($_ =~ /SRC\=([\d\.]+)/){
- if($1 eq $ip){
- my $chain = '';
- my $in = '-'; my $out = '-';
- my $srcaddr = ''; my $dstaddr = '';
- my $protostr = '';
- my $srcport = ''; my $dstport = '';
-
- $_ =~ /(^.* ..:..:..) [\w\-]+ kernel:(.*)(IN=.*)$/;
- my $timestamp = $1; my $chain = $2; my $packet = $3;
- $timestamp =~ /(...) (..) (..:..:..)/;
- my $month = $1; my $day = $2; my $time = $3;
-
- if ($a =~ /IN\=(\w+)/) { $iface = $1; }
- if ($a =~ /OUT\=(\w+)/) { $out = $1; }
- if ($a =~ /SRC\=([\d\.]+)/) { $srcaddr = $1; }
- if ($a =~ /DST\=([\d\.]+)/) { $dstaddr = $1; }
- if ($a =~ /PROTO\=(\w+)/) { $protostr = $1; }
- my $protostrlc = lc($protostr);
- if ($a =~ /SPT\=([\d\.]+)/){ $srcport = $1; }
- if ($a =~ /DPT\=([\d\.]+)/){ $dstport = $1; }
-
- if ($lines % 2) {
- print "<tr bgcolor='${Header::table1colour}'>\n"; }
- else {
- print "<tr bgcolor='${Header::table2colour}'>\n"; }
- print <<END
- <td align='center'>$time</td>
- <td align='center'>$chain</td>
- <td align='center'>$iface</td>
- <td align='center'>$protostr</td>
- <td align='center'>
- <table width='100%' cellpadding='0' cellspacing='0'><tr>
- <td align='center'><a href='/cgi-bin/ipinfo.cgi?ip=$srcaddr'>$srcaddr</a></td>
- </tr></table>
- </td>
- <td align='center'>$srcport</td>
- <td align='center'>
- <table width='100%' cellpadding='0' cellspacing='0'><tr>
- <td align='center'><a href='/cgi-bin/ipinfo.cgi?ip=$dstaddr'>$dstaddr</a></td>
- </tr></table>
- </td>
- <td align='center'>$dstport</td>
-</tr>
+foreach $_ (@slice) {
+ $a = $_;
+ # Check whether valid ipv4 or ipv6 address
+ if (($_ =~ /SRC\=(([\d]{1,3})(\.([\d]{1,3})){3})/) or ($_ =~ /SRC\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/)) {
+ if($1 eq $ip) {
+ my $chain = '';
+ my $in = '-'; my $out = '-';
+ my $srcaddr = ''; my $dstaddr = '';
+ my $protostr = '';
+ my $srcport = ''; my $dstport = '';
+
+ # If ipv6 uses bridge, the use PHYSIN, otherwise use IN
+ if ($_ =~ /(^.* ..:..:..) [\w\-]+ kernel:(.*)(IN=.*)(PHYSIN=.*)$/) {}
+ elsif ($_ =~ /(^.* ..:..:..) [\w\-]+ kernel:(.*)(IN=.*)$/) {}
+ my $timestamp = $1; my $chain = $2; my $packet = $3;
+ $timestamp =~ /(...) (..) (..:..:..)/;
+ my $month = $1; my $day = $2; my $time = $3;
+
+ # If ipv6 uses bridge, the use PHYSIN and PHYSOUT, otherwise use IN and OUT
+ if ($a =~ /PHYSIN=(\w+)/) { $iface = $1; } elsif ($a =~ /IN=(\w+)/) { $iface = $1; }
+ if ($a =~ /PHYSOUT=(\w+)/) { $out = $1; } elsif ($a =~ /OUT=(\w+)/) { $out = $1; }
+ # Detect ipv4 and ipv6 addresses
+ if (($a =~ /SRC\=(([\d]{1,3})(\.([\d]{1,3})){3})/) or ($a =~ /SRC\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/)) { $srcaddr = $1; }
+ if (($a =~ /DST\=(([\d]{1,3})(\.([\d]{1,3})){3})/) or ($a =~ /DST\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/)) { $dstaddr = $1; }
+ if ($a =~ /PROTO\=(\w+)/) { $protostr = $1; }
+ my $protostrlc = lc($protostr);
+ if ($a =~ /SPT\=([\d\.]+)/){ $srcport = $1; }
+ if ($a =~ /DPT\=([\d\.]+)/){ $dstport = $1; }
+
+ if ($lines % 2) {
+ print "<tr bgcolor='${Header::table1colour}'>\n";
+ }
+ else {
+ print "<tr bgcolor='${Header::table2colour}'>\n";
+ }
+ print <<END
+ <td align='center'>$time</td>
+ <td align='center'>$chain</td>
+ <td align='center'>$iface</td>
+ <td align='center'>$protostr</td>
+ <td align='center'>
+ <table width='100%' cellpadding='0' cellspacing='0'><tr>
+ <td align='center'><a href='/cgi-bin/ipinfo.cgi?ip=$srcaddr'>$srcaddr</a></td>
+ </tr></table>
+ </td>
+ <td align='center'>$srcport</td>
+ <td align='center'>
+ <table width='100%' cellpadding='0' cellspacing='0'><tr>
+ <td align='center'><a href='/cgi-bin/ipinfo.cgi?ip=$dstaddr'>$dstaddr</a></td>
+ </tr></table>
+ </td>
+ <td align='center'>$dstport</td>
+ </tr>
END
- ;
- $lines++;
- }
- }
+ ;
+ $lines++;
+ }
+ }
}
print <<END
sub oldernewer
{
-print <<END
-<table width='100%'>
-<tr>
+ print <<END
+ <table width='100%'>
+ <tr>
END
-;
+ ;
-print "<td align='center' width='50%'>";
-if ($prev != -1) {
- print "<a href='/cgi-bin/logs.cgi/showrequestfromip.dat?$prev,$cgiparams{'MONTH'},$cgiparams{'DAY'},$cgiparams{ip}'>$Lang::tr{'older'}</a>"; }
-else {
- print "$Lang::tr{'older'}"; }
-print "</td>\n";
+ print "<td align='center' width='50%'>";
+ if ($prev != -1) {
+ print "<a href='/cgi-bin/logs.cgi/showrequestfromip.dat?$prev,$cgiparams{'MONTH'},$cgiparams{'DAY'},$cgiparams{ip}'>$Lang::tr{'older'}</a>";
+ }
+ else {
+ print "$Lang::tr{'older'}";
+ }
+ print "</td>\n";
-print "<td align='center' width='50%'>";
-if ($next != -1) {
- print "<a href='/cgi-bin/logs.cgi/showrequestfromip.dat?$next,$cgiparams{'MONTH'},$cgiparams{'DAY'},$cgiparams{ip}'>$Lang::tr{'newer'}</a>"; }
-else {
- print "$Lang::tr{'newer'}"; }
-print "</td>\n";
+ print "<td align='center' width='50%'>";
+ if ($next != -1) {
+ print "<a href='/cgi-bin/logs.cgi/showrequestfromip.dat?$next,$cgiparams{'MONTH'},$cgiparams{'DAY'},$cgiparams{ip}'>$Lang::tr{'newer'}</a>";
+ }
+ else {
+ print "$Lang::tr{'newer'}";
+ }
+ print "</td>\n";
-print <<END
-</tr>
-</table>
+ print <<END
+ </tr>
+ </table>
END
-;
+ ;
}
}
elsif($cgiparams{'ACTION'} eq '>>')
{
- my @temp_then=();
- my @temp_now = localtime(time);
- $temp_now[4] = $cgiparams{'MONTH'};
- $temp_now[3] = $cgiparams{'DAY'};
- @temp_then = localtime(POSIX::mktime(@temp_now) + 86400);
- ## Retrieve the same time on the next day -
- ## 86400 seconds in a day
- $cgiparams{'MONTH'} = $temp_then[4];
- $cgiparams{'DAY'} = $temp_then[3];
+ my @temp_then=();
+ my @temp_now = localtime(time);
+ $temp_now[4] = $cgiparams{'MONTH'};
+ $temp_now[3] = $cgiparams{'DAY'};
+ @temp_then = localtime(POSIX::mktime(@temp_now) + 86400);
+ ## Retrieve the same time on the next day -
+ ## 86400 seconds in a day
+ $cgiparams{'MONTH'} = $temp_then[4];
+ $cgiparams{'DAY'} = $temp_then[3];
}
elsif($cgiparams{'ACTION'} eq '<<')
{
- my @temp_then=();
- my @temp_now = localtime(time);
- $temp_now[4] = $cgiparams{'MONTH'};
- $temp_now[3] = $cgiparams{'DAY'};
- @temp_then = localtime(POSIX::mktime(@temp_now) - 86400);
- ## Retrieve the same time on the previous day -
- ## 86400 seconds in a day
- $cgiparams{'MONTH'} = $temp_then[4];
- $cgiparams{'DAY'} = $temp_then[3];
+ my @temp_then=();
+ my @temp_now = localtime(time);
+ $temp_now[4] = $cgiparams{'MONTH'};
+ $temp_now[3] = $cgiparams{'DAY'};
+ @temp_then = localtime(POSIX::mktime(@temp_now) - 86400);
+ ## Retrieve the same time on the previous day -
+ ## 86400 seconds in a day
+ $cgiparams{'MONTH'} = $temp_then[4];
+ $cgiparams{'DAY'} = $temp_then[3];
}
if (($cgiparams{'DAY'} ne $now[3]) || ($cgiparams{'MONTH'} ne $now[4]))
{
- my @then = ();
- if ( ( $cgiparams{'MONTH'} eq $now[4]) && ($cgiparams{'DAY'} > $now[3]) ||
- ( $cgiparams{'MONTH'} > $now[4] ) ) {
- @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1901 ));
- } else {
- @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1900 ));
- }
- $tdoy = $then[7];
- my $lastleap=($year-1)%4;
- if ($tdoy>$doy) {
- if ($lastleap == 0 && $tdoy < 60) {
- $doy=$tdoy+366;
- } else {
- $doy=$doy+365;
- }
- }
+ my @then = ();
+ if ( ( $cgiparams{'MONTH'} eq $now[4]) && ($cgiparams{'DAY'} > $now[3]) ||
+ ( $cgiparams{'MONTH'} > $now[4] ) ) {
+ @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1901 ));
+ } else {
+ @then = localtime(POSIX::mktime( 0, 0, 0, $cgiparams{'DAY'}, $cgiparams{'MONTH'}, $year - 1900 ));
+ }
+ $tdoy = $then[7];
+ my $lastleap=($year-1)%4;
+ if ($tdoy>$doy) {
+ if ($lastleap == 0 && $tdoy < 60) {
+ $doy=$tdoy+366;
+ } else {
+ $doy=$doy+365;
+ }
+ }
}
my $datediff=0;
my $dowd=0;
my $multifile=0;
if ($tdoy ne $doy) {
- $datediff=int(($doy-$tdoy)/7);
- $dowd=($doy-$tdoy)%7;
- if (($dow-$dowd)<1) {
- $datediff=$datediff+1;
- }
- if (($dow-$dowd)==0) {
- $multifile=1;
- }
+ $datediff=int(($doy-$tdoy)/7);
+ $dowd=($doy-$tdoy)%7;
+ if (($dow-$dowd)<1) {
+ $datediff=$datediff+1;
+ }
+ if (($dow-$dowd)==0) {
+ $multifile=1;
+ }
}
my $monthstr = $shortmonths[$cgiparams{'MONTH'}];
my $skip=0;
my $filestr='';
if ($datediff==0) {
- $filestr="/var/log/messages";
+ $filestr="/var/log/messages";
} else {
$filestr="/var/log/messages.$datediff";
$filestr = "$filestr.gz" if -f "$filestr.gz";
}
if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
- $errormessage = "$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
- $skip=1;
- # Note: This is in case the log does not exist for that date
+ $errormessage = "$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
+ $skip=1;
+ # Note: This is in case the log does not exist for that date
}
my $lines = 0;
my @log=();
if (!$skip)
{
- while (<FILE>)
- {
- if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
- if($_ =~ /DPT\=([\d\.]+)/){
- if($1 eq $port){
- $log[$lines] = $_;
- $lines++;
- }
- }
+ while (<FILE>)
+ {
+ if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
+ if($_ =~ /DPT\=([\d\.]+)/){
+ if($1 eq $port){
+ $log[$lines] = $_;
+ $lines++;
+ }
+ }
}
}
close (FILE);
$skip=0;
if ($multifile) {
- $datediff=$datediff-1;
- if ($datediff==0) {
- $filestr="/var/log/messages";
- } else {
- $filestr="/var/log/messages.$datediff";
- $filestr = "$filestr.gz" if -f "$filestr.gz";
- }
- if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
- $errormessage="$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
- $skip=1;
- }
- if (!$skip) {
+ $datediff=$datediff-1;
+ if ($datediff==0) {
+ $filestr="/var/log/messages";
+ } else {
+ $filestr="/var/log/messages.$datediff";
+ $filestr = "$filestr.gz" if -f "$filestr.gz";
+ }
+ if (!(open (FILE,($filestr =~ /.gz$/ ? "gzip -dc $filestr |" : $filestr)))) {
+ $errormessage="$Lang::tr{'date not in logs'}: $filestr $Lang::tr{'could not be opened'}";
+ $skip=1;
+ }
+ if (!$skip) {
while (<FILE>) {
- if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
- if($_ =~ /DPT\=([\d\.]+)/){
- if($1 eq $port){
- $log[$lines] = $_;
- $lines++;
- }
- }
+ if (/(^${monthstr} ${daystr} ..:..:..) [\w\-]+ kernel:.*(IN=.*)$/) {
+ if($_ =~ /DPT\=([\d\.]+)/){
+ if($1 eq $port){
+ $log[$lines] = $_;
+ $lines++;
+ }
+ }
}
}
close (FILE);
print "<p><b>$Lang::tr{'firewall hits'} $longmonthstr $daystr: $lines</b></p>";
if ($start == -1) {
- $start = $lines - ${Header::viewsize}; }
+ $start = $lines - ${Header::viewsize};
+}
if ($start >= $lines - ${Header::viewsize}) { $start = $lines - ${Header::viewsize}; };
if ($start < 0) { $start = 0; }
$lines = 0;
foreach $_ (@slice)
{
- $a = $_;
- if($_ =~ /DPT\=([\d\.]+)/){
- if($1 eq $port){
- my $chain = '';
- my $in = '-'; my $out = '-';
- my $srcaddr = ''; my $dstaddr = '';
- my $protostr = '';
- my $srcport = ''; my $dstport = '';
-
- $_ =~ /(^.* ..:..:..) [\w\-]+ kernel:(.*)(IN=.*)$/;
- my $timestamp = $1; my $chain = $2; my $packet = $3;
- $timestamp =~ /(...) (..) (..:..:..)/;
- my $month = $1; my $day = $2; my $time = $3; my $iface;
-
- if ($a =~ /IN\=(\w+)/) { $iface = $1; }
- if ($a =~ /OUT\=(\w+)/) { $out = $1; }
- if ($a =~ /SRC\=([\d\.]+)/) { $srcaddr = $1; }
- if ($a =~ /DST\=([\d\.]+)/) { $dstaddr = $1; }
- if ($a =~ /PROTO\=(\w+)/) { $protostr = $1; }
- my $protostrlc = lc($protostr);
- if ($a =~ /SPT\=([\d\.]+)/){ $srcport = $1; }
- if ($a =~ /DPT\=([\d\.]+)/){ $dstport = $1; }
-
- if ($lines % 2) {
- print "<tr bgcolor='${Header::table1colour}'>\n"; }
- else {
- print "<tr bgcolor='${Header::table2colour}'>\n"; }
- print <<END
- <td align='center'>$time</td>
- <td align='center'>$chain</td>
- <td align='center'>$iface</td>
- <td align='center'>$protostr</td>
- <td align='center'>
- <table width='100%' cellpadding='0' cellspacing='0'><tr>
- <td align='center'><a href='/cgi-bin/ipinfo.cgi?ip=$srcaddr'>$srcaddr</a></td>
- </tr></table>
- </td>
- <td align='center'>$srcport</td>
- <td align='center'>
- <table width='100%' cellpadding='0' cellspacing='0'><tr>
- <td align='center'><a href='/cgi-bin/ipinfo.cgi?ip=$dstaddr'>$dstaddr</a></td>
- </tr></table>
- </td>
- <td align='center'>$dstport</td>
-</tr>
+ $a = $_;
+ if($_ =~ /DPT\=([\d\.]+)/){
+ if($1 eq $port){
+ my $chain = '';
+ my $in = '-';
+ my $out = '-';
+ my $srcaddr = '';
+ my $dstaddr = '';
+ my $protostr = '';
+ my $srcport = '';
+ my $dstport = '';
+
+ # If ipv6 uses bridge, the use PHYSIN, otherwise use IN
+ if ($_ =~ /(^.* ..:..:..) [\w\-]+ kernel:(.*)(IN=.*)(PHYSIN=.*)$/) {}
+ elsif ($_ =~ /(^.* ..:..:..) [\w\-]+ kernel:(.*)(IN=.*)$/) {}
+ my $timestamp = $1; my $chain = $2; my $packet = $3;
+ $timestamp =~ /(...) (..) (..:..:..)/;
+ my $month = $1; my $day = $2; my $time = $3; my $iface;
+
+ # If ipv6 uses bridge, the use PHYSIN and PHYSOUT, otherwise use IN and OUT
+ if ($a =~ /PHYSIN\=(\w+)/) { $iface = $1; } elsif ($a =~ /IN\=(\w+)/) { $iface = $1; }
+ if ($a =~ /PHYSOUT\=(\w+)/) { $out = $1; } elsif ($a =~ /OUT\=(\w+)/) { $out = $1; }
+ # Detect ipv4 and ipv6 addresses
+ if (($a =~ /SRC\=(([\d]{1,3})(\.([\d]{1,3})){3})/) or ($a =~ /SRC\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/)) { $srcaddr = $1; }
+ if (($a =~ /DST\=(([\d]{1,3})(\.([\d]{1,3})){3})/) or ($a =~ /DST\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/)) { $dstaddr = $1; }
+ if ($a =~ /PROTO\=(\w+)/) { $protostr = $1; }
+ my $protostrlc = lc($protostr);
+ if ($a =~ /SPT\=([\d\.]+)/){ $srcport = $1; }
+ if ($a =~ /DPT\=([\d\.]+)/){ $dstport = $1; }
+
+ if ($lines % 2) {
+ print "<tr bgcolor='${Header::table1colour}'>\n";
+ }
+ else {
+ print "<tr bgcolor='${Header::table2colour}'>\n";
+ }
+ print <<END
+ <td align='center'>$time</td>
+ <td align='center'>$chain</td>
+ <td align='center'>$iface</td>
+ <td align='center'>$protostr</td>
+ <td align='center'>
+ <table width='100%' cellpadding='0' cellspacing='0'><tr>
+ <td align='center'><a href='/cgi-bin/ipinfo.cgi?ip=$srcaddr'>$srcaddr</a></td>
+ </tr></table>
+ </td>
+ <td align='center'>$srcport</td>
+ <td align='center'>
+ <table width='100%' cellpadding='0' cellspacing='0'><tr>
+ <td align='center'><a href='/cgi-bin/ipinfo.cgi?ip=$dstaddr'>$dstaddr</a></td>
+ </tr></table>
+ </td>
+ <td align='center'>$dstport</td>
+ </tr>
END
- ;
- $lines++;
- }
- }
+ ;
+ $lines++;
+ }
+ }
}
print <<END
sub oldernewer
{
-print <<END
-<table width='100%'>
-<tr>
+ print <<END
+ <table width='100%'>
+ <tr>
END
-;
+ ;
-print "<td align='center' width='50%'>";
-if ($prev != -1) {
- print "<a href='/cgi-bin/logs.cgi/showrequestfromport.dat?$prev,$cgiparams{'MONTH'},$cgiparams{'DAY'},$cgiparams{port}'>$Lang::tr{'older'}</a>"; }
-else {
- print "$Lang::tr{'older'}"; }
-print "</td>\n";
+ print "<td align='center' width='50%'>";
+ if ($prev != -1) {
+ print "<a href='/cgi-bin/logs.cgi/showrequestfromport.dat?$prev,$cgiparams{'MONTH'},$cgiparams{'DAY'},$cgiparams{port}'>$Lang::tr{'older'}</a>";
+ }
+ else {
+ print "$Lang::tr{'older'}";
+ }
+ print "</td>\n";
-print "<td align='center' width='50%'>";
-if ($next != -1) {
- print "<a href='/cgi-bin/logs.cgi/showrequestfromport.dat?$next,$cgiparams{'MONTH'},$cgiparams{'DAY'},$cgiparams{port}'>$Lang::tr{'newer'}</a>"; }
-else {
- print "$Lang::tr{'newer'}"; }
-print "</td>\n";
+ print "<td align='center' width='50%'>";
+ if ($next != -1) {
+ print "<a href='/cgi-bin/logs.cgi/showrequestfromport.dat?$next,$cgiparams{'MONTH'},$cgiparams{'DAY'},$cgiparams{port}'>$Lang::tr{'newer'}</a>";
+ }
+ else {
+ print "$Lang::tr{'newer'}";
+ }
+ print "</td>\n";
-print <<END
-</tr>
-</table>
+ print <<END
+ </tr>
+ </table>
END
-;
+ ;
}
$checked{'SHOWDROPDOWN'}{'off'} = '';
$checked{'SHOWDROPDOWN'}{'on'} = '';
$checked{'SHOWDROPDOWN'}{$settings{'SHOWDROPDOWN'}} = "checked='checked'";
+$checked{'CONNTRACK_FTP'}{'off'} = '';
+$checked{'CONNTRACK_FTP'}{'on'} = '';
+$checked{'CONNTRACK_FTP'}{$settings{'CONNTRACK_FTP'}} = "checked='checked'";
+$checked{'CONNTRACK_H323'}{'off'} = '';
+$checked{'CONNTRACK_H323'}{'on'} = '';
+$checked{'CONNTRACK_H323'}{$settings{'CONNTRACK_H323'}} = "checked='checked'";
+$checked{'CONNTRACK_IRC'}{'off'} = '';
+$checked{'CONNTRACK_IRC'}{'on'} = '';
+$checked{'CONNTRACK_IRC'}{$settings{'CONNTRACK_IRC'}} = "checked='checked'";
+$checked{'CONNTRACK_SIP'}{'off'} = '';
+$checked{'CONNTRACK_SIP'}{'on'} = '';
+$checked{'CONNTRACK_SIP'}{$settings{'CONNTRACK_SIP'}} = "checked='checked'";
+$checked{'CONNTRACK_TFTP'}{'off'} = '';
+$checked{'CONNTRACK_TFTP'}{'on'} = '';
+$checked{'CONNTRACK_TFTP'}{$settings{'CONNTRACK_TFTP'}} = "checked='checked'";
$selected{'FWPOLICY'}{$settings{'FWPOLICY'}}= 'selected';
$selected{'FWPOLICY1'}{$settings{'FWPOLICY1'}}= 'selected';
$selected{'FWPOLICY2'}{$settings{'FWPOLICY2'}}= 'selected';
<input type='radio' name='SHOWTABLES' value='off' $checked{'SHOWTABLES'}{'off'} /> off</td></tr>
<tr><td align='left' width='60%'>$Lang::tr{'fw settings dropdown'}</td><td align='left'>on <input type='radio' name='SHOWDROPDOWN' value='on' $checked{'SHOWDROPDOWN'}{'on'} />/
<input type='radio' name='SHOWDROPDOWN' value='off' $checked{'SHOWDROPDOWN'}{'off'} /> off</td></tr>
-</table>
+</table>
+<br />
+<table width='95%' cellspacing='0'>
+<tr bgcolor='$color{'color20'}'><td colspan='2' align='left'><b>$Lang::tr{'application layer gateways'}</b></td></tr>
+<tr><td align='left' width='60%'>FTP</td><td align='left'>on <input type='radio' name='CONNTRACK_FTP' value='on' $checked{'CONNTRACK_FTP'}{'on'} />/
+ <input type='radio' name='CONNTRACK_FTP' value='off' $checked{'CONNTRACK_FTP'}{'off'} /> off</td></tr>
+<tr><td align='left' width='60%'>H.323</td><td align='left'>on <input type='radio' name='CONNTRACK_H323' value='on' $checked{'CONNTRACK_H323'}{'on'} />/
+ <input type='radio' name='CONNTRACK_H323' value='off' $checked{'CONNTRACK_H323'}{'off'} /> off</td></tr>
+<tr><td align='left' width='60%'>IRC</td><td align='left'>on <input type='radio' name='CONNTRACK_IRC' value='on' $checked{'CONNTRACK_IRC'}{'on'} />/
+ <input type='radio' name='CONNTRACK_IRC' value='off' $checked{'CONNTRACK_IRC'}{'off'} /> off</td></tr>
+<tr><td align='left' width='60%'>SIP</td><td align='left'>on <input type='radio' name='CONNTRACK_SIP' value='on' $checked{'CONNTRACK_SIP'}{'on'} />/
+ <input type='radio' name='CONNTRACK_SIP' value='off' $checked{'CONNTRACK_SIP'}{'off'} /> off</td></tr>
+<tr><td align='left' width='60%'>TFTP</td><td align='left'>on <input type='radio' name='CONNTRACK_TFTP' value='on' $checked{'CONNTRACK_TFTP'}{'on'} />/
+ <input type='radio' name='CONNTRACK_TFTP' value='off' $checked{'CONNTRACK_TFTP'}{'off'} /> off</td></tr>
+
+</table>
<br />
<table width='95%' cellspacing='0'>
<tr bgcolor='$color{'color20'}'><td colspan='2' align='left'><b>$Lang::tr{'fw default drop'}</b></td></tr>
}
print CLIENTCONF "verb 3\r\n";
print CLIENTCONF "ns-cert-type server\r\n";
- print CLIENTCONF "tls-remote $vpnsettings{ROOTCERT_HOSTNAME}\r\n";
+ print CLIENTCONF "verify-x509-name $vpnsettings{ROOTCERT_HOSTNAME} name\r\n";
if ($vpnsettings{MSSFIX} eq 'on') {
print CLIENTCONF "mssfix\r\n";
}
$qossettings{'ENABLED'} = 'on';
&General::writehash("${General::swroot}/qos/settings", \%qossettings);
system("/usr/local/bin/qosctrl generate >/dev/null 2>&1");
- system("/usr/bin/touch /var/ipfire/qos/enable");
system("/usr/local/bin/qosctrl start >/dev/null 2>&1");
system("logger -t ipfire 'QoS started'");
}
elsif ($qossettings{'ACTION'} eq $Lang::tr{'stop'})
{
- system("/usr/local/bin/qosctrl stop >/dev/null 2>&1");
- unlink "/var/ipfire/qos/bin/qos.sh";
- unlink "/var/ipfire/qos/enable";
- system("logger -t ipfire 'QoS stopped'");
$qossettings{'ENABLED'} = 'off';
&General::writehash("${General::swroot}/qos/settings", \%qossettings);
+ system("/usr/local/bin/qosctrl stop >/dev/null 2>&1");
+ system("/usr/local/bin/qosctrl generate >/dev/null 2>&1");
+ system("logger -t ipfire 'QoS stopped'");
}
elsif ($qossettings{'ACTION'} eq $Lang::tr{'restart'})
{
$qossettings{'ENABLED'} = 'on';
&General::writehash("${General::swroot}/qos/settings", \%qossettings);
system("/usr/local/bin/qosctrl generate >/dev/null 2>&1");
- system("/usr/bin/touch /var/ipfire/qos/enable");
system("/usr/local/bin/qosctrl start >/dev/null 2>&1");
system("logger -t ipfire 'QoS started'");
} else {
# #
###############################################################################
+use strict;
+
+#usable only the following on debugging purpose
+#use warnings;
+#use CGI::Carp 'fatalsToBrowser';
use CGI;
+require '/var/ipfire/general-functions.pl';
+require "${General::swroot}/lang.pl";
+require "${General::swroot}/header.pl";
+
+
my $swroot = "/var/ipfire";
my $apdir = "$swroot/proxy/advanced";
my $group_def_file = "$apdir/cre/classrooms";
my $banner = "A D V A N C E D P R O X Y - W E B A C C E S S M A N A G E R";
my %cgiparams;
my %proxysettings;
+my %temp;
my %acl=();
my @group_defs=();
foreach (@groups)
{
- if ($cgiparams{$_} eq $tr{'advproxy mode deny'}) { $acl{$_}='on'; }
- if ($cgiparams{$_} eq $tr{'advproxy mode allow'}) { $acl{$_}='off'; }
+ if ($cgiparams{$_} eq $Lang::tr{'advproxy mode deny'}) { $acl{$_}='on'; }
+ if ($cgiparams{$_} eq $Lang::tr{'advproxy mode allow'}) { $acl{$_}='off'; }
}
&read_all_groups;
{
print <<END
<td align='center'>
- <font face='verdana,arial,helvetica' color='#000000' size='2'>$tr{'advproxy supervisor password'}:</font>
+ <font face='verdana,arial,helvetica' color='#000000' size='2'>$Lang::tr{'advproxy supervisor password'}:</font>
</td>
<td align='center'><input type='password' name='PASSWORD' size='15'></td>
END
if ((defined($acl{$_})) && ($acl{$_} eq 'on'))
{
print "</td><td width='120' align='center'>";
- print "<input type='submit' name='$_' value=' $tr{'advproxy mode allow'} '>";
+ print "<input type='submit' name='$_' value=' $Lang::tr{'advproxy mode allow'} '>";
print "</td><td width='16' bgcolor='#D00000'> </td>\n";
} else {
print "</td><td width='120' align='center'>";
- print "<input type='submit' name='$_' value=' $tr{'advproxy mode deny'} '>";
+ print "<input type='submit' name='$_' value=' $Lang::tr{'advproxy mode deny'} '>";
print "</td><td width='16' bgcolor='#00A000'> </td>\n";
}
}
} else {
print " <tr>\n";
print " <td align='center'>\n";
- print " <font face='verdana,arial,helvetica' color='#000000' size='2'>$tr{'advproxy no cre groups'}</font>\n";
+ print " <font face='verdana,arial,helvetica' color='#000000' size='2'>$Lang::tr{'advproxy no cre groups'}</font>\n";
print " </td>\n";
print " </tr>\n";
}
} else {
print " <tr>\n";
print " <td align='center'>\n";
- print " <font face='verdana,arial,helvetica' color='#000000' size='2'>$tr{'advproxy cre disabled'}</font>\n";
+ print " <font face='verdana,arial,helvetica' color='#000000' size='2'>$Lang::tr{'advproxy cre disabled'}</font>\n";
print " </td>\n";
print " </tr>\n";
}
'alt vpn' => 'VPNs',
'and' => 'Und',
'apcupsd' => 'APC-UPS Status',
+'application layer gateways' => 'Application-Layer-Gateways',
'apply' => 'Jetzt anwenden',
'april' => 'April',
'archive not exist' => 'Konfigurationsarchiv existiert nicht',
'and' => 'And',
'ansi t1.483' => 'TO BE REMOVED',
'apcupsd' => 'APC-UPS status',
+'application layer gateways' => 'Application Layer Gateways',
'apply' => 'Apply now',
'april' => 'April',
'archive not exist' => 'Configuration archive does not exist',
DIR_INFO = $(LFS_BASEDIR)/log
DIR_TMP = /tmp
+# Add the compiler location and version and specs to the ccache hash
+CCACHE_COMPILERCHECK += $(shell gcc -dumpspecs 2>/dev/null | md5sum | cut -d ' ' -f1)
+
###############################################################################
# Common Macro Definitions
###############################################################################
###############################################################################
# #
# IPFire.org - A linux based firewall #
-# Copyright (C) 2007-2015 IPFire Team <info@ipfire.org> #
+# Copyright (C) 2007-2016 IPFire Team <info@ipfire.org> #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
VERSUFIX = ipfire$(KCFG)
-VER = 3.18.1-1
+VER = 4.2.6-1
THISAPP = backports-$(VER)
DL_FILE = $(THISAPP).tar.xz
$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
-$(DL_FILE)_MD5 = 6cef5f2c800e12441d2cba9fa42b6a5b
+$(DL_FILE)_MD5 = 3f978eb56473d9289cf21ebbcb5aa80b
install : $(TARGET)
$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
@$(PREBUILD)
+
+ # remove replaced kernel modules
+ rm -rf /lib/modules/$(KVER)-$(VERSUFIX)/kernel/drivers/net/wireless/rtl818x/rtl8180/rtl8180.ko
+ rm -rf /lib/modules/$(KVER)-$(VERSUFIX)/kernel/drivers/media
+
@rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar Jxf $(DIR_DL)/$(DL_FILE)
cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/backports-3.18.1-1-ipfire-build.patch
- cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/backports-3.18.1-1-grsecurity.patch
- cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/backports-3.18.1-1-add_usbnet_modules.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/backports-4.2.6-1-grsecurity.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/backports-4.2.6-1-add_usbnet_modules.patch
ifeq "$(MACHINE)" "x86_64"
cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/backports-3.18.1-1_no_dma_sgtable_on_x86_64.patch
endif
# DVB patches
cd $(DIR_APP) && patch -Np2 < $(DIR_SRC)/src/patches/v4l-dvb_fix_tua6034_pll.patch
- cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux-3.10-dvb_tevi_s482.patch
# Wlan patches
cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/compat-drivers-3.8.3-ath_ignore_eeprom_regdomain.patch
cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux-3.14.22-iwlwifi-noibss_only_on_radar_chan.patch
cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux-3.10.37-rt2800usb_add_dlink_dwa137_usbid.patch
cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/backports-3.18.1-1_rt2x00usb_suppress_queue_warnings.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/backports-4.2.6-1-mt7601_upstream_fixes.patch
cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/backports-3.18.1-1_add_libertas_uap.patch
# smsc mac address patch for pandaboard and raspberry pi
# Disable some settings
cd $(DIR_APP) && sed -i -e "s/CPTCFG_CFG80211_DEVELOPER_WARNINGS=y/# CPTCFG_CFG80211_DEVELOPER_WARNINGS is not set/g" .config
- cd $(DIR_APP) && sed -i -e "s/CPTCFG_CFG80211_CERTIFICATION_ONUS=y/# CPTCFG_CFG80211_CERTIFICATION_ONUS is not set/g" .config
- cd $(DIR_APP) && sed -i -e "s/CPTCFG_CFG80211_REG_CELLULAR_HINTS=y/# CPTCFG_CFG80211_REG_CELLULAR_HINTS is not set/g" .config
- cd $(DIR_APP) && sed -i -e "s/CPTCFG_CFG80211_REG_RELAX_NO_IR=y/# CPTCFG_CFG80211_REG_RELAX_NO_IR is not set/g" .config
cd $(DIR_APP) && sed -i -e "s/CPTCFG_CFG80211_INTERNAL_REGDB=y/# CPTCFG_CFG80211_INTERNAL_REGDB is not set/g" .config
cd $(DIR_APP) && sed -i -e "s/CPTCFG_CFG80211_DEFAULT_PS=y/# CPTCFG_CFG80211_DEFAULT_PS is not set/g" .config
cd $(DIR_APP) && sed -i -e "s/CPTCFG_NFC=m/# CPTCFG_NFC is not set/g" .config
cd $(DIR_APP) && sed -i -e "s/CPTCFG_LIBERTAS_UAP=m/# CPTCFG_LIBERTAS_UAP is not set/g" .config
endif
- # Disable some modules (build fail)
+ # Disable some modules (build fail/missing symbols)
+ cd $(DIR_APP) && sed -i -e "s/CPTCFG_VIDEO_AM437X_VPFE=m/# CPTCFG_VIDEO_AM437X_VPFE is not set/g" .config
cd $(DIR_APP) && sed -i -e "s/CPTCFG_VIDEO_VIA_CAMERA=m/# CPTCFG_VIDEO_VIA_CAMERA is not set/g" .config
+ cd $(DIR_APP) && sed -i -e "s/CPTCFG_VIDEO_XILINX=m/# CPTCFG_VIDEO_XILINX is not set/g" .config
+ cd $(DIR_APP) && sed -i -e "s/CPTCFG_IR_SUNXI=m/# CPTCFG_IR_SUNXI is not set/g" .config
+ cd $(DIR_APP) && sed -i -e "s/CPTCFG_BT_6LOWPAN=m/# CPTCFG_BT_6LOWPAN is not set/g" .config
# Disable DEBUG
cd $(DIR_APP) && sed -i -e "s/.*DEBUG=y/# & is not set/g" .config
cd $(DIR_APP) && sed -i -e "s/.*DEBUGFS=y/# & is not set/g" .config
cd $(DIR_APP) && sed -i -e "s/=y is not set/ is not set/g" .config
- # Disable OF_GRAPH (not supported by kernel 3.14)
- cd $(DIR_APP) && sed -i -e "s/CONFIG_OF/CONFIG_OF_IGNORE/g" include/linux/of_graph.h
-
cd $(DIR_APP) && make $(MAKETUNING) KLIB=/lib/modules/$(KVER)-$(VERSUFIX)/ install
- # Remove vsp1 module (not mach to our platforms)
- rm -rf /lib/modules/$(KVER)-$(VERSUFIX)/kernel/drivers/media/platform/vsp1
-
@rm -rf $(DIR_APP)
@$(POSTBUILD)
include Config
-VER = 9.10.2-P4
+VER = 9.10.3-P2
THISAPP = bind-$(VER)
DL_FILE = $(THISAPP).tar.gz
$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
-$(DL_FILE)_MD5 = 8b1f5064837756c938eadc1537dec5c7
+$(DL_FILE)_MD5 = 672dd3c2796b12ac8440f55bcaecfa82
install : $(TARGET)
###############################################################################
# #
# IPFire.org - A linux based firewall #
-# Copyright (C) 2007-2015 IPFire Team <info@ipfire.org> #
+# Copyright (C) 2007-2016 IPFire Team <info@ipfire.org> #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
include Config
-VER = 2.22
+VER = 2.24
THISAPP = binutils-$(VER)
DL_FILE = $(THISAPP).tar.bz2
EXTRA_CONFIG = \
--prefix=/usr \
--enable-shared \
- --disable-nls
+ --disable-nls \
+ --disable-werror
EXTRA_MAKE = tooldir=/usr
EXTRA_INSTALL = tooldir=/usr
else
ifeq "$(PASS)" "1"
CFLAGS := $(patsubst -march=%,,$(CFLAGS))
CFLAGS := $(patsubst -mfloat-abi=%,,$(CFLAGS))
+ CFLAGS := $(patsubst -fstack-protector-strong,-fstack-protector-all,$(CFLAGS))
TARGET = $(DIR_INFO)/$(THISAPP)-tools1
EXTRA_CONFIG = \
--target=$(CROSSTARGET) \
--prefix=/tools \
+ --with-sysroot=$(ROOT) \
+ --with-lib-path=/tools/lib \
--disable-nls \
--disable-werror
EXTRA_MAKE =
--build=$(BUILDTARGET) \
--prefix=/tools \
--with-lib-path=/tools/lib \
- --disable-nls
+ --disable-nls \
+ --disable-werror
EXTRA_MAKE =
EXTRA_INSTALL =
endif
$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
-$(DL_FILE)_MD5 = ee0f10756c84979622b992a4a61ea3f5
+$(DL_FILE)_MD5 = e0f71a7b2ddab0f8612336ac81d9636b
install : $(TARGET)
$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
@$(PREBUILD)
@rm -rf $(DIR_APP) $(DIR_SRC)/binutils-build && cd $(DIR_SRC) && tar jxf $(DIR_DL)/$(DL_FILE)
- cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/binutils-2.22-pt-pax-flags-20111121.patch
-
- # texinfo 5 syntax-fix.
- cd $(DIR_APP) && sed -i -e "s/@colophon/@@colophon/" \
- -e "s/doc@cygnus/doc@@cygnus/" bfd/doc/bfd.texinfo
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/binutils-2.24-pt-pax-flags-20131231.patch
@mkdir $(DIR_SRC)/binutils-build
###############################################################################
# #
# IPFire.org - A linux based firewall #
-# Copyright (C) 2010 IPFire Team <info@ipfire.org> #
+# Copyright (C) 2007-2016 IPFire Team <info@ipfire.org> #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
ifeq "$(PASS)" "1"
CFLAGS := $(patsubst -march=%,,$(CFLAGS))
CFLAGS := $(patsubst -mfloat-abi=%,,$(CFLAGS))
+ CFLAGS := $(patsubst -fstack-protector-strong,-fstack-protector-all,$(CFLAGS))
endif
# Set max cache size to 5GB
ifeq "$(PASS)" "1"
SPECS=$$(dirname $$(/tools/bin/$(CROSSTARGET)-gcc -print-libgcc-file-name))/specs; \
/tools/bin/$(CROSSTARGET)-gcc -dumpspecs | sed \
- -e 's@/lib\(64\)\?/ld@/tools&@g' \
-e "/^\*cpp:$$/{n;s,$$, -isystem /tools/include,}" > $$SPECS
endif
DIR_APP = $(DIR_SRC)/$(THISAPP)
TARGET = $(DIR_INFO)/$(THISAPP)
-ifeq "$(MACHINE)" "armv5tel"
- MAKETUNING = -j2
-endif
+MAKETUNING = -j2
###############################################################################
# Top-level Rules
echo "POLICY=MODE2" >> $(CONFIG_ROOT)/firewall/settings
echo "POLICY1=MODE2" >> $(CONFIG_ROOT)/firewall/settings
+ # Add conntrack helper default settings
+ for proto in FTP H323 IRC SIP TFTP; do \
+ echo "CONNTRACK_$${proto}=on" >> $(CONFIG_ROOT)/optionsfw/settings; \
+ done
+
+ # Do not enable these by default because these are broken
+ for proto in AMANDA PPTP; do \
+ echo "CONNTRACK_$${proto}=off" >> $(CONFIG_ROOT)/optionsfw/settings; \
+ done
+
# set converters executable
chmod 755 /usr/sbin/convert-*
rm -f $(CONFIG_ROOT)/dhcpc/dhcpcd-hooks/50-yp.conf
rm -f $(CONFIG_ROOT)/dhcpc/dhcpcd-hooks/50-ypbind
- sed -i -e "s|-ge 576|-gt 576|g" $(CONFIG_ROOT)/dhcpc/dhcpcd-hooks/10-mtu
-
install -m 644 $(DIR_SRC)/config/dhcpc/dhcpcd.conf $(CONFIG_ROOT)/dhcpc/
+ install -m 444 $(DIR_SRC)/config/dhcpc/dhcpcd-hooks/10-mtu $(CONFIG_ROOT)/dhcpc/dhcpcd-hooks
+
chown root:root $(CONFIG_ROOT)/dhcpc/dhcpcd.conf
@rm -rf $(DIR_APP)
--- /dev/null
+###############################################################################
+# #
+# IPFire.org - A linux based firewall #
+# Copyright (C) 2015 IPFire Team <info@ipfire.org> #
+# #
+# This program is free software: you can redistribute it and/or modify #
+# it under the terms of the GNU General Public License as published by #
+# the Free Software Foundation, either version 3 of the License, or #
+# (at your option) any later version. #
+# #
+# This program is distributed in the hope that it will be useful, #
+# but WITHOUT ANY WARRANTY; without even the implied warranty of #
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
+# GNU General Public License for more details. #
+# #
+# You should have received a copy of the GNU General Public License #
+# along with this program. If not, see <http://www.gnu.org/licenses/>. #
+# #
+###############################################################################
+
+###############################################################################
+# Definitions
+###############################################################################
+
+include Config
+
+VER = 0.0.498gac688af
+
+THISAPP = dnsdist-$(VER)
+DL_FILE = $(THISAPP).tar.bz2
+DL_FROM = $(URL_IPFIRE)
+DIR_APP = $(DIR_SRC)/$(THISAPP)
+TARGET = $(DIR_INFO)/$(THISAPP)
+SUP_ARCH = x86_64 i586
+PROG = dnsdist
+PAK_VER = 1
+
+DEPS = ""
+
+###############################################################################
+# Top-level Rules
+###############################################################################
+
+objects = $(DL_FILE)
+
+$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
+
+$(DL_FILE)_MD5 = b1bc53b3a35aef7006b74086919847bf
+
+install : $(TARGET)
+
+check : $(patsubst %,$(DIR_CHK)/%,$(objects))
+
+download :$(patsubst %,$(DIR_DL)/%,$(objects))
+
+md5 : $(subst %,%_MD5,$(objects))
+
+dist:
+ @$(PAK)
+
+###############################################################################
+# Downloading, checking, md5sum
+###############################################################################
+
+$(patsubst %,$(DIR_CHK)/%,$(objects)) :
+ @$(CHECK)
+
+$(patsubst %,$(DIR_DL)/%,$(objects)) :
+ @$(LOAD)
+
+$(subst %,%_MD5,$(objects)) :
+ @$(MD5)
+
+###############################################################################
+# Installation Details
+###############################################################################
+
+$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
+ @$(PREBUILD)
+ @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE)
+ cd $(DIR_APP) && ./configure --prefix=/usr --sysconfdir=/etc
+ cd $(DIR_APP) && make $(MAKETUNING)
+ cd $(DIR_APP) && make install
+ @rm -rf $(DIR_APP)
+ @$(POSTBUILD)
+
cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/dnsmasq/022-Tidy_up_DNSSEC_non-existence_code_Check_zone_status_is_NSEC_proof_bad.patch
cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/dnsmasq/023-Fix_brace_botch_in_dnssec_validate_ds.patch
cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/dnsmasq/024-Do_a_better_job_of_determining_which_DNSSEC_sig_algos_are_supported.patch
+ cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/dnsmasq/025-Major_tidy_up_of_EDNS0_handling_and_computation_use_of_udp.patch
+ cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/dnsmasq/026-More_tweaks_in_handling_unknown_DNSSEC_algorithms.patch
+ cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/dnsmasq/027-Nasty_rare_and_obscure_off-by-one_in_DNSSEC_hostname_cmp.patch
+ cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/dnsmasq/028-Minor_tweak_to_previous_commit.patch
+ cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/dnsmasq/029-NSEC3_check_RFC5155_para_8_2.patch
cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/dnsmasq-Add-support-to-read-ISC-DHCP-lease-file.patch
cd $(DIR_APP) && sed -i src/config.h \
###############################################################################
# #
# IPFire.org - A linux based firewall #
-# Copyright (C) 2007-2011 IPFire Team <info@ipfire.org> #
+# Copyright (C) 2007-2016 IPFire Team <info@ipfire.org> #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
include Config
-VER = 4.4.7
+VER = 4.9.3
GMP_VER = 5.0.5
MPFR_VER = 2.4.2
+MPC_VER = 1.0.3
THISAPP = gcc-$(VER)
-DL_FILE = $(THISAPP).tar.bz2
+DL_FILE = $(THISAPP).tar.gz
DL_FROM = $(URL_IPFIRE)
DIR_APP = $(DIR_SRC)/$(THISAPP)
CFLAGS := $(patsubst -march=%,,$(CFLAGS))
CFLAGS := $(patsubst -mtune=%,,$(CFLAGS))
CFLAGS := $(patsubst -mfloat-abi=%,,$(CFLAGS))
-
-# https://bugzilla.redhat.com/show_bug.cgi?id=476370
-CFLAGS += -fgnu89-inline
+CFLAGS := $(filter-out -fexceptions,$(CFLAGS))
+CXXFLAGS := $(CFLAGS)
# Normal build or /tools build.
#
EXTRA_INSTALL =
else
ifeq "$(PASS)" "1"
+ CFLAGS := $(patsubst -fstack-protector-strong,-fstack-protector-all,$(CFLAGS))
+ CXXFLAGS := $(patsubst -fstack-protector-strong,-fstack-protector-all,$(CXXFLAGS))
TARGET = $(DIR_INFO)/$(THISAPP)-tools1
EXTRA_CONFIG = \
--target=$(CROSSTARGET) \
--prefix=/tools \
+ --with-sysroot=$(ROOT) \
--disable-nls \
--disable-shared \
--disable-decimal-float \
--disable-threads \
+ --disable-libatomic \
--disable-libmudflap \
--disable-libssp \
--disable-libgomp \
--disable-libquadmath \
+ --disable-libstdc++-v3 \
+ --disable-libvtv \
+ --disable-libcilkrts \
+ --disable-libitm \
+ --disable-libsanitizer \
--with-newlib \
--without-headers \
--without-ppl \
--without-cloog \
- --enable-languages=c
+ --enable-languages=c,c++
EXTRA_MAKE =
EXTRA_INSTALL =
else
+ifeq "$(PASS)" "2"
TARGET = $(DIR_INFO)/$(THISAPP)-tools2
EXTRA_ENV = \
CC="$(CROSSTARGET)-gcc -B/tools/lib/" \
+ CXX="$(CROSSTARGET)-g++" \
AR="$(CROSSTARGET)-ar" \
RANLIB="$(CROSSTARGET)-ranlib"
EXTRA_CONFIG = \
--target=$(BUILDTARGET) \
--prefix=/tools \
--with-local-prefix=/tools \
+ --with-native-system-header-dir=/tools/include \
--enable-clocale=gnu \
--enable-shared \
--enable-threads=posix \
--enable-__cxa_atexit \
--enable-languages=c,c++ \
--disable-libstdcxx-pch \
- --disable-bootstrap
+ --enable-bootstrap
+ EXTRA_MAKE =
+ EXTRA_INSTALL =
+else
+ # PASS=L # libstdc++-v3
+ TARGET = $(DIR_INFO)/$(THISAPP)-libstdc++
+ EXTRA_ENV = \
+ CC="$(CROSSTARGET)-gcc -B/tools/lib/" \
+ AR="$(CROSSTARGET)-ar" \
+ RANLIB="$(CROSSTARGET)-ranlib"
+ EXTRA_CONFIG = \
+ --host=$(CROSSTARGET) \
+ --prefix=/tools \
+ --with-sysroot=$(ROOT) \
+ --disable-shared \
+ --disable-nls \
+ --disable-libstdcxx-threads \
+ --disable-libstdcxx-pch \
+ --with-gxx-include-dir=/tools/$(CROSSTARGET)/include/c++/$(VER)
EXTRA_MAKE =
EXTRA_INSTALL =
+endif
endif
# Disable stack protection in toolchain.
objects = $(DL_FILE) \
gmp-$(GMP_VER).tar.bz2 \
- mpfr-$(MPFR_VER).tar.bz2
+ mpfr-$(MPFR_VER).tar.bz2 \
+ mpc-$(MPC_VER).tar.gz
$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
gmp-$(GMP_VER).tar.bz2 = $(DL_FROM)/gmp-$(GMP_VER).tar.bz2
mpfr-$(MPFR_VER).tar.bz2 = $(DL_FROM)/mpfr-$(MPFR_VER).tar.bz2
+mpc-$(MPC_VER).tar.gz = $(DL_FROM)/mpc-$(MPC_VER).tar.gz
-$(DL_FILE)_MD5 = 295709feb4441b04e87dea3f1bab4281
+$(DL_FILE)_MD5 = 648bfba342bb41a4b5350fb685f85bc5
gmp-$(GMP_VER).tar.bz2_MD5 = 041487d25e9c230b0c42b106361055fe
mpfr-$(MPFR_VER).tar.bz2_MD5 = 89e59fe665e2b3ad44a6789f40b059a0
+mpc-$(MPC_VER).tar.gz_MD5 = d6a1d5f8ddea3abd2cc3e98f58352d26
install : $(TARGET)
$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
@$(PREBUILD)
- @rm -rf $(DIR_APP) $(DIR_SRC)/gcc-build && cd $(DIR_SRC) && tar jxf $(DIR_DL)/$(DL_FILE)
+ @rm -rf $(DIR_APP) $(DIR_SRC)/gcc-build && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE)
@mkdir $(DIR_SRC)/gcc-build
# Apply patches.
- cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/gcc/gcc44-build-id.patch
- cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/gcc/gcc44-c++-builtin-redecl.patch
- cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/gcc/gcc44-i386-libgomp.patch
- cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/gcc/gcc44-libtool-no-rpath.patch
- cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/gcc/gcc44-no-add-needed.patch
- cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/gcc/gcc44-pr33763.patch
- cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/gcc/gcc44-rh330771.patch
- cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/gcc/gcc44-rh533181.patch
- cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/gcc/gcc44-rh610785.patch
- cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/gcc/gcc44-unwind-debug-hook.patch
-
- # texinfo 5 syntax-fixes
- cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/gcc-4.4.7-texinfo-5.patch
+ cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/gcc/gcc49-i386-libgomp.patch
+ cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/gcc/gcc49-libtool-no-rpath.patch
+ cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/gcc/gcc49-no-add-needed.patch
+ cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/gcc/gcc49-pr38757.patch
+ cd $(DIR_APP) && patch -Np0 < $(DIR_SRC)/src/patches/gcc/gcc49-pr64336.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/gcc/gcc-fix-inlining-issues.patch
ifneq "$(ROOT)" ""
# Build gmp and mpfr internally in toolchain.
cd $(DIR_APP) && mv -v gmp-$(GMP_VER) gmp
cd $(DIR_APP) && tar xfa $(DIR_DL)/mpfr-$(MPFR_VER).tar.bz2
cd $(DIR_APP) && mv -v mpfr-$(MPFR_VER) mpfr
+ cd $(DIR_APP) && tar xfa $(DIR_DL)/mpc-$(MPC_VER).tar.gz
+ cd $(DIR_APP) && mv -v mpc-$(MPC_VER) mpc
ifeq "$(PASS)" "1"
# GCC does not detect stack protection correctly, which causes problems
# for the build of libresolv_pic.a.
cd $(DIR_APP) && sed -i '/k prot/agcc_cv_libc_provides_ssp=yes' gcc/configure
+
+ for file in $$(find $(DIR_APP)/gcc/config -name linux64.h -o -name linux.h \
+ -o -name sysv4.h -o -name linux-eabi.h -o -name linux-elf.h); do \
+ echo "Processing $${file}..."; \
+ sed -i $${file} \
+ -e 's@/lib\(64\)\?\(32\)\?/ld@/tools&@g' \
+ -e 's@/usr@/tools@g'; \
+ echo '#undef STANDARD_STARTFILE_PREFIX_1' >> $${file}; \
+ echo '#undef STANDARD_STARTFILE_PREFIX_2' >> $${file}; \
+ echo '#define STANDARD_STARTFILE_PREFIX_1 "/tools/lib/"' >> $${file}; \
+ echo '#define STANDARD_STARTFILE_PREFIX_2 ""' >> $${file}; \
+ done
endif
ifeq "$(PASS)" "2"
- cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/gcc-4.4.3-startfiles_fix-1.patch
-
+ cd $(DIR_APP) && cat gcc/limitx.h gcc/glimits.h gcc/limity.h > \
+ `dirname $$(/tools/bin/$(CROSSTARGET)-gcc -print-libgcc-file-name)`/include-fixed/limits.h
for file in $$(find $(DIR_APP)/gcc/config -name linux64.h -o -name linux.h \
-o -name sysv4.h -o -name linux-eabi.h -o -name linux-elf.h); do \
echo "Processing $${file}..."; \
sed -i $${file} \
-e 's@/lib\(64\)\?\(32\)\?/ld@/tools&@g' \
-e 's@/usr@/tools@g'; \
- echo '#undef STANDARD_INCLUDE_DIR' >> $${file}; \
- echo '#define STANDARD_INCLUDE_DIR 0' >> $${file}; \
- echo '#define STANDARD_STARTFILE_PREFIX_1 ""' >> $${file}; \
+ echo '#undef STANDARD_STARTFILE_PREFIX_1' >> $${file}; \
+ echo '#undef STANDARD_STARTFILE_PREFIX_2' >> $${file}; \
+ echo '#define STANDARD_STARTFILE_PREFIX_1 "/tools/lib/"' >> $${file}; \
echo '#define STANDARD_STARTFILE_PREFIX_2 ""' >> $${file}; \
done
endif
-e 's@\./fixinc\.sh@-c true@' \
-e 's/^T_CFLAGS =$$/& -fomit-frame-pointer/'
+ifeq "$(PASS)" "L"
+ # libstdc++ pass
+ cd $(DIR_SRC)/gcc-build && \
+ $(EXTRA_ENV) \
+ $(DIR_APP)/libstdc++-v3/configure \
+ $(EXTRA_CONFIG)
+ cd $(DIR_SRC)/gcc-build && make $(MAKETUNING) $(EXTRA_MAKE)
+ cd $(DIR_SRC)/gcc-build && make $(EXTRA_INSTALL) install
+else
# The actual build.
cd $(DIR_SRC)/gcc-build && \
$(EXTRA_ENV) \
$(EXTRA_CONFIG)
cd $(DIR_SRC)/gcc-build && make $(MAKETUNING) $(EXTRA_MAKE)
cd $(DIR_SRC)/gcc-build && make $(EXTRA_INSTALL) install
+endif
ifeq "$(ROOT)" ""
ln -svf ../usr/bin/cpp /lib
ln -svf gcc /usr/bin/cc
+ # remove gdb python files from libdir
+ rm -rf /usr/lib/*-gdb.py
else
ifeq "$(PASS)" "1"
ln -svf libgcc.a $$(/tools/bin/$(CROSSTARGET)-gcc -print-libgcc-file-name | sed 's/libgcc/&_eh/')
else
ln -svf gcc /tools/bin/cc
+ # remove gdb python files from libdir
+ rm -rf /tools/lib/*-gdb.py
endif
endif
@rm -rf $(DIR_APP) $(DIR_SRC)/gcc-build
--with-headers=/tools/include \
libc_cv_forced_unwind=yes \
libc_cv_ctors_header=yes \
- libc_cv_c_cleanup=yes
+ libc_cv_c_cleanup=yes \
+ CC=/tools/bin/$(CROSSTARGET)-gcc
EXTRA_MAKE =
EXTRA_INSTALL =
endif
cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/glibc-test-installation.pl-libgcc_s.patch
cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/glibc-2.12-accept-make-versions-4.0-and-greater.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/glibc/glibc-mq_open.patch
# Fixes:
# Makefile:235: *** mixed implicit and normal rules. Stop.
###############################################################################
# #
# IPFire.org - A linux based firewall #
-# Copyright (C) 2007 Michael Tremer & Christian Schmidt #
+# Copyright (C) 2016 Michael Tremer & Christian Schmidt #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
include Config
-VER = 2.21
+VER = 2.22
THISAPP = grep-$(VER)
DL_FILE = $(THISAPP).tar.xz
$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
-$(DL_FILE)_MD5 = 43c48064d6409862b8a850db83c8038a
+$(DL_FILE)_MD5 = e1015e951a49a82b02e38891026ef5df
install : $(TARGET)
# Disable hardening.
paxctl -mpes /usr/sbin/grub-bios-setup /usr/sbin/grub-probe
+ paxctl -mpexs /usr/bin/grub-script-check
# We don't need to install unifont just to generate a grub2 compatible
# font archive for the graphical boot menu. The following command only
--- /dev/null
+###############################################################################
+# #
+# IPFire.org - A linux based firewall #
+# Copyright (C) 2007 Michael Tremer & Christian Schmidt #
+# #
+# This program is free software: you can redistribute it and/or modify #
+# it under the terms of the GNU General Public License as published by #
+# the Free Software Foundation, either version 3 of the License, or #
+# (at your option) any later version. #
+# #
+# This program is distributed in the hope that it will be useful, #
+# but WITHOUT ANY WARRANTY; without even the implied warranty of #
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
+# GNU General Public License for more details. #
+# #
+# You should have received a copy of the GNU General Public License #
+# along with this program. If not, see <http://www.gnu.org/licenses/>. #
+# #
+###############################################################################
+
+###############################################################################
+# Definitions
+###############################################################################
+
+include Config
+
+VER = 1.0.3
+
+THISAPP = mpc-$(VER)
+DL_FILE = $(THISAPP).tar.gz
+DL_FROM = $(URL_IPFIRE)
+DIR_APP = $(DIR_SRC)/$(THISAPP)
+TARGET = $(DIR_INFO)/$(THISAPP)
+
+###############################################################################
+# Top-level Rules
+###############################################################################
+
+objects = $(DL_FILE)
+
+$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
+
+$(DL_FILE)_MD5 = d6a1d5f8ddea3abd2cc3e98f58352d26
+
+install : $(TARGET)
+
+check : $(patsubst %,$(DIR_CHK)/%,$(objects))
+
+download :$(patsubst %,$(DIR_DL)/%,$(objects))
+
+md5 : $(subst %,%_MD5,$(objects))
+
+###############################################################################
+# Downloading, checking, md5sum
+###############################################################################
+
+$(patsubst %,$(DIR_CHK)/%,$(objects)) :
+ @$(CHECK)
+
+$(patsubst %,$(DIR_DL)/%,$(objects)) :
+ @$(LOAD)
+
+$(subst %,%_MD5,$(objects)) :
+ @$(MD5)
+
+###############################################################################
+# Installation Details
+###############################################################################
+
+$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
+ @$(PREBUILD)
+ @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE)
+ cd $(DIR_APP) && ./configure --prefix=/usr
+ cd $(DIR_APP) && make $(MAKETUNING)
+ cd $(DIR_APP) && make install
+ @rm -rf $(DIR_APP)
+ @$(POSTBUILD)
###############################################################################
# #
# IPFire.org - A linux based firewall #
-# Copyright (C) 2007-2015 IPFire Team <info@ipfire.org> #
+# Copyright (C) 2007-2016 IPFire Team <info@ipfire.org> #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
include Config
-VER = 3.14.57
-RPI_PATCHES = 3.14.57-grsec-ipfire1
-A7M_PATCHES = 3.14.57-grsec-ipfire1
-GRS_PATCHES = grsecurity-3.1ipfire-3.14.57-v1.patch.xz
+VER = 3.14.60
+RPI_PATCHES = 3.14.60-grsec-ipfire1
+A7M_PATCHES = 3.14.60-grsec-ipfire1
+GRS_PATCHES = grsecurity-3.1ipfire-3.14.60-v1.patch.xz
THISAPP = linux-$(VER)
CFLAGS =
CXXFLAGS =
-PAK_VER = 64
+PAK_VER = 65
DEPS = ""
KERNEL_ARCH = $(MACHINE)
arm7-multi-patches-$(A7M_PATCHES).patch.xz = $(URL_IPFIRE)/arm7-multi-patches-$(A7M_PATCHES).patch.xz
$(GRS_PATCHES) = $(URL_IPFIRE)/$(GRS_PATCHES)
-$(DL_FILE)_MD5 = b7e254c83a0324852c8ccc4ed1b5377d
-rpi-patches-$(RPI_PATCHES).patch.xz_MD5 = 4ab53e184441c895adf318a1c2874d43
-arm7-multi-patches-$(A7M_PATCHES).patch.xz_MD5 = f29bd5c156384b0a4bb7c6e2c973ea06
-$(GRS_PATCHES)_MD5 = de603c5cb2e38ee308f1647ad3bd24cf
+$(DL_FILE)_MD5 = 25d623a8a884d055313e16aec59fdd7a
+rpi-patches-$(RPI_PATCHES).patch.xz_MD5 = ed11c924a484646018be8671935407d0
+arm7-multi-patches-$(A7M_PATCHES).patch.xz_MD5 = eafe3ef25946d9d5169dd5af4d280ba5
+$(GRS_PATCHES)_MD5 = 1b6941fd7cea95acce6575917ed08a31
install : $(TARGET)
# update the queued trim blacklist from kernel 4.2rc1
cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux-3.14.43_new_qtrim_blacklist.patch
- # HyperV 2008 patch
- cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux-3.14.x-hyperv-2008-fix.patch
+ # Hyper-V patches
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0001-Drivers-net-hyperv-Get-rid-of-the-rndis_filter_packe.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0002-Drivers-net-hyperv-Cleanup-the-receive-path.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0003-Drivers-net-hyperv-Cleanup-the-netvsc-receive-callba.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0004-hyperv-Add-latest-NetVSP-versions-to-auto-negotiatio.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0005-Drivers-net-hyperv-Enable-scatter-gather-I-O.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0006-Drivers-net-hyperv-Cleanup-the-send-path.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0007-Drivers-net-hyperv-Enable-offloads-on-the-host.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0008-Drivers-net-hyperv-Enable-receive-side-IP-checksum-o.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0009-Drivers-net-hyperv-Enable-send-side-checksum-offload.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0010-Drivers-net-hyperv-Enable-large-send-offload.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0011-hyperv-Change-the-receive-buffer-size-for-legacy-hos.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0012-Drivers-net-hyperv-Allocate-memory-for-all-possible-.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0013-Drivers-net-hyperv-Negotiate-suitable-ndis-version-f.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0014-Drivers-net-hyperv-Address-UDP-checksum-issues.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0015-hyperv-Properly-handle-checksum-offload.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0016-hyperv-Add-support-for-virtual-Receive-Side-Scaling-.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0017-hyperv-Remove-recv_pkt_list-and-lock.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0018-hyperv-Simplify-the-send_completion-variables.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0019-hyperv-Enable-sendbuf-mechanism-on-the-send-path.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0020-Add-support-for-netvsc-build-without-CONFIG_SYSFS-fl.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0021-hyperv-Add-hash-value-into-RNDIS-Per-packet-info.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0022-hyperv-fix-apparent-cut-n-paste-error-in-send-path-t.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0023-hyperv-Fix-error-return-code-in-netvsc_init_buf.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0024-hyperv-Fix-a-bug-in-netvsc_send.patch
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux/0025-Drivers-hv-vmbus-Support-per-channel-driver-state.patch
# fix empty symbol crc's
cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/linux-genksyms_fix_typeof_handling.patch
# Apply Arm7-multiarch kernel patches.
cd $(DIR_APP) && xzcat $(DIR_DL)/arm7-multi-patches-$(A7M_PATCHES).patch.xz | patch -Np1
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/arm-multi-grsec-compile-fixes.patch
# Install switch api userspace header
cd $(DIR_APP) && install -v -m644 include/uapi/linux/switch.h /usr/include/linux/
--- /dev/null
+###############################################################################
+# #
+# IPFire.org - A linux based firewall #
+# Copyright (C) 2007 Michael Tremer & Christian Schmidt #
+# #
+# This program is free software: you can redistribute it and/or modify #
+# it under the terms of the GNU General Public License as published by #
+# the Free Software Foundation, either version 3 of the License, or #
+# (at your option) any later version. #
+# #
+# This program is distributed in the hope that it will be useful, #
+# but WITHOUT ANY WARRANTY; without even the implied warranty of #
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
+# GNU General Public License for more details. #
+# #
+# You should have received a copy of the GNU General Public License #
+# along with this program. If not, see <http://www.gnu.org/licenses/>. #
+# #
+###############################################################################
+
+###############################################################################
+# Definitions
+###############################################################################
+
+include Config
+
+VER = 5.3.0
+
+THISAPP = lua-$(VER)
+DL_FILE = $(THISAPP).tar.gz
+DL_FROM = $(URL_IPFIRE)
+DIR_APP = $(DIR_SRC)/$(THISAPP)
+TARGET = $(DIR_INFO)/$(THISAPP)
+
+###############################################################################
+# Top-level Rules
+###############################################################################
+
+objects = $(DL_FILE)
+
+$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
+
+$(DL_FILE)_MD5 = a1b0a7e92d0c85bbff7a8d27bf29f8af
+
+install : $(TARGET)
+
+check : $(patsubst %,$(DIR_CHK)/%,$(objects))
+
+download :$(patsubst %,$(DIR_DL)/%,$(objects))
+
+md5 : $(subst %,%_MD5,$(objects))
+
+###############################################################################
+# Downloading, checking, md5sum
+###############################################################################
+
+$(patsubst %,$(DIR_CHK)/%,$(objects)) :
+ @$(CHECK)
+
+$(patsubst %,$(DIR_DL)/%,$(objects)) :
+ @$(LOAD)
+
+$(subst %,%_MD5,$(objects)) :
+ @$(MD5)
+
+###############################################################################
+# Installation Details
+###############################################################################
+
+$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
+ @$(PREBUILD)
+ @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE)
+ cd $(DIR_APP) && cp -v src/luaconf.h src/luaconf.h.template.in
+ cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/lua-5.3.0-autotoolize.patch
+ cd $(DIR_APP) && autoreconf -vfi
+ cd $(DIR_APP) && ./configure --prefix=/usr
+ cd $(DIR_APP) && make $(MAKETUNING)
+ cd $(DIR_APP) && make install
+ @rm -rf $(DIR_APP)
+ @$(POSTBUILD)
###############################################################################
# #
# IPFire.org - A linux based firewall #
-# Copyright (C) 2015 Michael Tremer & Christian Schmidt #
+# Copyright (C) 2016 Michael Tremer & Christian Schmidt #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
include Config
-VER = 2.5.0
+VER = 2.5.1
THISAPP = nano-$(VER)
DL_FILE = $(THISAPP).tar.gz
DIR_APP = $(DIR_SRC)/$(THISAPP)
TARGET = $(DIR_INFO)/$(THISAPP)
PROG = nano
-PAK_VER = 7
+PAK_VER = 8
DEPS = ""
$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
-$(DL_FILE)_MD5 = 751ed96457017572bab15be18cb873ba
+$(DL_FILE)_MD5 = f25c7da9813ae5f1df7e5dd1072de4ce
install : $(TARGET)
###############################################################################
# #
# IPFire.org - A linux based firewall #
-# Copyright (C) 2015 Michael Tremer & Christian Schmidt #
+# Copyright (C) 2016 Michael Tremer & Christian Schmidt #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
include Config
-VER = 4.2.8p4
+VER = 4.2.8p5
THISAPP = ntp-$(VER)
DL_FILE = $(THISAPP).tar.gz
$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
-$(DL_FILE)_MD5 = 6af96862b09324a8ef965ca76b759c8b
+$(DL_FILE)_MD5 = 9f02b2a0acc1617ce2716d529a58d2d8
install : $(TARGET)
$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
@$(PREBUILD)
@rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar zxf $(DIR_DL)/$(DL_FILE)
- cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/ntp-fix-sycing-with-local-clock.patch
cd $(DIR_APP) && \
./configure \
--prefix=/usr \
###############################################################################
# #
# IPFire.org - A linux based firewall #
-# Copyright (C) 2007-2014 IPFire Team <info@ipfire.org> #
+# Copyright (C) 2015 IPFire Team <info@ipfire.org> #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
include Config
-VER = 2.3.6
+VER = 2.3.7
THISAPP = openvpn-$(VER)
DL_FILE = $(THISAPP).tar.xz
$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
-$(DL_FILE)_MD5 = bcc30c296566df14feebdd8aa0e408ca
+$(DL_FILE)_MD5 = 5b819f7cd0b875f55f20a947224967aa
install : $(TARGET)
include Config
-VER = 7.0.3
+VER = 7.0.11
THISAPP = owncloud-$(VER)
DL_FILE = $(THISAPP).tar.bz2
DIR_APP = $(DIR_SRC)/$(THISAPP)
TARGET = $(DIR_INFO)/$(THISAPP)
PROG = owncloud
-PAK_VER = 4
+PAK_VER = 6
DEPS = ""
$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
-$(DL_FILE)_MD5 = d5d2ad068046e6ddb322cf001a9bb3d5
+$(DL_FILE)_MD5 = 1f4839e43bc910a9acd8700fb9923b3a
install : $(TARGET)
###############################################################################
# #
# IPFire.org - A linux based firewall #
-# Copyright (C) 2007-2013 IPFire Team <info@ipfire.org> #
+# Copyright (C) 2007-2016 IPFire Team <info@ipfire.org> #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
include Config
-VER = 3.1.1
+VER = 3.1.2
THISAPP = rsync-$(VER)
DL_FILE = $(THISAPP).tar.gz
DIR_APP = $(DIR_SRC)/$(THISAPP)
TARGET = $(DIR_INFO)/$(THISAPP)
PROG = rsync
-PAK_VER = 9
+PAK_VER = 10
DEPS = ""
$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
-$(DL_FILE)_MD5 = 43bd6676f0b404326eee2d63be3cdcfe
+$(DL_FILE)_MD5 = 0f758d7e000c0f7f7d3792610fad70cb
install : $(TARGET)
###############################################################################
# #
# IPFire.org - A linux based firewall #
-# Copyright (C) 2007 Michael Tremer & Christian Schmidt #
+# Copyright (C) 2016 Michael Tremer & Christian Schmidt #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
include Config
-VER = 4.2.1
+VER = 4.2.2
THISAPP = sed-$(VER)
DL_FILE = $(THISAPP).tar.gz
$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
-$(DL_FILE)_MD5 = f0fd4d7da574d4707e442285fd2d3b86
+$(DL_FILE)_MD5 = 4111de4faa3b9848a0686b2f260c5056
install : $(TARGET)
@$(PREBUILD)
@rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar xaf $(DIR_DL)/$(DL_FILE)
cd $(DIR_APP) && patch -Np0 -i $(DIR_SRC)/src/patches/squid-3.4-13228.patch
+ cd $(DIR_APP) && patch -Np0 -i $(DIR_SRC)/src/patches/squid-3.4.14-fix-max-file-descriptors.patch
+ cd $(DIR_APP) && patch -Np0 -i $(DIR_SRC)/src/patches/squid-3.4-13230.patch
+ cd $(DIR_APP) && autoreconf -vfi
+ cd $(DIR_APP)/libltdl && autoreconf -vfi
+
cd $(DIR_APP) && ./configure \
--prefix=/usr \
--sysconfdir=/etc/squid \
###############################################################################
# #
# IPFire.org - A linux based firewall #
-# Copyright (C) 2007-2011 IPFire Team <info@ipfire.org> #
+# Copyright (C) 2007-2016 IPFire Team <info@ipfire.org> #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
include Config
-VER = 2015d
+VER = 2016a
TZDATA_VER = $(VER)
TZCODE_VER = $(VER)
tzdata$(TZDATA_VER).tar.gz = $(DL_FROM)/tzdata$(TZDATA_VER).tar.gz
tzcode$(TZCODE_VER).tar.gz = $(DL_FROM)/tzcode$(TZCODE_VER).tar.gz
-tzdata$(TZDATA_VER).tar.gz_MD5 = b595bdc4474b8fc1a15cffc67c66025b
-tzcode$(TZCODE_VER).tar.gz_MD5 = 4008a3abc025a398697b2587c48258b9
+tzdata$(TZDATA_VER).tar.gz_MD5 = 0d3123eb1b453ec0620822bd65be4c42
+tzcode$(TZCODE_VER).tar.gz_MD5 = f5e0299925631da7cf82d8ce1205111d
install : $(TARGET)
NAME="IPFire" # Software name
SNAME="ipfire" # Short name
VERSION="2.17" # Version number
-CORE="98" # Core Level (Filename)
+CORE="99" # Core Level (Filename)
PAKFIRE_CORE="98" # Core Level (PAKFIRE)
GIT_BRANCH=`git rev-parse --abbrev-ref HEAD` # Git Branch
SLOGAN="www.ipfire.org" # Software slogan
KVER=`grep --max-count=1 VER lfs/linux | awk '{ print $3 }'`
GIT_TAG=$(git tag | tail -1) # Git Tag
GIT_LASTCOMMIT=$(git log | head -n1 | cut -d" " -f2 |head -c8) # Last commit
-TOOLCHAINVER=10
+TOOLCHAINVER=11
# New architecture variables
BUILD_ARCH="$(uname -m)"
# Run LFS static binary creation scripts one by one
export CCACHE_DIR=$BASEDIR/ccache
export CCACHE_COMPRESS=1
- export CCACHE_COMPILERCHECK="string:toolchain-${TOOLCHAINVER}:${TARGET_ARCH}"
+ export CCACHE_COMPILERCHECK="string:toolchain-${TOOLCHAINVER} ${TARGET_ARCH}"
# Remove pre-install list of installed files in case user erase some files before rebuild
rm -f $BASEDIR/build/usr/src/lsalr 2>/dev/null
lfsmake1 linux TOOLS=1 KCFG="-headers"
lfsmake1 glibc
lfsmake1 cleanup-toolchain PASS=1
+ lfsmake1 gcc PASS=L
lfsmake1 binutils PASS=2
lfsmake1 gcc PASS=2
lfsmake1 ccache PASS=2
lfsmake2 gmp
lfsmake2 gmp-compat
lfsmake2 mpfr
+ lfsmake2 libmpc
lfsmake2 file
lfsmake2 gcc
lfsmake2 sed
ipfiremake streamripper
ipfiremake sshfs
ipfiremake taglib
- ipfiremake mediatomb
+ #ipfiremake mediatomb
ipfiremake sslh
ipfiremake perl-gettext
ipfiremake perl-Sort-Naturally
ipfiremake swconfig
ipfiremake haproxy
ipfiremake ipset
+ ipfiremake lua
+ ipfiremake dnsdist
}
buildinstaller() {
--- /dev/null
+#!/bin/sh
+########################################################################
+# Begin $rc_base/init.d/dnsdist
+#
+# Description : dnsdist - A DNS load-balancer and more
+#
+########################################################################
+
+. /etc/sysconfig/rc
+. ${rc_functions}
+
+[ -r "/etc/sysconfig/dnsdist" ] && . /etc/sysconfig/dnsdist
+
+case "${1}" in
+ start)
+ boot_mesg "Starting dnsdist..."
+ loadproc /usr/bin/dnsdist -d ${ARGS}
+ ;;
+
+ stop)
+ boot_mesg "Stopping dnsdist..."
+ killproc /usr/bin/dnsdist
+ ;;
+
+ reload)
+ boot_mesg "Reloading dnsdist..."
+ reloadproc /usr/bin/dnsdist
+ ;;
+
+ restart)
+ ${0} stop
+ sleep 1
+ ${0} start
+ ;;
+
+ status)
+ statusproc /usr/bin/dnsdist
+ ;;
+
+ *)
+ echo "Usage: ${0} {start|stop|reload|restart|status}"
+ exit 1
+ ;;
+esac
+
+# End $rc_base/init.d/dnsdist
iptables -F
iptables -t nat -F
iptables -t mangle -F
+ iptables -t raw -F
iptables -X
iptables -t nat -X
iptables -t mangle -X
+ iptables -t raw -X
# Set up policies
iptables -P INPUT DROP
iptables -A INPUT -p tcp -j BADTCP
iptables -A FORWARD -p tcp -j BADTCP
- # Connection tracking chain
+ # Connection tracking chains
iptables -N CONNTRACK
- iptables -A CONNTRACK -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT
+ iptables -A CONNTRACK -m conntrack --ctstate ESTABLISHED -j ACCEPT
iptables -A CONNTRACK -m conntrack --ctstate INVALID -j DROP
+ iptables -A CONNTRACK -p icmp -m conntrack --ctstate RELATED -j ACCEPT
+ iptables -t raw -N CONNTRACK
+ iptables -t raw -A PREROUTING -j CONNTRACK
+
+ # Conntrack helpers (https://home.regit.org/netfilter-en/secure-use-of-helpers/)
+
+ # SIP
+ if [ "${CONNTRACK_SIP}" = "on" ]; then
+ iptables -A CONNTRACK -m conntrack --ctstate RELATED \
+ -m helper --helper sip -j ACCEPT
+ for proto in udp tcp; do
+ iptables -t raw -A CONNTRACK -p "${proto}" --dport 5060 -j CT --helper sip
+ done
+ fi
+
+ # H.323
+ if [ "${CONNTRACK_H323}" = "on" ]; then
+ iptables -A CONNTRACK -m conntrack --ctstate RELATED \
+ -m helper --helper h323 -j ACCEPT
+
+ # Gatekeeper RAS
+ iptables -t raw -A CONNTRACK -p udp --dport 1719 -j CT --helper RAS
+
+ # Q.931
+ iptables -t raw -A CONNTRACK -p tcp --dport 1720 -j CT --helper Q.931
+ fi
+
+ # FTP
+ if [ "${CONNTRACK_FTP}" = "on" ]; then
+ iptables -A CONNTRACK -m conntrack --ctstate RELATED \
+ -m helper --helper ftp -p tcp --dport 1024: -j ACCEPT
+ iptables -t raw -A CONNTRACK -p tcp --dport 21 -j CT --helper ftp
+ fi
+
+ # PPTP
+ if [ "${CONNTRACK_PPTP}" = "on" ]; then
+ iptables -A CONNTRACK -m conntrack --ctstate RELATED \
+ -m helper --helper pptp -j ACCEPT
+ iptables -t raw -A CONNTRACK -p udp --dport 1723 -j CT --helper pptp
+ fi
+
+ # TFTP
+ if [ "${CONNTRACK_TFTP}" = "on" ]; then
+ iptables -A CONNTRACK -m conntrack --ctstate RELATED \
+ -m helper --helper tftp -j ACCEPT
+ iptables -t raw -A CONNTRACK -p udp --dport 69 -j CT --helper tftp
+ fi
+
+ # IRC
+ if [ "${CONNTRACK_IRC}" = "on" ]; then
+ iptables -A CONNTRACK -m conntrack --ctstate RELATED \
+ -m helper --helper irc -j ACCEPT
+ iptables -t raw -A CONNTRACK -p tcp --dport 6667 -j CT --helper irc
+ fi
+
+ # Amanda
+ if [ "${CONNTRACK_AMANDA}" = "on" ]; then
+ iptables -A CONNTRACK -m conntrack --ctstate RELATED \
+ -m helper --helper amanda -j ACCEPT
+ iptables -t raw -A CONNTRACK -p tcp -j CT --helper amanda
+ fi
# Fix for braindead ISP's
iptables -A FORWARD -p tcp --tcp-flags SYN,RST SYN -j TCPMSS --clamp-mss-to-pmtu
# See how we were called.
case "$1" in
start)
- boot_mesg "Loading firewall modules into the kernel"
- modprobe iptable_nat || failed=1
- for i in $(find /lib/modules/$(uname -r) -name nf_conntrack*); do
- modprobe $(basename $i | cut -d. -f1) || failed=1
- done
- for i in $(find /lib/modules/$(uname -r) -name nf_nat*); do
- modprobe $(basename $i | cut -d. -f1) || failed=1
- done
- (exit ${failed})
- evaluate_retval
-
- if [ -e /var/ipfire/main/disable_nf_sip ]; then
- rmmod nf_nat_sip
- rmmod nf_conntrack_sip
- rmmod nf_nat_h323
- rmmod nf_conntrack_h323
- fi
-
boot_mesg "Setting up firewall"
iptables_init
evaluate_retval
# Only if RED_TYPE=DHCP update /var/ipfire/red
if [ "$RED_TYPE" == "DHCP" ]; then
- #Force MTU option for KabelDeutschland because this ISP
- #set the MTU to 576 instead of the supportet 1500
- if [ $RED_DHCP_FORCE_MTU -ge 576 ]; then
- logger -p local0.info -t dhcpcd.exe[$$] "Force mtu to $RED_DHCP_FORCE_MTU"
- ip link set $interface mtu $RED_DHCP_FORCE_MTU
- fi
-
#Check if we have to restart the services at update
[ ! -e "/var/ipfire/red/active" ] && update=1;
if [ "$old_domain_name_service" != "$new_domain_name_service" ]; then
#include <sys/types.h>
#include <fcntl.h>
#include "setuid.h"
+#include "libsmooth.h"
-int main(int argc, char *argv[]) {
+#define QOS_SH "/var/ipfire/qos/bin/qos.sh"
+int main(int argc, char *argv[]) {
+ struct keyvalue* kv = NULL;
int fd = -1;
+ int r = 0;
if (!(initsetuid()))
exit(1);
}
if (strcmp(argv[1], "generate") == 0) {
- safe_system("/usr/bin/perl /var/ipfire/qos/bin/makeqosscripts.pl > /var/ipfire/qos/bin/qos.sh");
+ kv = initkeyvalues();
+ if (!readkeyvalues(kv, CONFIG_ROOT "/qos/settings")) {
+ fprintf(stderr, "Cannot read QoS settings\n");
+ r = 1;
+ goto END;
+ }
+
+ char enabled[STRING_SIZE];
+ if (!findkey(kv, "ENABLED", enabled))
+ strcpy(enabled, "off");
+
+ if (strcmp(enabled, "on") == 0)
+ safe_system("/usr/bin/perl /var/ipfire/qos/bin/makeqosscripts.pl > " QOS_SH);
+ else
+ unlink(QOS_SH);
}
- if ((fd = open("/var/ipfire/qos/bin/qos.sh", O_RDONLY)) != -1) {
+ if ((fd = open(QOS_SH, O_RDONLY)) != -1) {
close(fd);
} else {
// If there is no qos.sh do nothing.
- exit(0);
+ goto END;
}
- safe_system("chmod 755 /var/ipfire/qos/bin/qos.sh &>/dev/null");
+ safe_system("chmod 755 " QOS_SH " &>/dev/null");
if (strcmp(argv[1], "start") == 0) {
- safe_system("/var/ipfire/qos/bin/qos.sh start");
+ safe_system(QOS_SH " start");
} else if (strcmp(argv[1], "stop") == 0) {
- safe_system("/var/ipfire/qos/bin/qos.sh clear");
+ safe_system(QOS_SH " clear");
} else if (strcmp(argv[1], "status") == 0) {
- safe_system("/var/ipfire/qos/bin/qos.sh status");
+ safe_system(QOS_SH " status");
} else if (strcmp(argv[1], "restart") == 0) {
- safe_system("/var/ipfire/qos/bin/qos.sh restart");
+ safe_system(QOS_SH " restart");
} else {
if (strcmp(argv[1], "generate") == 0) {exit(0);}
fprintf(stderr, "\nBad argument given.\n\nqosctrl (start|stop|restart|status|generate)\n\n");
exit(1);
}
- return 0;
+END:
+ if (kv)
+ freekeyvalues(kv);
+
+ return r;
}
safe_system("ln -fs ../init.d/ntp /etc/rc.d/rc6.d/K46ntpd >/dev/null 2>&1");
safe_system("/etc/rc.d/init.d/ntp start");
} else if (strcmp(argv[1], "disable") == 0) {
- safe_system("/etc/rc.d/init.d/ntpd stop");
+ safe_system("/etc/rc.d/init.d/ntp stop");
safe_system("rm -f /etc/rc.d/rc*.d/*ntpd >/dev/null 2>&1");
} else {
fprintf(stderr, "\nBad argument given.\n\ntimectrl (start|stop|restart)\n\n");
}
int main(void) {
- char green_dev[STRING_SIZE] = "";
char buffer[STRING_SIZE];
char *index, *ipaddress, *macaddress, *enabled;
struct keyvalue *kv = NULL;
exit(1);
}
- /* Get the GREEN interface details */
- if (findkey(kv, "GREEN_DEV", green_dev) > 0) {
- if (!VALID_DEVICE(green_dev)) {
- fprintf(stderr, "Bad GREEN_DEV: %s\n", green_dev);
- exit(1);
- }
- }
-
/* Get the BLUE interface details */
if (findkey(kv, "BLUE_DEV", blue_dev) > 0) {
if ((strlen(blue_dev) > 0) && !VALID_DEVICE(blue_dev)) {
if (strcmp(enabled, "on") == 0) {
/* both specified, added security */
if ((strlen(macaddress) == 17) && (VALID_IP_AND_MASK(ipaddress))) {
- snprintf(command, STRING_SIZE-1, "/sbin/iptables --wait -A WIRELESSINPUT -m mac --mac-source %s -s %s -i %s -j ACCEPT", macaddress, ipaddress, blue_dev);
+ snprintf(command, STRING_SIZE-1, "/sbin/iptables --wait -A WIRELESSINPUT -m mac --mac-source %s -s %s -i %s -j RETURN", macaddress, ipaddress, blue_dev);
safe_system(command);
snprintf(command, STRING_SIZE-1, "/sbin/iptables --wait -A WIRELESSFORWARD -m mac --mac-source %s -s %s -i %s -j RETURN", macaddress, ipaddress, blue_dev);
safe_system(command);
} else {
/* correctly formed mac address is 17 chars */
if (strlen(macaddress) == 17) {
- snprintf(command, STRING_SIZE-1, "/sbin/iptables --wait -A WIRELESSINPUT -m mac --mac-source %s -i %s -j ACCEPT", macaddress, blue_dev);
+ snprintf(command, STRING_SIZE-1, "/sbin/iptables --wait -A WIRELESSINPUT -m mac --mac-source %s -i %s -j RETURN", macaddress, blue_dev);
safe_system(command);
snprintf(command, STRING_SIZE-1, "/sbin/iptables --wait -A WIRELESSFORWARD -m mac --mac-source %s -i %s -j RETURN", macaddress, blue_dev);
safe_system(command);
}
if (VALID_IP_AND_MASK(ipaddress)) {
- snprintf(command, STRING_SIZE-1, "/sbin/iptables --wait -A WIRELESSINPUT -s %s -i %s -j ACCEPT", ipaddress, blue_dev);
+ snprintf(command, STRING_SIZE-1, "/sbin/iptables --wait -A WIRELESSINPUT -s %s -i %s -j RETURN", ipaddress, blue_dev);
safe_system(command);
snprintf(command, STRING_SIZE-1, "/sbin/iptables --wait -A WIRELESSFORWARD -s %s -i %s -j RETURN", ipaddress, blue_dev);
safe_system(command);
--- /dev/null
+--- a/arch/arm/mach-omap2/cclock3xxx_data.c~ 2015-12-12 11:00:10.474423373 +0000
++++ b/arch/arm/mach-omap2/cclock3xxx_data.c 2015-12-12 11:30:31.198452547 +0000
+@@ -250,7 +250,7 @@
+
+ static struct clk dpll1_ck;
+
+-static struct clk_ops dpll1_ck_ops;
++static clk_ops_no_const dpll1_ck_ops;
+
+ static struct clk_ops dpll1_ck_ops_34xx __initdata = {
+ .init = &omap2_init_clk_clkdm,
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/asix_common.c backports-3.18.1-1/drivers/net/usb/asix_common.c
---- backports-3.18.1-1.org/drivers/net/usb/asix_common.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/asix_common.c 2014-12-16 18:39:45.000000000 +0100
-@@ -0,0 +1,582 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/asix_common.c backports-4.2.6-1/drivers/net/usb/asix_common.c
+--- backports-4.2.6-1.org/drivers/net/usb/asix_common.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/asix_common.c 2015-11-09 23:37:56.000000000 +0100
+@@ -0,0 +1,584 @@
+/*
+ * ASIX AX8817X based USB 2.0 Ethernet Devices
+ * Copyright (C) 2003-2006 David Hollis <dhollis@davehollis.com>
+ memcpy(skb_tail_pointer(skb), &padbytes, sizeof(padbytes));
+ skb_put(skb, sizeof(padbytes));
+ }
++
++ usbnet_set_skb_tx_stats(skb, 1, 0);
+ return skb;
+}
+
+
+ return 0;
+}
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/asix_devices.c backports-3.18.1-1/drivers/net/usb/asix_devices.c
---- backports-3.18.1-1.org/drivers/net/usb/asix_devices.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/asix_devices.c 2014-12-16 18:39:45.000000000 +0100
-@@ -0,0 +1,1104 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/asix_devices.c backports-4.2.6-1/drivers/net/usb/asix_devices.c
+--- backports-4.2.6-1.org/drivers/net/usb/asix_devices.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/asix_devices.c 2015-11-09 23:37:56.000000000 +0100
+@@ -0,0 +1,1107 @@
+/*
+ * ASIX AX8817X based USB 2.0 Ethernet Devices
+ * Copyright (C) 2003-2006 David Hollis <dhollis@davehollis.com>
+
+static void ax88772_unbind(struct usbnet *dev, struct usb_interface *intf)
+{
-+ if (dev->driver_priv)
-+ kfree(dev->driver_priv);
++ kfree(dev->driver_priv);
+}
+
+static const struct ethtool_ops ax88178_ethtool_ops = {
+ USB_DEVICE (0x0df6, 0x0056),
+ .driver_info = (unsigned long) &ax88178_info,
+}, {
++ // Sitecom LN-028 "USB 2.0 10/100/1000 Ethernet adapter"
++ USB_DEVICE (0x0df6, 0x061c),
++ .driver_info = (unsigned long) &ax88178_info,
++}, {
+ // corega FEther USB2-TX
+ USB_DEVICE (0x07aa, 0x0017),
+ .driver_info = (unsigned long) &ax8817x_info,
+MODULE_DESCRIPTION("ASIX AX8817X based USB 2.0 Ethernet Devices");
+MODULE_LICENSE("GPL");
+
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/asix.h backports-3.18.1-1/drivers/net/usb/asix.h
---- backports-3.18.1-1.org/drivers/net/usb/asix.h 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/asix.h 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/asix.h backports-4.2.6-1/drivers/net/usb/asix.h
+--- backports-4.2.6-1.org/drivers/net/usb/asix.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/asix.h 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,234 @@
+/*
+ * ASIX AX8817X based USB 2.0 Ethernet Devices
+int asix_set_mac_address(struct net_device *net, void *p);
+
+#endif /* _ASIX_H */
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/ax88172a.c backports-3.18.1-1/drivers/net/usb/ax88172a.c
---- backports-3.18.1-1.org/drivers/net/usb/ax88172a.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/ax88172a.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/ax88172a.c backports-4.2.6-1/drivers/net/usb/ax88172a.c
+--- backports-4.2.6-1.org/drivers/net/usb/ax88172a.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/ax88172a.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,422 @@
+/*
+ * ASIX AX88172A based USB 2.0 Ethernet Devices
+ .rx_fixup = ax88172a_rx_fixup,
+ .tx_fixup = asix_tx_fixup,
+};
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/ax88179_178a.c backports-3.18.1-1/drivers/net/usb/ax88179_178a.c
---- backports-3.18.1-1.org/drivers/net/usb/ax88179_178a.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/ax88179_178a.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/ax88179_178a.c backports-4.2.6-1/drivers/net/usb/ax88179_178a.c
+--- backports-4.2.6-1.org/drivers/net/usb/ax88179_178a.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/ax88179_178a.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,1756 @@
+/*
+ * ASIX AX88179/178A USB 3.0/2.0 to Gigabit Ethernet Devices
+
+MODULE_DESCRIPTION("ASIX AX88179/178A based USB 3.0/2.0 Gigabit Ethernet Devices");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/catc.c backports-3.18.1-1/drivers/net/usb/catc.c
---- backports-3.18.1-1.org/drivers/net/usb/catc.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/catc.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/catc.c backports-4.2.6-1/drivers/net/usb/catc.c
+--- backports-4.2.6-1.org/drivers/net/usb/catc.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/catc.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,965 @@
+/*
+ * Copyright (c) 2001 Vojtech Pavlik
+ u8 broadcast[ETH_ALEN];
+ u8 rx = RxEnable | RxPolarity | RxMultiCast;
+
-+ memset(broadcast, 0xff, ETH_ALEN);
++ eth_broadcast_addr(broadcast);
+ memset(catc->multicast, 0, 64);
+
+ catc_multicast(broadcast, catc->multicast);
+
+ dev_dbg(dev, "Filling the multicast list.\n");
+
-+ memset(broadcast, 0xff, ETH_ALEN);
++ eth_broadcast_addr(broadcast);
+ catc_multicast(broadcast, catc->multicast);
+ catc_multicast(netdev->dev_addr, catc->multicast);
+ catc_write_mem(catc, 0xfa80, catc->multicast, 64);
+};
+
+module_usb_driver(catc_driver);
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/cdc_eem.c backports-3.18.1-1/drivers/net/usb/cdc_eem.c
---- backports-3.18.1-1.org/drivers/net/usb/cdc_eem.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/cdc_eem.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/cdc_eem.c backports-4.2.6-1/drivers/net/usb/cdc_eem.c
+--- backports-4.2.6-1.org/drivers/net/usb/cdc_eem.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/cdc_eem.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,381 @@
+/*
+ * USB CDC EEM network interface driver
+MODULE_AUTHOR("Omar Laazimani <omar.oberthur@gmail.com>");
+MODULE_DESCRIPTION("USB CDC EEM");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/cdc-phonet.c backports-3.18.1-1/drivers/net/usb/cdc-phonet.c
---- backports-3.18.1-1.org/drivers/net/usb/cdc-phonet.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/cdc-phonet.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/cdc-phonet.c backports-4.2.6-1/drivers/net/usb/cdc-phonet.c
+--- backports-4.2.6-1.org/drivers/net/usb/cdc-phonet.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/cdc-phonet.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,466 @@
+/*
+ * phonet.c -- USB CDC Phonet host driver
+ struct page *page;
+ int err;
+
-+ page = __skb_alloc_page(gfp_flags | __GFP_NOMEMALLOC, NULL);
++ page = __dev_alloc_page(gfp_flags | __GFP_NOMEMALLOC);
+ if (!page)
+ return -ENOMEM;
+
+ if (page)
+ put_page(page);
+ if (req)
-+ rx_submit(pnd, req, GFP_ATOMIC | __GFP_COLD);
++ rx_submit(pnd, req, GFP_ATOMIC);
+}
+
+static int usbpn_close(struct net_device *dev);
+ for (i = 0; i < rxq_size; i++) {
+ struct urb *req = usb_alloc_urb(0, GFP_KERNEL);
+
-+ if (!req || rx_submit(pnd, req, GFP_KERNEL | __GFP_COLD)) {
++ if (!req || rx_submit(pnd, req, GFP_KERNEL)) {
+ usb_free_urb(req);
+ usbpn_close(dev);
+ return -ENOMEM;
+MODULE_AUTHOR("Remi Denis-Courmont");
+MODULE_DESCRIPTION("USB CDC Phonet host interface");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/cdc_subset.c backports-3.18.1-1/drivers/net/usb/cdc_subset.c
---- backports-3.18.1-1.org/drivers/net/usb/cdc_subset.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/cdc_subset.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/cdc_subset.c backports-4.2.6-1/drivers/net/usb/cdc_subset.c
+--- backports-4.2.6-1.org/drivers/net/usb/cdc_subset.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/cdc_subset.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,369 @@
+/*
+ * Simple "CDC Subset" USB Networking Links
+MODULE_AUTHOR("David Brownell");
+MODULE_DESCRIPTION("Simple 'CDC Subset' USB networking links");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/cx82310_eth.c backports-3.18.1-1/drivers/net/usb/cx82310_eth.c
---- backports-3.18.1-1.org/drivers/net/usb/cx82310_eth.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/cx82310_eth.c 2014-12-16 18:39:45.000000000 +0100
-@@ -0,0 +1,326 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/cx82310_eth.c backports-4.2.6-1/drivers/net/usb/cx82310_eth.c
+--- backports-4.2.6-1.org/drivers/net/usb/cx82310_eth.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/cx82310_eth.c 2015-11-09 23:37:56.000000000 +0100
+@@ -0,0 +1,353 @@
+/*
+ * Driver for USB ethernet port of Conexant CX82310-based ADSL routers
+ * Copyright (C) 2010 by Ondrej Zary
+};
+
+#define CMD_PACKET_SIZE 64
-+/* first command after power on can take around 8 seconds */
-+#define CMD_TIMEOUT 15000
++#define CMD_TIMEOUT 100
+#define CMD_REPLY_RETRY 5
+
+#define CX82310_MTU 1514
+ ret = usb_bulk_msg(udev, usb_sndbulkpipe(udev, CMD_EP), buf,
+ CMD_PACKET_SIZE, &actual_len, CMD_TIMEOUT);
+ if (ret < 0) {
-+ dev_err(&dev->udev->dev, "send command %#x: error %d\n",
-+ cmd, ret);
++ if (cmd != CMD_GET_LINK_STATUS)
++ dev_err(&dev->udev->dev, "send command %#x: error %d\n",
++ cmd, ret);
+ goto end;
+ }
+
+ buf, CMD_PACKET_SIZE, &actual_len,
+ CMD_TIMEOUT);
+ if (ret < 0) {
-+ dev_err(&dev->udev->dev,
-+ "reply receive error %d\n", ret);
++ if (cmd != CMD_GET_LINK_STATUS)
++ dev_err(&dev->udev->dev,
++ "reply receive error %d\n",
++ ret);
+ goto end;
+ }
+ if (actual_len > 0)
+ int ret;
+ char buf[15];
+ struct usb_device *udev = dev->udev;
++ u8 link[3];
++ int timeout = 50;
+
+ /* avoid ADSL modems - continue only if iProduct is "USB NET CARD" */
+ if (usb_string(udev, udev->descriptor.iProduct, buf, sizeof(buf)) > 0
+ if (!dev->partial_data)
+ return -ENOMEM;
+
++ /* wait for firmware to become ready (indicated by the link being up) */
++ while (--timeout) {
++ ret = cx82310_cmd(dev, CMD_GET_LINK_STATUS, true, NULL, 0,
++ link, sizeof(link));
++ /* the command can time out during boot - it's not an error */
++ if (!ret && link[0] == 1 && link[2] == 1)
++ break;
++ msleep(500);
++ }
++ if (!timeout) {
++ dev_err(&udev->dev, "firmware not ready in time\n");
++ return -ETIMEDOUT;
++ }
++
+ /* enable ethernet mode (?) */
+ ret = cx82310_cmd(dev, CMD_ETHERNET_MODE, true, "\x01", 1, NULL, 0);
+ if (ret) {
+ .tx_fixup = cx82310_tx_fixup,
+};
+
++#define USB_DEVICE_CLASS(vend, prod, cl, sc, pr) \
++ .match_flags = USB_DEVICE_ID_MATCH_DEVICE | \
++ USB_DEVICE_ID_MATCH_DEV_INFO, \
++ .idVendor = (vend), \
++ .idProduct = (prod), \
++ .bDeviceClass = (cl), \
++ .bDeviceSubClass = (sc), \
++ .bDeviceProtocol = (pr)
++
+static const struct usb_device_id products[] = {
+ {
-+ USB_DEVICE_AND_INTERFACE_INFO(0x0572, 0xcb01, 0xff, 0, 0),
++ USB_DEVICE_CLASS(0x0572, 0xcb01, 0xff, 0, 0),
+ .driver_info = (unsigned long) &cx82310_info
+ },
+ { },
+MODULE_AUTHOR("Ondrej Zary");
+MODULE_DESCRIPTION("Conexant CX82310-based ADSL router USB ethernet driver");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/dm9601.c backports-3.18.1-1/drivers/net/usb/dm9601.c
---- backports-3.18.1-1.org/drivers/net/usb/dm9601.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/dm9601.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/dm9601.c backports-4.2.6-1/drivers/net/usb/dm9601.c
+--- backports-4.2.6-1.org/drivers/net/usb/dm9601.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/dm9601.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,647 @@
+/*
+ * Davicom DM96xx USB 10/100Mbps ethernet devices
+MODULE_AUTHOR("Peter Korsgaard <jacmet@sunsite.dk>");
+MODULE_DESCRIPTION("Davicom DM96xx USB 10/100 ethernet devices");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/gl620a.c backports-3.18.1-1/drivers/net/usb/gl620a.c
---- backports-3.18.1-1.org/drivers/net/usb/gl620a.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/gl620a.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/gl620a.c backports-4.2.6-1/drivers/net/usb/gl620a.c
+--- backports-4.2.6-1.org/drivers/net/usb/gl620a.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/gl620a.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,242 @@
+/*
+ * GeneSys GL620USB-A based links
+MODULE_DESCRIPTION("GL620-USB-A Host-to-Host Link cables");
+MODULE_LICENSE("GPL");
+
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/hso.c backports-3.18.1-1/drivers/net/usb/hso.c
---- backports-3.18.1-1.org/drivers/net/usb/hso.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/hso.c 2015-01-03 13:42:25.000000000 +0100
-@@ -0,0 +1,3326 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/hso.c backports-4.2.6-1/drivers/net/usb/hso.c
+--- backports-4.2.6-1.org/drivers/net/usb/hso.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/hso.c 2016-01-27 15:03:25.000000000 +0100
+@@ -0,0 +1,3322 @@
+/******************************************************************************
+ *
+ * Driver for Option High Speed Mobile Devices.
+#include <linux/module.h>
+#include <linux/ethtool.h>
+#include <linux/usb.h>
-+#include <linux/timer.h>
+#include <linux/tty.h>
+#include <linux/tty_driver.h>
+#include <linux/tty_flip.h>
+ struct hso_device *parent;
+ struct net_device *net;
+ struct rfkill *rfkill;
++ char name[24];
+
+ struct usb_endpoint_descriptor *in_endp;
+ struct usb_endpoint_descriptor *out_endp;
+ u8 usb_gone;
+ struct work_struct async_get_intf;
+ struct work_struct async_put_intf;
-+ struct work_struct reset_device;
+
+ struct usb_device *usb;
+ struct usb_interface *interface;
+static int hso_put_activity(struct hso_device *hso_dev);
+static int hso_get_activity(struct hso_device *hso_dev);
+static void tiocmget_intr_callback(struct urb *urb);
-+static void reset_device(struct work_struct *data);
+/*****************************************************************************/
+/* Helping functions */
+/*****************************************************************************/
+}
+static DEVICE_ATTR(hsotype, S_IRUGO, hso_sysfs_show_porttype, NULL);
+
++static struct attribute *hso_serial_dev_attrs[] = {
++ &dev_attr_hsotype.attr,
++ NULL
++};
++
++ATTRIBUTE_GROUPS(hso_serial_dev);
++
+static int hso_urb_to_index(struct hso_serial *serial, struct urb *urb)
+{
+ int idx;
+ case -ETIMEDOUT:
+ explanation = "protocol error";
+ if (hso_dev)
-+ schedule_work(&hso_dev->reset_device);
++ usb_queue_reset_device(hso_dev->interface);
+ break;
+ default:
+ explanation = "unknown status";
+ /* We got no receive buffer. */
+ D1("could not allocate memory");
+ odev->rx_parse_state = WAIT_SYNC;
-+ return;
++ continue;
+ }
+
+ /* Copy what we got so far. make room for iphdr
+ goto err_out;
+
+ D1("Opening %d", serial->minor);
-+ kref_get(&serial->parent->ref);
+
+ /* setup */
+ tty->driver_data = serial;
+ if (result) {
+ hso_stop_serial_device(serial->parent);
+ atomic_dec(&serial->port.count);
-+ kref_put(&serial->parent->ref, hso_serial_ref_free);
++ } else {
++ kref_get(&serial->parent->ref);
+ }
+ } else {
+ D1("Port was already open");
+ usb_autopm_put_interface(serial->parent->interface);
+
+ mutex_unlock(&serial->parent->mutex);
-+
-+ kref_put(&serial->parent->ref, hso_serial_ref_free);
+}
+
+/* close the requested serial port */
+ return room;
+}
+
++static void hso_serial_cleanup(struct tty_struct *tty)
++{
++ struct hso_serial *serial = tty->driver_data;
++
++ if (!serial)
++ return;
++
++ kref_put(&serial->parent->ref, hso_serial_ref_free);
++}
++
+/* setup the term */
+static void hso_serial_set_termios(struct tty_struct *tty, struct ktermios *old)
+{
+ struct uart_icount *icount;
+ struct hso_serial_state_notification *serial_state_notification;
+ struct usb_device *usb;
++ struct usb_interface *interface;
+ int if_num;
+
+ /* Sanity checks */
+ BUG_ON((serial->parent->port_spec & HSO_PORT_MASK) != HSO_PORT_MODEM);
+
+ usb = serial->parent->usb;
-+ if_num = serial->parent->interface->altsetting->desc.bInterfaceNumber;
++ interface = serial->parent->interface;
++
++ if_num = interface->cur_altsetting->desc.bInterfaceNumber;
+
+ /* wIndex should be the USB interface number of the port to which the
+ * notification applies, which should always be the Modem port.
+ }
+ cprev = cnow;
+ }
-+ current->state = TASK_RUNNING;
++ __set_current_state(TASK_RUNNING);
+ remove_wait_queue(&tiocmget->waitq, &wait);
+
+ return ret;
+ unsigned long flags;
+ int if_num;
+ struct hso_serial *serial = tty->driver_data;
++ struct usb_interface *interface;
+
+ /* sanity check */
+ if (!serial) {
+ if ((serial->parent->port_spec & HSO_PORT_MASK) != HSO_PORT_MODEM)
+ return -EINVAL;
+
-+ if_num = serial->parent->interface->altsetting->desc.bInterfaceNumber;
++ interface = serial->parent->interface;
++ if_num = interface->cur_altsetting->desc.bInterfaceNumber;
+
+ spin_lock_irqsave(&serial->serial_lock, flags);
+ if (set & TIOCM_RTS)
+
+ for (i = 0; i < serial->num_rx_urbs; i++) {
+ if (serial->rx_urb[i]) {
-+ usb_kill_urb(serial->rx_urb[i]);
-+ serial->rx_urb_filled[i] = 0;
++ usb_kill_urb(serial->rx_urb[i]);
++ serial->rx_urb_filled[i] = 0;
+ }
+ }
+ serial->curr_rx_urb_idx = 0;
+ return 0;
+}
+
++static void hso_serial_tty_unregister(struct hso_serial *serial)
++{
++ tty_unregister_device(tty_drv, serial->minor);
++}
++
+static void hso_serial_common_free(struct hso_serial *serial)
+{
+ int i;
+
-+ if (serial->parent->dev)
-+ device_remove_file(serial->parent->dev, &dev_attr_hsotype);
-+
-+ tty_unregister_device(tty_drv, serial->minor);
-+
+ for (i = 0; i < serial->num_rx_urbs; i++) {
+ /* unlink and free RX URB */
+ usb_free_urb(serial->rx_urb[i]);
+
+ /* unlink and free TX URB */
+ usb_free_urb(serial->tx_urb);
++ kfree(serial->tx_buffer);
+ kfree(serial->tx_data);
+ tty_port_destroy(&serial->port);
+}
+ goto exit;
+
+ /* register our minor number */
-+ serial->parent->dev = tty_port_register_device(&serial->port, tty_drv,
-+ minor, &serial->parent->interface->dev);
++ serial->parent->dev = tty_port_register_device_attr(&serial->port,
++ tty_drv, minor, &serial->parent->interface->dev,
++ serial->parent, hso_serial_dev_groups);
+ dev = serial->parent->dev;
-+ dev_set_drvdata(dev, serial->parent);
-+ i = device_create_file(dev, &dev_attr_hsotype);
+
+ /* fill in specific data for later use */
+ serial->minor = minor;
+
+ return 0;
+exit:
++ hso_serial_tty_unregister(serial);
+ hso_serial_common_free(serial);
+ return -1;
+}
+
+ INIT_WORK(&hso_dev->async_get_intf, async_get_intf);
+ INIT_WORK(&hso_dev->async_put_intf, async_put_intf);
-+ INIT_WORK(&hso_dev->reset_device, reset_device);
+
+ return hso_dev;
+}
+{
+ struct hso_net *hso_net = dev2net(hso_dev);
+ struct device *dev = &hso_net->net->dev;
-+ char *rfkn;
++ static u32 rfkill_counter;
+
-+ rfkn = kzalloc(20, GFP_KERNEL);
-+ if (!rfkn)
-+ dev_err(dev, "%s - Out of memory\n", __func__);
-+
-+ snprintf(rfkn, 20, "hso-%d",
-+ interface->altsetting->desc.bInterfaceNumber);
++ snprintf(hso_net->name, sizeof(hso_net->name), "hso-%d",
++ rfkill_counter++);
+
-+ hso_net->rfkill = rfkill_alloc(rfkn,
++ hso_net->rfkill = rfkill_alloc(hso_net->name,
+ &interface_to_usbdev(interface)->dev,
+ RFKILL_TYPE_WWAN,
+ &hso_rfkill_ops, hso_dev);
+ if (!hso_net->rfkill) {
+ dev_err(dev, "%s - Out of memory\n", __func__);
-+ kfree(rfkn);
+ return;
+ }
+ if (rfkill_register(hso_net->rfkill) < 0) {
+ rfkill_destroy(hso_net->rfkill);
-+ kfree(rfkn);
+ hso_net->rfkill = NULL;
+ dev_err(dev, "%s - Failed to register rfkill\n", __func__);
+ return;
+
+ if (!serial)
+ return;
-+ set_serial_by_index(serial->minor, NULL);
+
+ hso_serial_common_free(serial);
+
+ return hso_dev;
+
+exit2:
++ hso_serial_tty_unregister(serial);
+ hso_serial_common_free(serial);
+exit:
+ hso_free_tiomget(serial);
+ tty_unregister_device(tty_drv, serial->minor);
+ kfree(serial);
+ }
-+ if (hso_dev)
-+ kfree(hso_dev);
++ kfree(hso_dev);
+ return NULL;
+
+}
+{
+ struct usb_device *usbdev = interface_to_usbdev(interface);
+ u8 *config_data = kmalloc(17, GFP_KERNEL);
-+ u32 if_num = interface->altsetting->desc.bInterfaceNumber;
++ u32 if_num = interface->cur_altsetting->desc.bInterfaceNumber;
+ s32 result;
+
+ if (!config_data)
+ return -ENODEV;
+ }
+
-+ if_num = interface->altsetting->desc.bInterfaceNumber;
++ if_num = interface->cur_altsetting->desc.bInterfaceNumber;
+
+ /* Get the interface/port specification from either driver_info or from
+ * the device itself */
+ return result;
+}
+
-+static void reset_device(struct work_struct *data)
-+{
-+ struct hso_device *hso_dev =
-+ container_of(data, struct hso_device, reset_device);
-+ struct usb_device *usb = hso_dev->usb;
-+ int result;
-+
-+ if (hso_dev->usb_gone) {
-+ D1("No reset during disconnect\n");
-+ } else {
-+ result = usb_lock_device_for_reset(usb, hso_dev->interface);
-+ if (result < 0)
-+ D1("unable to lock device for reset: %d\n", result);
-+ else {
-+ usb_reset_device(usb);
-+ usb_unlock_device(usb);
-+ }
-+ }
-+}
-+
+static void hso_serial_ref_free(struct kref *ref)
+{
+ struct hso_device *hso_dev = container_of(ref, struct hso_device, ref);
+
+static void hso_free_interface(struct usb_interface *interface)
+{
-+ struct hso_serial *hso_dev;
++ struct hso_serial *serial;
+ int i;
+
+ for (i = 0; i < HSO_SERIAL_TTY_MINORS; i++) {
+ if (serial_table[i] &&
+ (serial_table[i]->interface == interface)) {
-+ hso_dev = dev2ser(serial_table[i]);
-+ tty_port_tty_hangup(&hso_dev->port, false);
-+ mutex_lock(&hso_dev->parent->mutex);
-+ hso_dev->parent->usb_gone = 1;
-+ mutex_unlock(&hso_dev->parent->mutex);
++ serial = dev2ser(serial_table[i]);
++ tty_port_tty_hangup(&serial->port, false);
++ mutex_lock(&serial->parent->mutex);
++ serial->parent->usb_gone = 1;
++ mutex_unlock(&serial->parent->mutex);
++ cancel_work_sync(&serial_table[i]->async_put_intf);
++ cancel_work_sync(&serial_table[i]->async_get_intf);
++ hso_serial_tty_unregister(serial);
+ kref_put(&serial_table[i]->ref, hso_serial_ref_free);
++ set_serial_by_index(i, NULL);
+ }
+ }
+
+ .close = hso_serial_close,
+ .write = hso_serial_write,
+ .write_room = hso_serial_write_room,
++ .cleanup = hso_serial_cleanup,
+ .ioctl = hso_serial_ioctl,
+ .set_termios = hso_serial_set_termios,
+ .chars_in_buffer = hso_serial_chars_in_buffer,
+/* disable network interface (eg: insmod hso.ko disable_net=1) */
+MODULE_PARM_DESC(disable_net, "Disable the network interface");
+module_param(disable_net, int, S_IRUGO | S_IWUSR);
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/huawei_cdc_ncm.c backports-3.18.1-1/drivers/net/usb/huawei_cdc_ncm.c
---- backports-3.18.1-1.org/drivers/net/usb/huawei_cdc_ncm.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/huawei_cdc_ncm.c 2014-12-16 18:39:45.000000000 +0100
-@@ -0,0 +1,221 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/huawei_cdc_ncm.c backports-4.2.6-1/drivers/net/usb/huawei_cdc_ncm.c
+--- backports-4.2.6-1.org/drivers/net/usb/huawei_cdc_ncm.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/huawei_cdc_ncm.c 2015-11-09 23:37:56.000000000 +0100
+@@ -0,0 +1,224 @@
+/* huawei_cdc_ncm.c - handles Huawei devices using the CDC NCM protocol as
+ * transport layer.
+ * Copyright (C) 2013 Enrico Mioso <mrkiko.rs@gmail.com>
+ struct usb_driver *subdriver = ERR_PTR(-ENODEV);
+ int ret = -ENODEV;
+ struct huawei_cdc_ncm_state *drvstate = (void *)&usbnet_dev->data;
++ int drvflags = 0;
+
+ /* altsetting should always be 1 for NCM devices - so we hard-coded
-+ * it here
++ * it here. Some huawei devices will need the NDP part of the NCM package to
++ * be at the end of the frame.
+ */
-+ ret = cdc_ncm_bind_common(usbnet_dev, intf, 1);
++ drvflags |= CDC_NCM_FLAG_NDP_TO_END;
++ ret = cdc_ncm_bind_common(usbnet_dev, intf, 1, drvflags);
+ if (ret)
+ goto err;
+
+MODULE_AUTHOR("Enrico Mioso <mrkiko.rs@gmail.com>");
+MODULE_DESCRIPTION("USB CDC NCM host driver with encapsulated protocol support");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/int51x1.c backports-3.18.1-1/drivers/net/usb/int51x1.c
---- backports-3.18.1-1.org/drivers/net/usb/int51x1.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/int51x1.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/int51x1.c backports-4.2.6-1/drivers/net/usb/int51x1.c
+--- backports-4.2.6-1.org/drivers/net/usb/int51x1.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/int51x1.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,199 @@
+/*
+ * Copyright (c) 2009 Peter Holik
+MODULE_AUTHOR("Peter Holik");
+MODULE_DESCRIPTION("Intellon usb powerline adapter");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/ipheth.c backports-3.18.1-1/drivers/net/usb/ipheth.c
---- backports-3.18.1-1.org/drivers/net/usb/ipheth.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/ipheth.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/ipheth.c backports-4.2.6-1/drivers/net/usb/ipheth.c
+--- backports-4.2.6-1.org/drivers/net/usb/ipheth.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/ipheth.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,588 @@
+/*
+ * ipheth.c - Apple iPhone USB Ethernet driver
+MODULE_AUTHOR("Diego Giagio <diego@giagio.com>");
+MODULE_DESCRIPTION("Apple iPhone USB Ethernet driver");
+MODULE_LICENSE("Dual BSD/GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/kalmia.c backports-3.18.1-1/drivers/net/usb/kalmia.c
---- backports-3.18.1-1.org/drivers/net/usb/kalmia.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/kalmia.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/kalmia.c backports-4.2.6-1/drivers/net/usb/kalmia.c
+--- backports-4.2.6-1.org/drivers/net/usb/kalmia.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/kalmia.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,366 @@
+/*
+ * USB network interface driver for Samsung Kalmia based LTE USB modem like the
+MODULE_AUTHOR("Marius Bjoernstad Kotsbak <marius@kotsbak.com>");
+MODULE_DESCRIPTION("Samsung Kalmia USB network driver");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/kaweth.c backports-3.18.1-1/drivers/net/usb/kaweth.c
---- backports-3.18.1-1.org/drivers/net/usb/kaweth.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/kaweth.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/kaweth.c backports-4.2.6-1/drivers/net/usb/kaweth.c
+--- backports-4.2.6-1.org/drivers/net/usb/kaweth.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/kaweth.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,1331 @@
+/****************************************************************
+ *
+ awd.done = 0;
+
+ urb->context = &awd;
-+ status = usb_submit_urb(urb, GFP_NOIO);
++ status = usb_submit_urb(urb, GFP_ATOMIC);
+ if (status) {
+ // something went wrong
+ usb_free_urb(urb);
+}
+
+module_usb_driver(kaweth_driver);
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/Kconfig backports-3.18.1-1/drivers/net/usb/Kconfig
---- backports-3.18.1-1.org/drivers/net/usb/Kconfig 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/Kconfig 2015-01-03 15:19:02.310281530 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/Kconfig backports-4.2.6-1/drivers/net/usb/Kconfig
+--- backports-4.2.6-1.org/drivers/net/usb/Kconfig 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/Kconfig 2016-01-27 15:58:23.159192032 +0100
@@ -13,7 +13,6 @@
if USB_NET_DRIVERS
- depends on n
tristate "USB Pegasus/Pegasus-II based ethernet device support"
depends on m
- select BACKPORT_MII
+ select BPAUTO_MII
@@ -92,7 +89,6 @@
module will be called pegasus.
- depends on n
tristate "USB RTL8150 based ethernet device support"
depends on m
- select BACKPORT_MII
+ select BPAUTO_MII
@@ -105,7 +101,6 @@
module will be called rtl8150.
- depends on n
tristate "Realtek RTL8152/RTL8153 Based USB Ethernet Adapters"
depends on m
- select BACKPORT_MII
+ select BPAUTO_MII
@@ -153,7 +148,6 @@
module will be called usbnet.
tristate "ASIX AX88xxx Based USB 2.0 Ethernet Adapters"
depends on m
depends on USB_USBNET
-@@ -183,7 +177,6 @@
+@@ -184,7 +178,6 @@
what other networking devices you have in use.
config USB_NET_AX88179_178A
tristate "ASIX AX88179/178A USB 3.0/2.0 to Gigabit Ethernet"
depends on m
depends on USB_USBNET
-@@ -232,7 +225,6 @@
+@@ -233,7 +226,6 @@
name is used instead.
config USB_NET_CDC_EEM
tristate "CDC EEM support"
depends on m
depends on USB_USBNET
-@@ -268,7 +260,6 @@
+@@ -269,7 +261,6 @@
* Ericsson F5521gw Mobile Broadband Module
config USB_NET_HUAWEI_CDC_NCM
tristate "Huawei NCM embedded AT channel support"
depends on m
depends on USB_USBNET
-@@ -304,7 +295,6 @@
+@@ -305,7 +296,6 @@
module will be called cdc_mbim.
config USB_NET_DM9601
tristate "Davicom DM96xx based USB 10/100 ethernet devices"
depends on m
depends on USB_USBNET
-@@ -314,7 +304,6 @@
+@@ -315,7 +305,6 @@
based USB 10/100 Ethernet adapters.
config USB_NET_SR9700
tristate "CoreChip-sz SR9700 based USB 1.1 10/100 ethernet devices"
depends on m
depends on USB_USBNET
-@@ -324,7 +313,6 @@
+@@ -325,7 +314,6 @@
10/100 Ethernet adapters.
config USB_NET_SR9800
tristate "CoreChip-sz SR9800 based USB 2.0 10/100 ethernet devices"
depends on m
depends on USB_USBNET
-@@ -341,7 +329,6 @@
+@@ -342,7 +330,6 @@
module will be called sr9800.
config USB_NET_SMSC75XX
tristate "SMSC LAN75XX based USB 2.0 gigabit ethernet devices"
depends on m
depends on USB_USBNET
-@@ -353,7 +340,6 @@
+@@ -354,7 +341,6 @@
Gigabit Ethernet adapters.
config USB_NET_SMSC95XX
tristate "SMSC LAN95XX based USB 2.0 10/100 ethernet devices"
depends on m
depends on USB_USBNET
-@@ -365,7 +351,6 @@
+@@ -366,7 +352,6 @@
10/100 Ethernet adapters.
config USB_NET_GL620A
tristate "GeneSys GL620USB-A based cables"
depends on m
depends on USB_USBNET
-@@ -376,7 +361,6 @@
+@@ -377,7 +362,6 @@
Note that the half-duplex "GL620USB" is not supported.
config USB_NET_NET1080
tristate "NetChip 1080 based cables (Laplink, ...)"
depends on m
default y
-@@ -387,7 +371,6 @@
+@@ -388,7 +372,6 @@
optionally with LEDs that indicate traffic
config USB_NET_PLUSB
tristate "Prolific PL-2301/2302/25A1 based cables"
depends on m
# if the handshake/init/reset problems, from original 'plusb',
-@@ -398,7 +381,6 @@
+@@ -399,7 +382,6 @@
with one of these chips.
config USB_NET_MCS7830
tristate "MosChip MCS7830 based Ethernet adapters"
depends on m
depends on USB_USBNET
-@@ -424,7 +406,6 @@
+@@ -425,7 +407,6 @@
(and for) Microsoft; it isn't an "Open" ecosystem or market.
config USB_NET_CDC_SUBSET
tristate "Simple USB Network Links (CDC Ethernet subset)"
depends on m
depends on USB_USBNET
-@@ -496,7 +477,6 @@
+@@ -497,7 +478,6 @@
with one of these chips.
config USB_NET_ZAURUS
tristate "Sharp Zaurus (stock ROMs) and compatible"
depends on m
depends on USB_USBNET
-@@ -516,7 +496,6 @@
+@@ -517,7 +497,6 @@
some cases CDC MDLM) protocol, not "g_ether".
config USB_NET_CX82310_ETH
tristate "Conexant CX82310 USB ethernet port"
depends on m
depends on USB_USBNET
-@@ -526,7 +505,6 @@
+@@ -527,7 +506,6 @@
it will not work with ADSL modems (use cxacru driver instead).
config USB_NET_KALMIA
tristate "Samsung Kalmia based LTE USB modem"
depends on m
depends on USB_USBNET
-@@ -561,7 +539,6 @@
+@@ -562,7 +540,6 @@
module will be called qmi_wwan.
config USB_HSO
tristate "Option USB High Speed Mobile Devices"
depends on m
depends on USB && RFKILL && TTY
-@@ -574,7 +551,6 @@
+@@ -575,7 +552,6 @@
module will be called hso.
config USB_NET_INT51X1
tristate "Intellon PLC based usb adapter"
depends on m
depends on USB_USBNET
-@@ -584,7 +560,6 @@
+@@ -585,7 +561,6 @@
INT51x1/INT5200 chip, like the "devolo dLan duo".
config USB_CDC_PHONET
tristate "CDC Phonet support"
depends on m
depends on PHONET
-@@ -594,7 +569,6 @@
+@@ -595,7 +570,6 @@
"PC suite" USB profile.
config USB_IPHETH
tristate "Apple iPhone USB Ethernet driver"
depends on m
default n
-@@ -618,11 +592,10 @@
+@@ -619,11 +593,10 @@
module will be called sierra_net.
config USB_VL600
help
Select this if you want to use an LG Electronics 4G/LTE usb modem
called VL600. This driver only handles the ethernet
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/lg-vl600.c backports-3.18.1-1/drivers/net/usb/lg-vl600.c
---- backports-3.18.1-1.org/drivers/net/usb/lg-vl600.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/lg-vl600.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/Kconfig.orig backports-4.2.6-1/drivers/net/usb/Kconfig.orig
+--- backports-4.2.6-1.org/drivers/net/usb/Kconfig.orig 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/Kconfig.orig 2015-11-15 22:19:40.000000000 +0100
+@@ -0,0 +1,638 @@
++#
++# USB Network devices configuration
++#
++comment "Host-side USB support is needed for USB Network Adapter support"
++ depends on !USB && NET
++
++menuconfig USB_NET_DRIVERS
++ tristate "USB Network Adapters"
++ depends on m
++ default USB if USB
++ depends on USB && NET
++
++if USB_NET_DRIVERS
++
++config USB_CATC
++ depends on n
++ tristate "USB CATC NetMate-based Ethernet device support"
++ depends on m
++ depends on CRC32
++ ---help---
++ Say Y if you want to use one of the following 10Mbps USB Ethernet
++ device based on the EL1210A chip. Supported devices are:
++ Belkin F5U011
++ Belkin F5U111
++ CATC NetMate
++ CATC NetMate II
++ smartBridges smartNIC
++
++ This driver makes the adapter appear as a normal Ethernet interface,
++ typically on eth0, if it is the only ethernet device, or perhaps on
++ eth1, if you have a PCI or ISA ethernet card installed.
++
++ To compile this driver as a module, choose M here: the
++ module will be called catc.
++
++config USB_KAWETH
++ depends on n
++ tristate "USB KLSI KL5USB101-based ethernet device support"
++ depends on m
++ ---help---
++ Say Y here if you want to use one of the following 10Mbps only
++ USB Ethernet adapters based on the KLSI KL5KUSB101B chipset:
++ 3Com 3C19250
++ ADS USB-10BT
++ ATEN USB Ethernet
++ ASANTE USB To Ethernet Adapter
++ AOX Endpoints USB Ethernet
++ Correga K.K.
++ D-Link DSB-650C and DU-E10
++ Entrega / Portgear E45
++ I-O DATA USB-ET/T
++ Jaton USB Ethernet Device Adapter
++ Kingston Technology USB Ethernet Adapter
++ Linksys USB10T
++ Mobility USB-Ethernet Adapter
++ NetGear EA-101
++ Peracom Enet and Enet2
++ Portsmith Express Ethernet Adapter
++ Shark Pocket Adapter
++ SMC 2202USB
++ Sony Vaio port extender
++
++ This driver is likely to work with most 10Mbps only USB Ethernet
++ adapters, including some "no brand" devices. It does NOT work on
++ SmartBridges smartNIC or on Belkin F5U111 devices - you should use
++ the CATC NetMate driver for those. If you are not sure which one
++ you need, select both, and the correct one should be selected for
++ you.
++
++ This driver makes the adapter appear as a normal Ethernet interface,
++ typically on eth0, if it is the only ethernet device, or perhaps on
++ eth1, if you have a PCI or ISA ethernet card installed.
++
++ To compile this driver as a module, choose M here: the
++ module will be called kaweth.
++
++config USB_PEGASUS
++ depends on n
++ tristate "USB Pegasus/Pegasus-II based ethernet device support"
++ depends on m
++ select BPAUTO_MII
++ ---help---
++ Say Y here if you know you have Pegasus or Pegasus-II based adapter.
++ If in doubt then look at <file:drivers/net/usb/pegasus.h> for the
++ complete list of supported devices.
++
++ If your particular adapter is not in the list and you are _sure_ it
++ is Pegasus or Pegasus II based then send me
++ <petkan@users.sourceforge.net> vendor and device IDs.
++
++ To compile this driver as a module, choose M here: the
++ module will be called pegasus.
++
++config USB_RTL8150
++ depends on n
++ tristate "USB RTL8150 based ethernet device support"
++ depends on m
++ select BPAUTO_MII
++ help
++ Say Y here if you have RTL8150 based usb-ethernet adapter.
++ Send me <petkan@users.sourceforge.net> any comments you may have.
++ You can also check for updates at <http://pegasus2.sourceforge.net/>.
++
++ To compile this driver as a module, choose M here: the
++ module will be called rtl8150.
++
++config USB_RTL8152
++ depends on n
++ tristate "Realtek RTL8152/RTL8153 Based USB Ethernet Adapters"
++ depends on m
++ select BPAUTO_MII
++ help
++ This option adds support for Realtek RTL8152 based USB 2.0
++ 10/100 Ethernet adapters and RTL8153 based USB 3.0 10/100/1000
++ Ethernet adapters.
++
++ To compile this driver as a module, choose M here: the
++ module will be called r8152.
++
++config USB_USBNET
++ tristate "Multi-purpose USB Networking Framework"
++ depends on m
++ select BPAUTO_MII
++ ---help---
++ This driver supports several kinds of network links over USB,
++ with "minidrivers" built around a common network driver core
++ that supports deep queues for efficient transfers. (This gives
++ better performance with small packets and at high speeds).
++
++ The USB host runs "usbnet", and the other end of the link might be:
++
++ - Another USB host, when using USB "network" or "data transfer"
++ cables. These are often used to network laptops to PCs, like
++ "Laplink" parallel cables or some motherboards. These rely
++ on specialized chips from many suppliers.
++
++ - An intelligent USB gadget, perhaps embedding a Linux system.
++ These include PDAs running Linux (iPaq, Yopy, Zaurus, and
++ others), and devices that interoperate using the standard
++ CDC-Ethernet specification (including many cable modems).
++
++ - Network adapter hardware (like those for 10/100 Ethernet) which
++ uses this driver framework.
++
++ The link will appear with a name like "usb0", when the link is
++ a two-node link, or "eth0" for most CDC-Ethernet devices. Those
++ two-node links are most easily managed with Ethernet Bridging
++ (CONFIG_BRIDGE) instead of routing.
++
++ For more information see <http://www.linux-usb.org/usbnet/>.
++
++ To compile this driver as a module, choose M here: the
++ module will be called usbnet.
++
++config USB_NET_AX8817X
++ depends on n
++ tristate "ASIX AX88xxx Based USB 2.0 Ethernet Adapters"
++ depends on m
++ depends on USB_USBNET
++ depends on CRC32
++ depends on PHYLIB
++ default y
++ help
++ This option adds support for ASIX AX88xxx based USB 2.0
++ 10/100 Ethernet adapters.
++
++ This driver should work with at least the following devices:
++ * Aten UC210T
++ * ASIX AX88172
++ * Billionton Systems, USB2AR
++ * Buffalo LUA-U2-KTX
++ * Corega FEther USB2-TX
++ * D-Link DUB-E100
++ * Hawking UF200
++ * Linksys USB200M
++ * Netgear FA120
++ * Sitecom LN-029
++ * Sitecom LN-028
++ * Intellinet USB 2.0 Ethernet
++ * ST Lab USB 2.0 Ethernet
++ * TrendNet TU2-ET100
++
++ This driver creates an interface named "ethX", where X depends on
++ what other networking devices you have in use.
++
++config USB_NET_AX88179_178A
++ depends on n
++ tristate "ASIX AX88179/178A USB 3.0/2.0 to Gigabit Ethernet"
++ depends on m
++ depends on USB_USBNET
++ depends on CRC32
++ depends on PHYLIB
++ default y
++ help
++ This option adds support for ASIX AX88179 based USB 3.0/2.0
++ to Gigabit Ethernet adapters.
++
++ This driver should work with at least the following devices:
++ * ASIX AX88179
++ * ASIX AX88178A
++ * Sitcomm LN-032
++
++ This driver creates an interface named "ethX", where X depends on
++ what other networking devices you have in use.
++
++config USB_NET_CDCETHER
++ tristate "CDC Ethernet support (smart devices such as cable modems)"
++ depends on m
++ depends on USB_USBNET
++ default y
++ help
++ This option supports devices conforming to the Communication Device
++ Class (CDC) Ethernet Control Model, a specification that's easy to
++ implement in device firmware. The CDC specifications are available
++ from <http://www.usb.org/>.
++
++ CDC Ethernet is an implementation option for DOCSIS cable modems
++ that support USB connectivity, used for non-Microsoft USB hosts.
++ The Linux-USB CDC Ethernet Gadget driver is an open implementation.
++ This driver should work with at least the following devices:
++
++ * Dell Wireless 5530 HSPA
++ * Ericsson PipeRider (all variants)
++ * Ericsson Mobile Broadband Module (all variants)
++ * Motorola (DM100 and SB4100)
++ * Broadcom Cable Modem (reference design)
++ * Toshiba (PCX1100U and F3507g/F3607gw)
++ * ...
++
++ This driver creates an interface named "ethX", where X depends on
++ what other networking devices you have in use. However, if the
++ IEEE 802 "local assignment" bit is set in the address, a "usbX"
++ name is used instead.
++
++config USB_NET_CDC_EEM
++ depends on n
++ tristate "CDC EEM support"
++ depends on m
++ depends on USB_USBNET
++ help
++ This option supports devices conforming to the Communication Device
++ Class (CDC) Ethernet Emulation Model, a specification that's easy to
++ implement in device firmware. The CDC EEM specifications are available
++ from <http://www.usb.org/>.
++
++ This driver creates an interface named "ethX", where X depends on
++ what other networking devices you have in use. However, if the
++ IEEE 802 "local assignment" bit is set in the address, a "usbX"
++ name is used instead.
++
++config USB_NET_CDC_NCM
++ tristate "CDC NCM support"
++ depends on m
++ depends on USB_USBNET
++ default y
++ help
++ This driver provides support for CDC NCM (Network Control Model
++ Device USB Class Specification). The CDC NCM specification is
++ available from <http://www.usb.org/>.
++
++ Say "y" to link the driver statically, or "m" to build a
++ dynamically linked module.
++
++ This driver should work with at least the following devices:
++ * ST-Ericsson M700 LTE FDD/TDD Mobile Broadband Modem (ref. design)
++ * ST-Ericsson M5730 HSPA+ Mobile Broadband Modem (reference design)
++ * ST-Ericsson M570 HSPA+ Mobile Broadband Modem (reference design)
++ * ST-Ericsson M343 HSPA Mobile Broadband Modem (reference design)
++ * Ericsson F5521gw Mobile Broadband Module
++
++config USB_NET_HUAWEI_CDC_NCM
++ depends on n
++ tristate "Huawei NCM embedded AT channel support"
++ depends on m
++ depends on USB_USBNET
++ select USB_WDM
++ select USB_NET_CDC_NCM
++ help
++ This driver supports huawei-style NCM devices, that use NCM as a
++ transport for other protocols, usually an embedded AT channel.
++ Good examples are:
++ * Huawei E3131
++ * Huawei E3251
++
++ To compile this driver as a module, choose M here: the module will be
++ called huawei_cdc_ncm.ko.
++
++config USB_NET_CDC_MBIM
++ tristate "CDC MBIM support"
++ depends on m
++ depends on USB_USBNET
++ select USB_WDM
++ select USB_NET_CDC_NCM
++ help
++ This driver provides support for CDC MBIM (Mobile Broadband
++ Interface Model) devices. The CDC MBIM specification is
++ available from <http://www.usb.org/>.
++
++ MBIM devices require configuration using the management
++ protocol defined by the MBIM specification. This driver
++ provides unfiltered access to the MBIM control channel
++ through the associated /dev/cdc-wdmx character device.
++
++ To compile this driver as a module, choose M here: the
++ module will be called cdc_mbim.
++
++config USB_NET_DM9601
++ depends on n
++ tristate "Davicom DM96xx based USB 10/100 ethernet devices"
++ depends on m
++ depends on USB_USBNET
++ depends on CRC32
++ help
++ This option adds support for Davicom DM9601/DM9620/DM9621A
++ based USB 10/100 Ethernet adapters.
++
++config USB_NET_SR9700
++ depends on n
++ tristate "CoreChip-sz SR9700 based USB 1.1 10/100 ethernet devices"
++ depends on m
++ depends on USB_USBNET
++ depends on CRC32
++ help
++ This option adds support for CoreChip-sz SR9700 based USB 1.1
++ 10/100 Ethernet adapters.
++
++config USB_NET_SR9800
++ depends on n
++ tristate "CoreChip-sz SR9800 based USB 2.0 10/100 ethernet devices"
++ depends on m
++ depends on USB_USBNET
++ depends on CRC32
++ ---help---
++ Say Y if you want to use one of the following 100Mbps USB Ethernet
++ device based on the CoreChip-sz SR9800 chip.
++
++ This driver makes the adapter appear as a normal Ethernet interface,
++ typically on eth0, if it is the only ethernet device, or perhaps on
++ eth1, if you have a PCI or ISA ethernet card installed.
++
++ To compile this driver as a module, choose M here: the
++ module will be called sr9800.
++
++config USB_NET_SMSC75XX
++ depends on n
++ tristate "SMSC LAN75XX based USB 2.0 gigabit ethernet devices"
++ depends on m
++ depends on USB_USBNET
++ depends on BITREVERSE
++ depends on CRC16
++ depends on CRC32
++ help
++ This option adds support for SMSC LAN75XX based USB 2.0
++ Gigabit Ethernet adapters.
++
++config USB_NET_SMSC95XX
++ depends on n
++ tristate "SMSC LAN95XX based USB 2.0 10/100 ethernet devices"
++ depends on m
++ depends on USB_USBNET
++ depends on BITREVERSE
++ depends on CRC16
++ depends on CRC32
++ help
++ This option adds support for SMSC LAN95XX based USB 2.0
++ 10/100 Ethernet adapters.
++
++config USB_NET_GL620A
++ depends on n
++ tristate "GeneSys GL620USB-A based cables"
++ depends on m
++ depends on USB_USBNET
++ help
++ Choose this option if you're using a host-to-host cable,
++ or PC2PC motherboard, with this chip.
++
++ Note that the half-duplex "GL620USB" is not supported.
++
++config USB_NET_NET1080
++ depends on n
++ tristate "NetChip 1080 based cables (Laplink, ...)"
++ depends on m
++ default y
++ depends on USB_USBNET
++ help
++ Choose this option if you're using a host-to-host cable based
++ on this design: one NetChip 1080 chip and supporting logic,
++ optionally with LEDs that indicate traffic
++
++config USB_NET_PLUSB
++ depends on n
++ tristate "Prolific PL-2301/2302/25A1 based cables"
++ depends on m
++ # if the handshake/init/reset problems, from original 'plusb',
++ # are ever resolved ... then remove "experimental"
++ depends on USB_USBNET
++ help
++ Choose this option if you're using a host-to-host cable
++ with one of these chips.
++
++config USB_NET_MCS7830
++ depends on n
++ tristate "MosChip MCS7830 based Ethernet adapters"
++ depends on m
++ depends on USB_USBNET
++ help
++ Choose this option if you're using a 10/100 Ethernet USB2
++ adapter based on the MosChip 7830 controller. This includes
++ adapters marketed under the DeLOCK brand.
++
++config USB_NET_RNDIS_HOST
++ tristate "Host for RNDIS and ActiveSync devices"
++ depends on m
++ depends on USB_USBNET
++ select USB_NET_CDCETHER
++ help
++ This option enables hosting "Remote NDIS" USB networking links,
++ as encouraged by Microsoft (instead of CDC Ethernet!) for use in
++ various devices that may only support this protocol. A variant
++ of this protocol (with even less public documentation) seems to
++ be at the root of Microsoft's "ActiveSync" too.
++
++ Avoid using this protocol unless you have no better options.
++ The protocol specification is incomplete, and is controlled by
++ (and for) Microsoft; it isn't an "Open" ecosystem or market.
++
++config USB_NET_CDC_SUBSET
++ depends on n
++ tristate "Simple USB Network Links (CDC Ethernet subset)"
++ depends on m
++ depends on USB_USBNET
++ default y
++ help
++ This driver module supports USB network devices that can work
++ without any device-specific information. Select it if you have
++ one of these drivers.
++
++ Note that while many USB host-to-host cables can work in this mode,
++ that may mean not being able to talk to Win32 systems or more
++ commonly not being able to handle certain events (like replugging
++ the host on the other end) very well. Also, these devices will
++ not generally have permanently assigned Ethernet addresses.
++
++config USB_ALI_M5632
++ bool "ALi M5632 based 'USB 2.0 Data Link' cables"
++ depends on USB_NET_CDC_SUBSET
++ help
++ Choose this option if you're using a host-to-host cable
++ based on this design, which supports USB 2.0 high speed.
++
++config USB_AN2720
++ bool "AnchorChips 2720 based cables (Xircom PGUNET, ...)"
++ depends on USB_NET_CDC_SUBSET
++ help
++ Choose this option if you're using a host-to-host cable
++ based on this design. Note that AnchorChips is now a
++ Cypress brand.
++
++config USB_BELKIN
++ bool "eTEK based host-to-host cables (Advance, Belkin, ...)"
++ depends on USB_NET_CDC_SUBSET
++ default y
++ help
++ Choose this option if you're using a host-to-host cable
++ based on this design: two NetChip 2890 chips and an Atmel
++ microcontroller, with LEDs that indicate traffic.
++
++config USB_ARMLINUX
++ bool "Embedded ARM Linux links (iPaq, ...)"
++ depends on USB_NET_CDC_SUBSET
++ default y
++ help
++ Choose this option to support the "usb-eth" networking driver
++ used by most of the ARM Linux community with device controllers
++ such as the SA-11x0 and PXA-25x UDCs, or the tftp capabilities
++ in some PXA versions of the "blob" boot loader.
++
++ Linux-based "Gumstix" PXA-25x based systems use this protocol
++ to talk with other Linux systems.
++
++ Although the ROMs shipped with Sharp Zaurus products use a
++ different link level framing protocol, you can have them use
++ this simpler protocol by installing a different kernel.
++
++config USB_EPSON2888
++ bool "Epson 2888 based firmware (DEVELOPMENT)"
++ depends on USB_NET_CDC_SUBSET
++ help
++ Choose this option to support the usb networking links used
++ by some sample firmware from Epson.
++
++config USB_KC2190
++ bool "KT Technology KC2190 based cables (InstaNet)"
++ depends on USB_NET_CDC_SUBSET
++ help
++ Choose this option if you're using a host-to-host cable
++ with one of these chips.
++
++config USB_NET_ZAURUS
++ depends on n
++ tristate "Sharp Zaurus (stock ROMs) and compatible"
++ depends on m
++ depends on USB_USBNET
++ select USB_NET_CDCETHER
++ depends on CRC32
++ default y
++ help
++ Choose this option to support the usb networking links used by
++ Zaurus models like the SL-5000D, SL-5500, SL-5600, A-300, B-500.
++ This also supports some related device firmware, as used in some
++ PDAs from Olympus and some cell phones from Motorola.
++
++ If you install an alternate image, such as the Linux 2.6 based
++ versions of OpenZaurus, you should no longer need to support this
++ protocol. Only the "eth-fd" or "net_fd" drivers in these devices
++ really need this non-conformant variant of CDC Ethernet (or in
++ some cases CDC MDLM) protocol, not "g_ether".
++
++config USB_NET_CX82310_ETH
++ depends on n
++ tristate "Conexant CX82310 USB ethernet port"
++ depends on m
++ depends on USB_USBNET
++ help
++ Choose this option if you're using a Conexant CX82310-based ADSL
++ router with USB ethernet port. This driver is for routers only,
++ it will not work with ADSL modems (use cxacru driver instead).
++
++config USB_NET_KALMIA
++ depends on n
++ tristate "Samsung Kalmia based LTE USB modem"
++ depends on m
++ depends on USB_USBNET
++ help
++ Choose this option if you have a Samsung Kalmia based USB modem
++ as Samsung GT-B3730.
++
++ To compile this driver as a module, choose M here: the
++ module will be called kalmia.
++
++config USB_NET_QMI_WWAN
++ tristate "QMI WWAN driver for Qualcomm MSM based 3G and LTE modems"
++ depends on m
++ depends on USB_USBNET
++ select USB_WDM
++ help
++ Support WWAN LTE/3G devices based on Qualcomm Mobile Data Modem
++ (MDM) chipsets. Examples of such devices are
++ * Huawei E392/E398
++
++ This driver will only drive the ethernet part of the chips.
++ The devices require additional configuration to be usable.
++ Multiple management interfaces with linux drivers are
++ available:
++
++ * option: AT commands on /dev/ttyUSBx
++ * cdc-wdm: Qualcomm MSM Interface (QMI) protocol on /dev/cdc-wdmx
++
++ A modem manager with support for QMI is recommended.
++
++ To compile this driver as a module, choose M here: the
++ module will be called qmi_wwan.
++
++config USB_HSO
++ depends on n
++ tristate "Option USB High Speed Mobile Devices"
++ depends on m
++ depends on USB && RFKILL && TTY
++ default n
++ help
++ Choose this option if you have an Option HSDPA/HSUPA card.
++ These cards support downlink speeds of 7.2Mbps or greater.
++
++ To compile this driver as a module, choose M here: the
++ module will be called hso.
++
++config USB_NET_INT51X1
++ depends on n
++ tristate "Intellon PLC based usb adapter"
++ depends on m
++ depends on USB_USBNET
++ help
++ Choose this option if you're using a 14Mb USB-based PLC
++ (Powerline Communications) solution with an Intellon
++ INT51x1/INT5200 chip, like the "devolo dLan duo".
++
++config USB_CDC_PHONET
++ depends on n
++ tristate "CDC Phonet support"
++ depends on m
++ depends on PHONET
++ help
++ Choose this option to support the Phonet interface to a Nokia
++ cellular modem, as found on most Nokia handsets with the
++ "PC suite" USB profile.
++
++config USB_IPHETH
++ depends on n
++ tristate "Apple iPhone USB Ethernet driver"
++ depends on m
++ default n
++ ---help---
++ Module used to share Internet connection (tethering) from your
++ iPhone (Original, 3G and 3GS) to your system.
++ Note that you need userspace libraries and programs that are needed
++ to pair your device with your system and that understand the iPhone
++ protocol.
++
++ For more information: http://giagio.com/wiki/moin.cgi/iPhoneEthernetDriver
++
++config USB_SIERRA_NET
++ tristate "USB-to-WWAN Driver for Sierra Wireless modems"
++ depends on m
++ depends on USB_USBNET
++ help
++ Choose this option if you have a Sierra Wireless USB-to-WWAN device.
++
++ To compile this driver as a module, choose M here: the
++ module will be called sierra_net.
++
++config USB_VL600
++ depends on n
++ tristate "LG VL600 modem dongle"
++ depends on m
++ depends on USB_NET_CDCETHER && TTY
++ select USB_ACM
++ help
++ Select this if you want to use an LG Electronics 4G/LTE usb modem
++ called VL600. This driver only handles the ethernet
++ interface exposed by the modem firmware. To establish a connection
++ you will first need a userspace program that sends the right
++ command to the modem through its CDC ACM port, and most
++ likely also a DHCP client. See this thread about using the
++ 4G modem from Verizon:
++
++ http://ubuntuforums.org/showpost.php?p=10589647&postcount=17
++
++endif # USB_NET_DRIVERS
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/lg-vl600.c backports-4.2.6-1/drivers/net/usb/lg-vl600.c
+--- backports-4.2.6-1.org/drivers/net/usb/lg-vl600.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/lg-vl600.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,353 @@
+/*
+ * Ethernet interface part of the LG VL600 LTE modem (4G dongle)
+ &buf->data[sizeof(*ethhdr) + 0x12],
+ ETH_ALEN);
+ } else {
-+ memset(ethhdr->h_source, 0, ETH_ALEN);
++ eth_zero_addr(ethhdr->h_source);
+ memcpy(ethhdr->h_dest, dev->net->dev_addr, ETH_ALEN);
+
+ /* Inbound IPv6 packets have an IPv4 ethertype (0x800)
+MODULE_AUTHOR("Anrzej Zaborowski");
+MODULE_DESCRIPTION("LG-VL600 modem's ethernet link");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/Makefile backports-3.18.1-1/drivers/net/usb/Makefile
---- backports-3.18.1-1.org/drivers/net/usb/Makefile 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/Makefile 2015-01-03 13:49:51.269970813 +0100
-@@ -1,39 +1,35 @@
--#
--# Makefile for USB Network drivers
--#
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/Makefile backports-4.2.6-1/drivers/net/usb/Makefile
+--- backports-4.2.6-1.org/drivers/net/usb/Makefile 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/Makefile 2016-01-27 15:53:50.000000000 +0100
+@@ -1,39 +1,40 @@
+ #
+ # Makefile for USB Network drivers
+ #
-#
-#obj-$(CPTCFG_USB_CATC) += catc.o
-#obj-$(CPTCFG_USB_KAWETH) += kaweth.o
-#obj-$(CPTCFG_USB_HSO) += hso.o
-#obj-$(CPTCFG_USB_NET_AX8817X) += asix.o
-#obj-$(CPTCFG_USB_NET_AX88179_178A) += ax88179_178a.o
++
+obj-$(CPTCFG_USB_CATC) += catc.o
+obj-$(CPTCFG_USB_KAWETH) += kaweth.o
+obj-$(CPTCFG_USB_PEGASUS) += pegasus.o
+obj-$(CPTCFG_USB_VL600) += lg-vl600.o
obj-$(CPTCFG_USB_NET_QMI_WWAN) += qmi_wwan.o
obj-$(CPTCFG_USB_NET_CDC_MBIM) += cdc_mbim.o
--
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/mcs7830.c backports-3.18.1-1/drivers/net/usb/mcs7830.c
---- backports-3.18.1-1.org/drivers/net/usb/mcs7830.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/mcs7830.c 2014-12-16 18:39:45.000000000 +0100
+
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/mcs7830.c backports-4.2.6-1/drivers/net/usb/mcs7830.c
+--- backports-4.2.6-1.org/drivers/net/usb/mcs7830.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/mcs7830.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,643 @@
+/*
+ * MOSCHIP MCS7830 based (7730/7830/7832) USB 2.0 Ethernet Devices
+
+MODULE_DESCRIPTION("USB to network adapter MCS7830)");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/net1080.c backports-3.18.1-1/drivers/net/usb/net1080.c
---- backports-3.18.1-1.org/drivers/net/usb/net1080.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/net1080.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/net1080.c backports-4.2.6-1/drivers/net/usb/net1080.c
+--- backports-4.2.6-1.org/drivers/net/usb/net1080.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/net1080.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,544 @@
+/*
+ * Net1080 based USB host-to-host cables
+MODULE_AUTHOR("David Brownell");
+MODULE_DESCRIPTION("NetChip 1080 based USB Host-to-Host Links");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/pegasus.c backports-3.18.1-1/drivers/net/usb/pegasus.c
---- backports-3.18.1-1.org/drivers/net/usb/pegasus.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/pegasus.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/pegasus.c backports-4.2.6-1/drivers/net/usb/pegasus.c
+--- backports-4.2.6-1.org/drivers/net/usb/pegasus.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/pegasus.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,1335 @@
+/*
+ * Copyright (c) 1999-2013 Petko Manolov (petkan@nucleusys.com)
+
+module_init(pegasus_init);
+module_exit(pegasus_exit);
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/pegasus.h backports-3.18.1-1/drivers/net/usb/pegasus.h
---- backports-3.18.1-1.org/drivers/net/usb/pegasus.h 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/pegasus.h 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/pegasus.h backports-4.2.6-1/drivers/net/usb/pegasus.h
+--- backports-4.2.6-1.org/drivers/net/usb/pegasus.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/pegasus.h 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,308 @@
+/*
+ * Copyright (c) 1999-2013 Petko Manolov (petkan@nucleusys.com)
+
+
+#endif /* PEGASUS_DEV */
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/plusb.c backports-3.18.1-1/drivers/net/usb/plusb.c
---- backports-3.18.1-1.org/drivers/net/usb/plusb.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/plusb.c 2014-12-16 18:39:45.000000000 +0100
-@@ -0,0 +1,157 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/plusb.c backports-4.2.6-1/drivers/net/usb/plusb.c
+--- backports-4.2.6-1.org/drivers/net/usb/plusb.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/plusb.c 2015-11-09 23:37:56.000000000 +0100
+@@ -0,0 +1,162 @@
+/*
+ * PL-2301/2302 USB host-to-host link cables
+ * Copyright (C) 2000-2005 by David Brownell
+}, {
+ USB_DEVICE(0x050d, 0x258a), /* Belkin F5U258/F5U279 (PL-25A1) */
+ .driver_info = (unsigned long) &prolific_info,
++}, {
++ USB_DEVICE(0x3923, 0x7825), /* National Instruments USB
++ * Host-to-Host Cable
++ */
++ .driver_info = (unsigned long) &prolific_info,
+},
+
+ { }, // END
+MODULE_AUTHOR("David Brownell");
+MODULE_DESCRIPTION("Prolific PL-2301/2302/25A1 USB Host to Host Link Driver");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/r8152.c backports-3.18.1-1/drivers/net/usb/r8152.c
---- backports-3.18.1-1.org/drivers/net/usb/r8152.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/r8152.c 2015-01-03 13:42:25.000000000 +0100
-@@ -0,0 +1,3913 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/r8152.c backports-4.2.6-1/drivers/net/usb/r8152.c
+--- backports-4.2.6-1.org/drivers/net/usb/r8152.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/r8152.c 2016-01-27 12:43:25.000000000 +0100
+@@ -0,0 +1,2847 @@
+/*
+ * Copyright (c) 2014 Realtek Semiconductor Corp. All rights reserved.
+ *
+#include <linux/list.h>
+#include <linux/ip.h>
+#include <linux/ipv6.h>
-+#include <net/ip6_checksum.h>
-+#include <uapi/linux/mdio.h>
-+#include <linux/mdio.h>
+
+/* Version Information */
-+#define DRIVER_VERSION "v1.07.0 (2014/10/09)"
++#define DRIVER_VERSION "v1.04.0 (2014/01/15)"
+#define DRIVER_AUTHOR "Realtek linux nic maintainers <nic_swsd@realtek.com>"
+#define DRIVER_DESC "Realtek RTL8152/RTL8153 Based USB Ethernet Adapters"
+#define MODULENAME "r8152"
+#define PLA_WDT6_CTRL 0xe428
+#define PLA_TCR0 0xe610
+#define PLA_TCR1 0xe612
-+#define PLA_MTPS 0xe615
+#define PLA_TXFIFO_CTRL 0xe618
-+#define PLA_RSTTALLY 0xe800
++#define PLA_RSTTELLY 0xe800
+#define PLA_CR 0xe813
+#define PLA_CRWECR 0xe81c
-+#define PLA_CONFIG12 0xe81e /* CONFIG1, CONFIG2 */
-+#define PLA_CONFIG34 0xe820 /* CONFIG3, CONFIG4 */
+#define PLA_CONFIG5 0xe822
+#define PLA_PHY_PWR 0xe84c
+#define PLA_OOB_CTRL 0xe84f
+#define PLA_MISC_0 0xe858
+#define PLA_MISC_1 0xe85a
+#define PLA_OCP_GPHY_BASE 0xe86c
-+#define PLA_TALLYCNT 0xe890
++#define PLA_TELLYCNT 0xe890
+#define PLA_SFF_STS_7 0xe8de
+#define PLA_PHYSTATUS 0xe908
+#define PLA_BP_BA 0xfc26
+#define OCP_SRAM_ADDR 0xa436
+#define OCP_SRAM_DATA 0xa438
+#define OCP_DOWN_SPEED 0xa442
-+#define OCP_EEE_ABLE 0xa5c4
-+#define OCP_EEE_ADV 0xa5d0
-+#define OCP_EEE_LPABLE 0xa5d2
++#define OCP_EEE_CFG2 0xa5d0
+#define OCP_ADC_CFG 0xbc06
+
+/* SRAM Register */
+/* PLA_TCR1 */
+#define VERSION_MASK 0x7cf0
+
-+/* PLA_MTPS */
-+#define MTPS_JUMBO (12 * 1024 / 64)
-+#define MTPS_DEFAULT (6 * 1024 / 64)
-+
-+/* PLA_RSTTALLY */
-+#define TALLY_RESET 0x0001
-+
+/* PLA_CR */
+#define CR_RST 0x10
+#define CR_RE 0x08
+/* PAL_BDC_CR */
+#define ALDPS_PROXY_MODE 0x0001
+
-+/* PLA_CONFIG34 */
-+#define LINK_ON_WAKE_EN 0x0010
-+#define LINK_OFF_WAKE_EN 0x0008
-+
+/* PLA_CONFIG5 */
-+#define BWF_EN 0x0040
-+#define MWF_EN 0x0020
-+#define UWF_EN 0x0010
+#define LAN_WAKE_EN 0x0002
+
+/* PLA_LED_FEATURE */
+/* USB_DEV_STAT */
+#define STAT_SPEED_MASK 0x0006
+#define STAT_SPEED_HIGH 0x0000
-+#define STAT_SPEED_FULL 0x0002
++#define STAT_SPEED_FULL 0x0001
+
+/* USB_TX_AGG */
+#define TX_AGG_MAX_THRESHOLD 0x03
+#define EEE_NWAY_EN 0x1000
+#define TX_QUIET_EN 0x0200
+#define RX_QUIET_EN 0x0100
-+#define sd_rise_time_mask 0x0070
-+#define sd_rise_time(x) (min(x, 7) << 4) /* bit 4 ~ 6 */
++#define SDRISETIME 0x0010 /* bit 4 ~ 6 */
+#define RG_RXLPI_MSK_HFDUP 0x0008
+#define SDFALLTIME 0x0007 /* bit 0 ~ 2 */
+
+#define RG_EEEPRG_EN 0x0010
+
+/* OCP_EEE_CONFIG3 */
-+#define fast_snr_mask 0xff80
-+#define fast_snr(x) (min(x, 0x1ff) << 7) /* bit 7 ~ 15 */
++#define FST_SNR_EYE_R 0x1500 /* bit 7 ~ 15 */
+#define RG_LFS_SEL 0x0060 /* bit 6 ~ 5 */
+#define MSK_PH 0x0006 /* bit 0 ~ 3 */
+
+#define FUN_ADDR 0x0000
+#define FUN_DATA 0x4000
+/* bit[4:0] device addr */
++#define DEVICE_ADDR 0x0007
++
++/* OCP_EEE_DATA */
++#define EEE_ADDR 0x003C
++#define EEE_DATA 0x0002
+
+/* OCP_EEE_CFG */
+#define CTAP_SHORT_EN 0x0040
+/* OCP_DOWN_SPEED */
+#define EN_10M_BGOFF 0x0080
+
++/* OCP_EEE_CFG2 */
++#define MY1000_EEE 0x0004
++#define MY100_EEE 0x0002
++
+/* OCP_ADC_CFG */
+#define CKADSEL_L 0x0100
+#define ADC_EN 0x0080
+ FULL_DUP = 0x01,
+};
+
-+#define RTL8152_MAX_TX 4
++#define RTL8152_MAX_TX 10
+#define RTL8152_MAX_RX 10
+#define INTBUFSIZE 2
+#define CRC_SIZE 4
+#define BYTE_EN_START_MASK 0x0f
+#define BYTE_EN_END_MASK 0xf0
+
-+#define RTL8153_MAX_PACKET 9216 /* 9K */
-+#define RTL8153_MAX_MTU (RTL8153_MAX_PACKET - VLAN_ETH_HLEN - VLAN_HLEN)
+#define RTL8152_RMS (VLAN_ETH_FRAME_LEN + VLAN_HLEN)
-+#define RTL8153_RMS RTL8153_MAX_PACKET
-+#define RTL8152_TX_TIMEOUT (5 * HZ)
++#define RTL8152_TX_TIMEOUT (HZ)
+
+/* rtl8152 flags */
+enum rtl8152_flags {
+ RTL8152_SET_RX_MODE,
+ WORK_ENABLE,
+ RTL8152_LINK_CHG,
-+ SELECTIVE_SUSPEND,
-+ PHY_RESET,
-+ SCHEDULE_TASKLET,
+};
+
+/* Define these values to match your device */
+#define MCU_TYPE_PLA 0x0100
+#define MCU_TYPE_USB 0x0000
+
-+#define REALTEK_USB_DEVICE(vend, prod) \
-+ USB_DEVICE_INTERFACE_CLASS(vend, prod, USB_CLASS_VENDOR_SPEC)
-+
-+struct tally_counter {
-+ __le64 tx_packets;
-+ __le64 rx_packets;
-+ __le64 tx_errors;
-+ __le32 rx_errors;
-+ __le16 rx_missed;
-+ __le16 align_errors;
-+ __le32 tx_one_collision;
-+ __le32 tx_multi_collision;
-+ __le64 rx_unicast;
-+ __le64 rx_broadcast;
-+ __le32 rx_multicast;
-+ __le16 tx_aborted;
-+ __le16 tx_underun;
-+};
-+
+struct rx_desc {
+ __le32 opts1;
+#define RX_LEN_MASK 0x7fff
-+
+ __le32 opts2;
-+#define RD_UDP_CS (1 << 23)
-+#define RD_TCP_CS (1 << 22)
-+#define RD_IPV6_CS (1 << 20)
-+#define RD_IPV4_CS (1 << 19)
-+
+ __le32 opts3;
-+#define IPF (1 << 23) /* IP checksum fail */
-+#define UDPF (1 << 22) /* UDP checksum fail */
-+#define TCPF (1 << 21) /* TCP checksum fail */
-+#define RX_VLAN_TAG (1 << 16)
-+
+ __le32 opts4;
+ __le32 opts5;
+ __le32 opts6;
+ __le32 opts1;
+#define TX_FS (1 << 31) /* First segment of a packet */
+#define TX_LS (1 << 30) /* Final segment of a packet */
-+#define GTSENDV4 (1 << 28)
-+#define GTSENDV6 (1 << 27)
-+#define GTTCPHO_SHIFT 18
-+#define GTTCPHO_MAX 0x7fU
-+#define TX_LEN_MAX 0x3ffffU
++#define TX_LEN_MASK 0x3ffff
+
+ __le32 opts2;
+#define UDP_CS (1 << 31) /* Calculate UDP/IP checksum */
+#define TCP_CS (1 << 30) /* Calculate TCP/IP checksum */
+#define IPV4_CS (1 << 29) /* Calculate IPv4 checksum */
+#define IPV6_CS (1 << 28) /* Calculate IPv6 checksum */
-+#define MSS_SHIFT 17
-+#define MSS_MAX 0x7ffU
-+#define TCPHO_SHIFT 17
-+#define TCPHO_MAX 0x7ffU
-+#define TX_VLAN_TAG (1 << 16)
+};
+
+struct r8152;
+ spinlock_t rx_lock, tx_lock;
+ struct delayed_work schedule;
+ struct mii_if_info mii;
-+ struct mutex control; /* use for hw setting */
+
+ struct rtl_ops {
+ void (*init)(struct r8152 *);
+ int (*enable)(struct r8152 *);
+ void (*disable)(struct r8152 *);
-+ void (*up)(struct r8152 *);
+ void (*down)(struct r8152 *);
+ void (*unload)(struct r8152 *);
-+ int (*eee_get)(struct r8152 *, struct ethtool_eee *);
-+ int (*eee_set)(struct r8152 *, struct ethtool_eee *);
+ } __no_const rtl_ops;
+
+ int intr_interval;
-+ u32 saved_wolopts;
+ u32 msg_enable;
+ u32 tx_qlen;
+ u16 ocp_base;
+ RTL_VER_MAX
+};
+
-+enum tx_csum_stat {
-+ TX_CSUM_SUCCESS = 0,
-+ TX_CSUM_TSO,
-+ TX_CSUM_NONE
-+};
-+
+/* Maximum number of multicast addresses to filter (vs. Rx-all-multicast).
+ * The RTL chips use a 64 element hash table based on the Ethernet CRC.
+ */
+static const int multicast_filter_limit = 32;
-+static unsigned int agg_buf_sz = 16384;
-+
-+#define RTL_LIMITED_TSO_SIZE (agg_buf_sz - sizeof(struct tx_desc) - \
-+ VLAN_ETH_HLEN - VLAN_HLEN)
++static unsigned int rx_buf_sz = 16384;
+
+static
+int get_registers(struct r8152 *tp, u16 value, u16 index, u16 size, void *data)
+ return -ENOMEM;
+
+ ret = usb_control_msg(tp->udev, usb_rcvctrlpipe(tp->udev, 0),
-+ RTL8152_REQ_GET_REGS, RTL8152_REQT_READ,
-+ value, index, tmp, size, 500);
++ RTL8152_REQ_GET_REGS, RTL8152_REQT_READ,
++ value, index, tmp, size, 500);
+
+ memcpy(data, tmp, size);
+ kfree(tmp);
+ int ret;
+ void *tmp;
+
-+ tmp = kmemdup(data, size, GFP_KERNEL);
++ tmp = kmalloc(size, GFP_KERNEL);
+ if (!tmp)
+ return -ENOMEM;
+
++ memcpy(tmp, data, size);
++
+ ret = usb_control_msg(tp->udev, usb_sndctrlpipe(tp->udev, 0),
-+ RTL8152_REQ_SET_REGS, RTL8152_REQT_WRITE,
-+ value, index, tmp, size, 500);
++ RTL8152_REQ_SET_REGS, RTL8152_REQT_WRITE,
++ value, index, tmp, size, 500);
+
+ kfree(tmp);
-+
+ return ret;
+}
+
+static int generic_ocp_read(struct r8152 *tp, u16 index, u16 size,
-+ void *data, u16 type)
++ void *data, u16 type)
+{
+ u16 limit = 64;
+ int ret = 0;
+}
+
+static int generic_ocp_write(struct r8152 *tp, u16 index, u16 byteen,
-+ u16 size, void *data, u16 type)
++ u16 size, void *data, u16 type)
+{
+ int ret;
+ u16 byteen_start, byteen_end, byen;
+ while (size) {
+ if (size > limit) {
+ ret = set_registers(tp, index,
-+ type | BYTE_EN_DWORD,
-+ limit, data);
++ type | BYTE_EN_DWORD,
++ limit, data);
+ if (ret < 0)
+ goto error1;
+
+ size -= limit;
+ } else {
+ ret = set_registers(tp, index,
-+ type | BYTE_EN_DWORD,
-+ size, data);
++ type | BYTE_EN_DWORD,
++ size, data);
+ if (ret < 0)
+ goto error1;
+
+static int read_mii_word(struct net_device *netdev, int phy_id, int reg)
+{
+ struct r8152 *tp = netdev_priv(netdev);
-+ int ret;
-+
-+ if (test_bit(RTL8152_UNPLUG, &tp->flags))
-+ return -ENODEV;
+
+ if (phy_id != R8152_PHY_ID)
+ return -EINVAL;
+
-+ ret = r8152_mdio_read(tp, reg);
-+
-+ return ret;
++ return r8152_mdio_read(tp, reg);
+}
+
+static
+{
+ struct r8152 *tp = netdev_priv(netdev);
+
-+ if (test_bit(RTL8152_UNPLUG, &tp->flags))
-+ return;
-+
+ if (phy_id != R8152_PHY_ID)
+ return;
+
+ r8152_mdio_write(tp, reg, val);
+}
+
-+static int
-+r8152_submit_rx(struct r8152 *tp, struct rx_agg *agg, gfp_t mem_flags);
++static
++int r8152_submit_rx(struct r8152 *tp, struct rx_agg *agg, gfp_t mem_flags);
++
++static inline void set_ethernet_addr(struct r8152 *tp)
++{
++ struct net_device *dev = tp->netdev;
++ u8 node_id[8] = {0};
++
++ if (pla_ocp_read(tp, PLA_IDR, sizeof(node_id), node_id) < 0)
++ netif_notice(tp, probe, dev, "inet addr fail\n");
++ else {
++ memcpy(dev->dev_addr, node_id, dev->addr_len);
++ memcpy(dev->perm_addr, dev->dev_addr, dev->addr_len);
++ }
++}
+
+static int rtl8152_set_mac_address(struct net_device *netdev, void *p)
+{
+ struct r8152 *tp = netdev_priv(netdev);
+ struct sockaddr *addr = p;
-+ int ret = -EADDRNOTAVAIL;
+
+ if (!is_valid_ether_addr(addr->sa_data))
-+ goto out1;
-+
-+ ret = usb_autopm_get_interface(tp->intf);
-+ if (ret < 0)
-+ goto out1;
-+
-+ mutex_lock(&tp->control);
++ return -EADDRNOTAVAIL;
+
+ memcpy(netdev->dev_addr, addr->sa_data, netdev->addr_len);
+
+ pla_ocp_write(tp, PLA_IDR, BYTE_EN_SIX_BYTES, 8, addr->sa_data);
+ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_CRWECR, CRWECR_NORAML);
+
-+ mutex_unlock(&tp->control);
-+
-+ usb_autopm_put_interface(tp->intf);
-+out1:
-+ return ret;
++ return 0;
+}
+
-+static int set_ethernet_addr(struct r8152 *tp)
++static struct net_device_stats *rtl8152_get_stats(struct net_device *dev)
+{
-+ struct net_device *dev = tp->netdev;
-+ struct sockaddr sa;
-+ int ret;
-+
-+ if (tp->version == RTL_VER_01)
-+ ret = pla_ocp_read(tp, PLA_IDR, 8, sa.sa_data);
-+ else
-+ ret = pla_ocp_read(tp, PLA_BACKUP, 8, sa.sa_data);
-+
-+ if (ret < 0) {
-+ netif_err(tp, probe, dev, "Get ether addr fail\n");
-+ } else if (!is_valid_ether_addr(sa.sa_data)) {
-+ netif_err(tp, probe, dev, "Invalid ether addr %pM\n",
-+ sa.sa_data);
-+ eth_hw_addr_random(dev);
-+ ether_addr_copy(sa.sa_data, dev->dev_addr);
-+ ret = rtl8152_set_mac_address(dev, &sa);
-+ netif_info(tp, probe, dev, "Random ether addr %pM\n",
-+ sa.sa_data);
-+ } else {
-+ if (tp->version == RTL_VER_01)
-+ ether_addr_copy(dev->dev_addr, sa.sa_data);
-+ else
-+ ret = rtl8152_set_mac_address(dev, &sa);
-+ }
-+
-+ return ret;
++ return &dev->stats;
+}
+
+static void read_bulk_callback(struct urb *urb)
+{
+ struct net_device *netdev;
++ unsigned long flags;
+ int status = urb->status;
+ struct rx_agg *agg;
+ struct r8152 *tp;
+ if (!netif_carrier_ok(netdev))
+ return;
+
-+ usb_mark_last_busy(tp->udev);
-+
+ switch (status) {
+ case 0:
+ if (urb->actual_length < ETH_ZLEN)
+ break;
+
-+ spin_lock(&tp->rx_lock);
++ spin_lock_irqsave(&tp->rx_lock, flags);
+ list_add_tail(&agg->list, &tp->rx_done);
-+ spin_unlock(&tp->rx_lock);
++ spin_unlock_irqrestore(&tp->rx_lock, flags);
+ tasklet_schedule(&tp->tl);
+ return;
+ case -ESHUTDOWN:
+ if (result == -ENODEV) {
+ netif_device_detach(tp->netdev);
+ } else if (result) {
-+ spin_lock(&tp->rx_lock);
++ spin_lock_irqsave(&tp->rx_lock, flags);
+ list_add_tail(&agg->list, &tp->rx_done);
-+ spin_unlock(&tp->rx_lock);
++ spin_unlock_irqrestore(&tp->rx_lock, flags);
+ tasklet_schedule(&tp->tl);
+ }
+}
+static void write_bulk_callback(struct urb *urb)
+{
+ struct net_device_stats *stats;
-+ struct net_device *netdev;
++ unsigned long flags;
+ struct tx_agg *agg;
+ struct r8152 *tp;
+ int status = urb->status;
+ if (!tp)
+ return;
+
-+ netdev = tp->netdev;
-+ stats = &netdev->stats;
++ stats = rtl8152_get_stats(tp->netdev);
+ if (status) {
+ if (net_ratelimit())
-+ netdev_warn(netdev, "Tx status %d\n", status);
++ netdev_warn(tp->netdev, "Tx status %d\n", status);
+ stats->tx_errors += agg->skb_num;
+ } else {
+ stats->tx_packets += agg->skb_num;
+ stats->tx_bytes += agg->skb_len;
+ }
+
-+ spin_lock(&tp->tx_lock);
++ spin_lock_irqsave(&tp->tx_lock, flags);
+ list_add_tail(&agg->list, &tp->tx_free);
-+ spin_unlock(&tp->tx_lock);
-+
-+ usb_autopm_put_interface_async(tp->intf);
++ spin_unlock_irqrestore(&tp->tx_lock, flags);
+
-+ if (!netif_carrier_ok(netdev))
++ if (!netif_carrier_ok(tp->netdev))
+ return;
+
+ if (!test_bit(WORK_ENABLE, &tp->flags))
+ case -ESHUTDOWN:
+ netif_device_detach(tp->netdev);
+ case -ENOENT:
-+ case -EPROTO:
-+ netif_info(tp, intr, tp->netdev,
-+ "Stop submitting intr, status %d\n", status);
+ return;
+ case -EOVERFLOW:
+ netif_info(tp, intr, tp->netdev, "intr status -EOVERFLOW\n");
+ skb_queue_head_init(&tp->tx_queue);
+
+ for (i = 0; i < RTL8152_MAX_RX; i++) {
-+ buf = kmalloc_node(agg_buf_sz, GFP_KERNEL, node);
++ buf = kmalloc_node(rx_buf_sz, GFP_KERNEL, node);
+ if (!buf)
+ goto err1;
+
+ if (buf != rx_agg_align(buf)) {
+ kfree(buf);
-+ buf = kmalloc_node(agg_buf_sz + RX_ALIGN, GFP_KERNEL,
++ buf = kmalloc_node(rx_buf_sz + RX_ALIGN, GFP_KERNEL,
+ node);
+ if (!buf)
+ goto err1;
+ }
+
+ for (i = 0; i < RTL8152_MAX_TX; i++) {
-+ buf = kmalloc_node(agg_buf_sz, GFP_KERNEL, node);
++ buf = kmalloc_node(rx_buf_sz, GFP_KERNEL, node);
+ if (!buf)
+ goto err1;
+
+ if (buf != tx_agg_align(buf)) {
+ kfree(buf);
-+ buf = kmalloc_node(agg_buf_sz + TX_ALIGN, GFP_KERNEL,
++ buf = kmalloc_node(rx_buf_sz + TX_ALIGN, GFP_KERNEL,
+ node);
+ if (!buf)
+ goto err1;
+
+ tp->intr_interval = (int)ep_intr->desc.bInterval;
+ usb_fill_int_urb(tp->intr_urb, tp->udev, usb_rcvintpipe(tp->udev, 3),
-+ tp->intr_buff, INTBUFSIZE, intr_callback,
-+ tp, tp->intr_interval);
++ tp->intr_buff, INTBUFSIZE, intr_callback,
++ tp, tp->intr_interval);
+
+ return 0;
+
+ struct tx_agg *agg = NULL;
+ unsigned long flags;
+
-+ if (list_empty(&tp->tx_free))
-+ return NULL;
-+
+ spin_lock_irqsave(&tp->tx_lock, flags);
+ if (!list_empty(&tp->tx_free)) {
+ struct list_head *cursor;
+ return agg;
+}
+
-+static inline __be16 get_protocol(struct sk_buff *skb)
-+{
-+ __be16 protocol;
-+
-+ if (skb->protocol == htons(ETH_P_8021Q))
-+ protocol = vlan_eth_hdr(skb)->h_vlan_encapsulated_proto;
-+ else
-+ protocol = skb->protocol;
-+
-+ return protocol;
-+}
-+
-+/* r8152_csum_workaround()
-+ * The hw limites the value the transport offset. When the offset is out of the
-+ * range, calculate the checksum by sw.
-+ */
-+static void r8152_csum_workaround(struct r8152 *tp, struct sk_buff *skb,
-+ struct sk_buff_head *list)
-+{
-+ if (skb_shinfo(skb)->gso_size) {
-+ netdev_features_t features = tp->netdev->features;
-+ struct sk_buff_head seg_list;
-+ struct sk_buff *segs, *nskb;
-+
-+ features &= ~(NETIF_F_SG | NETIF_F_IPV6_CSUM | NETIF_F_TSO6);
-+ segs = skb_gso_segment(skb, features);
-+ if (IS_ERR(segs) || !segs)
-+ goto drop;
-+
-+ __skb_queue_head_init(&seg_list);
-+
-+ do {
-+ nskb = segs;
-+ segs = segs->next;
-+ nskb->next = NULL;
-+ __skb_queue_tail(&seg_list, nskb);
-+ } while (segs);
-+
-+ skb_queue_splice(&seg_list, list);
-+ dev_kfree_skb(skb);
-+ } else if (skb->ip_summed == CHECKSUM_PARTIAL) {
-+ if (skb_checksum_help(skb) < 0)
-+ goto drop;
-+
-+ __skb_queue_head(list, skb);
-+ } else {
-+ struct net_device_stats *stats;
-+
-+drop:
-+ stats = &tp->netdev->stats;
-+ stats->tx_dropped++;
-+ dev_kfree_skb(skb);
-+ }
-+}
-+
-+/* msdn_giant_send_check()
-+ * According to the document of microsoft, the TCP Pseudo Header excludes the
-+ * packet length for IPv6 TCP large packets.
-+ */
-+static int msdn_giant_send_check(struct sk_buff *skb)
-+{
-+ const struct ipv6hdr *ipv6h;
-+ struct tcphdr *th;
-+ int ret;
-+
-+ ret = skb_cow_head(skb, 0);
-+ if (ret)
-+ return ret;
-+
-+ ipv6h = ipv6_hdr(skb);
-+ th = tcp_hdr(skb);
-+
-+ th->check = 0;
-+ th->check = ~tcp_v6_check(0, &ipv6h->saddr, &ipv6h->daddr, 0);
-+
-+ return ret;
-+}
-+
-+static inline void rtl_tx_vlan_tag(struct tx_desc *desc, struct sk_buff *skb)
-+{
-+ if (vlan_tx_tag_present(skb)) {
-+ u32 opts2;
-+
-+ opts2 = TX_VLAN_TAG | swab16(vlan_tx_tag_get(skb));
-+ desc->opts2 |= cpu_to_le32(opts2);
-+ }
-+}
-+
-+static inline void rtl_rx_vlan_tag(struct rx_desc *desc, struct sk_buff *skb)
-+{
-+ u32 opts2 = le32_to_cpu(desc->opts2);
-+
-+ if (opts2 & RX_VLAN_TAG)
-+ __vlan_hwaccel_put_tag(skb, htons(ETH_P_8021Q),
-+ swab16(opts2 & 0xffff));
-+}
-+
-+static int r8152_tx_csum(struct r8152 *tp, struct tx_desc *desc,
-+ struct sk_buff *skb, u32 len, u32 transport_offset)
++static void
++r8152_tx_csum(struct r8152 *tp, struct tx_desc *desc, struct sk_buff *skb)
+{
-+ u32 mss = skb_shinfo(skb)->gso_size;
-+ u32 opts1, opts2 = 0;
-+ int ret = TX_CSUM_SUCCESS;
-+
-+ WARN_ON_ONCE(len > TX_LEN_MAX);
-+
-+ opts1 = len | TX_FS | TX_LS;
-+
-+ if (mss) {
-+ if (transport_offset > GTTCPHO_MAX) {
-+ netif_warn(tp, tx_err, tp->netdev,
-+ "Invalid transport offset 0x%x for TSO\n",
-+ transport_offset);
-+ ret = TX_CSUM_TSO;
-+ goto unavailable;
-+ }
-+
-+ switch (get_protocol(skb)) {
-+ case htons(ETH_P_IP):
-+ opts1 |= GTSENDV4;
-+ break;
-+
-+ case htons(ETH_P_IPV6):
-+ if (msdn_giant_send_check(skb)) {
-+ ret = TX_CSUM_TSO;
-+ goto unavailable;
-+ }
-+ opts1 |= GTSENDV6;
-+ break;
++ memset(desc, 0, sizeof(*desc));
+
-+ default:
-+ WARN_ON_ONCE(1);
-+ break;
-+ }
++ desc->opts1 = cpu_to_le32((skb->len & TX_LEN_MASK) | TX_FS | TX_LS);
+
-+ opts1 |= transport_offset << GTTCPHO_SHIFT;
-+ opts2 |= min(mss, MSS_MAX) << MSS_SHIFT;
-+ } else if (skb->ip_summed == CHECKSUM_PARTIAL) {
++ if (skb->ip_summed == CHECKSUM_PARTIAL) {
++ __be16 protocol;
+ u8 ip_protocol;
++ u32 opts2 = 0;
+
-+ if (transport_offset > TCPHO_MAX) {
-+ netif_warn(tp, tx_err, tp->netdev,
-+ "Invalid transport offset 0x%x\n",
-+ transport_offset);
-+ ret = TX_CSUM_NONE;
-+ goto unavailable;
-+ }
++ if (skb->protocol == htons(ETH_P_8021Q))
++ protocol = vlan_eth_hdr(skb)->h_vlan_encapsulated_proto;
++ else
++ protocol = skb->protocol;
+
-+ switch (get_protocol(skb)) {
++ switch (protocol) {
+ case htons(ETH_P_IP):
+ opts2 |= IPV4_CS;
+ ip_protocol = ip_hdr(skb)->protocol;
+ break;
+ }
+
-+ if (ip_protocol == IPPROTO_TCP)
++ if (ip_protocol == IPPROTO_TCP) {
+ opts2 |= TCP_CS;
-+ else if (ip_protocol == IPPROTO_UDP)
++ opts2 |= (skb_transport_offset(skb) & 0x7fff) << 17;
++ } else if (ip_protocol == IPPROTO_UDP) {
+ opts2 |= UDP_CS;
-+ else
++ } else {
+ WARN_ON_ONCE(1);
++ }
+
-+ opts2 |= transport_offset << TCPHO_SHIFT;
++ desc->opts2 = cpu_to_le32(opts2);
+ }
-+
-+ desc->opts2 = cpu_to_le32(opts2);
-+ desc->opts1 = cpu_to_le32(opts1);
-+
-+unavailable:
-+ return ret;
+}
+
+static int r8152_tx_agg_fill(struct r8152 *tp, struct tx_agg *agg)
+{
-+ struct sk_buff_head skb_head, *tx_queue = &tp->tx_queue;
-+ int remain, ret;
++ int remain;
+ u8 *tx_data;
+
-+ __skb_queue_head_init(&skb_head);
-+ spin_lock(&tx_queue->lock);
-+ skb_queue_splice_init(tx_queue, &skb_head);
-+ spin_unlock(&tx_queue->lock);
-+
+ tx_data = agg->head;
-+ agg->skb_num = 0;
-+ agg->skb_len = 0;
-+ remain = agg_buf_sz;
++ agg->skb_num = agg->skb_len = 0;
++ remain = rx_buf_sz;
+
+ while (remain >= ETH_ZLEN + sizeof(struct tx_desc)) {
+ struct tx_desc *tx_desc;
+ struct sk_buff *skb;
+ unsigned int len;
-+ u32 offset;
+
-+ skb = __skb_dequeue(&skb_head);
++ skb = skb_dequeue(&tp->tx_queue);
+ if (!skb)
+ break;
+
-+ len = skb->len + sizeof(*tx_desc);
-+
-+ if (len > remain) {
-+ __skb_queue_head(&skb_head, skb);
++ remain -= sizeof(*tx_desc);
++ len = skb->len;
++ if (remain < len) {
++ skb_queue_head(&tp->tx_queue, skb);
+ break;
+ }
+
+ tx_data = tx_agg_align(tx_data);
+ tx_desc = (struct tx_desc *)tx_data;
-+
-+ offset = (u32)skb_transport_offset(skb);
-+
-+ if (r8152_tx_csum(tp, tx_desc, skb, skb->len, offset)) {
-+ r8152_csum_workaround(tp, skb, &skb_head);
-+ continue;
-+ }
-+
-+ rtl_tx_vlan_tag(tx_desc, skb);
-+
+ tx_data += sizeof(*tx_desc);
+
-+ len = skb->len;
-+ if (skb_copy_bits(skb, 0, tx_data, len) < 0) {
-+ struct net_device_stats *stats = &tp->netdev->stats;
-+
-+ stats->tx_dropped++;
-+ dev_kfree_skb_any(skb);
-+ tx_data -= sizeof(*tx_desc);
-+ continue;
-+ }
-+
-+ tx_data += len;
-+ agg->skb_len += len;
++ r8152_tx_csum(tp, tx_desc, skb);
++ memcpy(tx_data, skb->data, len);
+ agg->skb_num++;
-+
++ agg->skb_len += len;
+ dev_kfree_skb_any(skb);
+
-+ remain = agg_buf_sz - (int)(tx_agg_align(tx_data) - agg->head);
-+ }
-+
-+ if (!skb_queue_empty(&skb_head)) {
-+ spin_lock(&tx_queue->lock);
-+ skb_queue_splice(&skb_head, tx_queue);
-+ spin_unlock(&tx_queue->lock);
++ tx_data += len;
++ remain = rx_buf_sz - (int)(tx_agg_align(tx_data) - agg->head);
+ }
+
+ netif_tx_lock(tp->netdev);
+
+ netif_tx_unlock(tp->netdev);
+
-+ ret = usb_autopm_get_interface_async(tp->intf);
-+ if (ret < 0)
-+ goto out_tx_fill;
-+
+ usb_fill_bulk_urb(agg->urb, tp->udev, usb_sndbulkpipe(tp->udev, 2),
+ agg->head, (int)(tx_data - (u8 *)agg->head),
+ (usb_complete_t)write_bulk_callback, agg);
+
-+ ret = usb_submit_urb(agg->urb, GFP_ATOMIC);
-+ if (ret < 0)
-+ usb_autopm_put_interface_async(tp->intf);
-+
-+out_tx_fill:
-+ return ret;
-+}
-+
-+static u8 r8152_rx_csum(struct r8152 *tp, struct rx_desc *rx_desc)
-+{
-+ u8 checksum = CHECKSUM_NONE;
-+ u32 opts2, opts3;
-+
-+ if (tp->version == RTL_VER_01)
-+ goto return_result;
-+
-+ opts2 = le32_to_cpu(rx_desc->opts2);
-+ opts3 = le32_to_cpu(rx_desc->opts3);
-+
-+ if (opts2 & RD_IPV4_CS) {
-+ if (opts3 & IPF)
-+ checksum = CHECKSUM_NONE;
-+ else if ((opts2 & RD_UDP_CS) && (opts3 & UDPF))
-+ checksum = CHECKSUM_NONE;
-+ else if ((opts2 & RD_TCP_CS) && (opts3 & TCPF))
-+ checksum = CHECKSUM_NONE;
-+ else
-+ checksum = CHECKSUM_UNNECESSARY;
-+ } else if (RD_IPV6_CS) {
-+ if ((opts2 & RD_UDP_CS) && !(opts3 & UDPF))
-+ checksum = CHECKSUM_UNNECESSARY;
-+ else if ((opts2 & RD_TCP_CS) && !(opts3 & TCPF))
-+ checksum = CHECKSUM_UNNECESSARY;
-+ }
-+
-+return_result:
-+ return checksum;
++ return usb_submit_urb(agg->urb, GFP_ATOMIC);
+}
+
+static void rx_bottom(struct r8152 *tp)
+{
+ unsigned long flags;
-+ struct list_head *cursor, *next, rx_queue;
-+
-+ if (list_empty(&tp->rx_done))
-+ return;
++ struct list_head *cursor, *next;
+
-+ INIT_LIST_HEAD(&rx_queue);
+ spin_lock_irqsave(&tp->rx_lock, flags);
-+ list_splice_init(&tp->rx_done, &rx_queue);
-+ spin_unlock_irqrestore(&tp->rx_lock, flags);
-+
-+ list_for_each_safe(cursor, next, &rx_queue) {
++ list_for_each_safe(cursor, next, &tp->rx_done) {
+ struct rx_desc *rx_desc;
+ struct rx_agg *agg;
+ int len_used = 0;
+ int ret;
+
+ list_del_init(cursor);
++ spin_unlock_irqrestore(&tp->rx_lock, flags);
+
+ agg = list_entry(cursor, struct rx_agg, list);
+ urb = agg->urb;
+
+ while (urb->actual_length > len_used) {
+ struct net_device *netdev = tp->netdev;
-+ struct net_device_stats *stats = &netdev->stats;
++ struct net_device_stats *stats;
+ unsigned int pkt_len;
+ struct sk_buff *skb;
+
+ if (urb->actual_length < len_used)
+ break;
+
++ stats = rtl8152_get_stats(netdev);
++
+ pkt_len -= CRC_SIZE;
+ rx_data += sizeof(struct rx_desc);
+
+ skb = netdev_alloc_skb_ip_align(netdev, pkt_len);
+ if (!skb) {
+ stats->rx_dropped++;
-+ goto find_next_rx;
++ break;
+ }
-+
-+ skb->ip_summed = r8152_rx_csum(tp, rx_desc);
+ memcpy(skb->data, rx_data, pkt_len);
+ skb_put(skb, pkt_len);
+ skb->protocol = eth_type_trans(skb, netdev);
-+ rtl_rx_vlan_tag(rx_desc, skb);
-+ netif_receive_skb(skb);
++ netif_rx(skb);
+ stats->rx_packets++;
+ stats->rx_bytes += pkt_len;
+
-+find_next_rx:
+ rx_data = rx_agg_align(rx_data + pkt_len + CRC_SIZE);
+ rx_desc = (struct rx_desc *)rx_data;
+ len_used = (int)(rx_data - (u8 *)agg->head);
+
+submit:
+ ret = r8152_submit_rx(tp, agg, GFP_ATOMIC);
++ spin_lock_irqsave(&tp->rx_lock, flags);
+ if (ret && ret != -ENODEV) {
-+ spin_lock_irqsave(&tp->rx_lock, flags);
-+ list_add_tail(&agg->list, &tp->rx_done);
-+ spin_unlock_irqrestore(&tp->rx_lock, flags);
++ list_add_tail(&agg->list, next);
+ tasklet_schedule(&tp->tl);
+ }
+ }
++ spin_unlock_irqrestore(&tp->rx_lock, flags);
+}
+
+static void tx_bottom(struct r8152 *tp)
+
+ res = r8152_tx_agg_fill(tp, agg);
+ if (res) {
-+ struct net_device *netdev = tp->netdev;
++ struct net_device_stats *stats;
++ struct net_device *netdev;
++ unsigned long flags;
++
++ netdev = tp->netdev;
++ stats = rtl8152_get_stats(netdev);
+
+ if (res == -ENODEV) {
+ netif_device_detach(netdev);
+ } else {
-+ struct net_device_stats *stats = &netdev->stats;
-+ unsigned long flags;
-+
+ netif_warn(tp, tx_err, netdev,
+ "failed tx_urb %d\n", res);
+ stats->tx_dropped += agg->skb_num;
-+
+ spin_lock_irqsave(&tp->tx_lock, flags);
+ list_add_tail(&agg->list, &tp->tx_free);
+ spin_unlock_irqrestore(&tp->tx_lock, flags);
+int r8152_submit_rx(struct r8152 *tp, struct rx_agg *agg, gfp_t mem_flags)
+{
+ usb_fill_bulk_urb(agg->urb, tp->udev, usb_rcvbulkpipe(tp->udev, 1),
-+ agg->head, agg_buf_sz,
-+ (usb_complete_t)read_bulk_callback, agg);
++ agg->head, rx_buf_sz,
++ (usb_complete_t)read_bulk_callback, agg);
+
+ return usb_submit_urb(agg->urb, mem_flags);
+}
+
-+static void rtl_drop_queued_tx(struct r8152 *tp)
-+{
-+ struct net_device_stats *stats = &tp->netdev->stats;
-+ struct sk_buff_head skb_head, *tx_queue = &tp->tx_queue;
-+ struct sk_buff *skb;
-+
-+ if (skb_queue_empty(tx_queue))
-+ return;
-+
-+ __skb_queue_head_init(&skb_head);
-+ spin_lock_bh(&tx_queue->lock);
-+ skb_queue_splice_init(tx_queue, &skb_head);
-+ spin_unlock_bh(&tx_queue->lock);
-+
-+ while ((skb = __skb_dequeue(&skb_head))) {
-+ dev_kfree_skb(skb);
-+ stats->tx_dropped++;
-+ }
-+}
-+
+static void rtl8152_tx_timeout(struct net_device *netdev)
+{
+ struct r8152 *tp = netdev_priv(netdev);
+ /* Unconditionally log net taps. */
+ netif_notice(tp, link, netdev, "Promiscuous mode enabled\n");
+ ocp_data |= RCR_AM | RCR_AAP;
-+ mc_filter[1] = 0xffffffff;
-+ mc_filter[0] = 0xffffffff;
++ mc_filter[1] = mc_filter[0] = 0xffffffff;
+ } else if ((netdev_mc_count(netdev) > multicast_filter_limit) ||
+ (netdev->flags & IFF_ALLMULTI)) {
+ /* Too many to filter perfectly -- accept all multicasts. */
+ ocp_data |= RCR_AM;
-+ mc_filter[1] = 0xffffffff;
-+ mc_filter[0] = 0xffffffff;
++ mc_filter[1] = mc_filter[0] = 0xffffffff;
+ } else {
+ struct netdev_hw_addr *ha;
+
-+ mc_filter[1] = 0;
-+ mc_filter[0] = 0;
++ mc_filter[1] = mc_filter[0] = 0;
+ netdev_for_each_mc_addr(ha, netdev) {
+ int bit_nr = ether_crc(ETH_ALEN, ha->addr) >> 26;
-+
+ mc_filter[bit_nr >> 5] |= 1 << (bit_nr & 31);
+ ocp_data |= RCR_AM;
+ }
+}
+
+static netdev_tx_t rtl8152_start_xmit(struct sk_buff *skb,
-+ struct net_device *netdev)
++ struct net_device *netdev)
+{
+ struct r8152 *tp = netdev_priv(netdev);
+
+
+ skb_queue_tail(&tp->tx_queue, skb);
+
-+ if (!list_empty(&tp->tx_free)) {
-+ if (test_bit(SELECTIVE_SUSPEND, &tp->flags)) {
-+ set_bit(SCHEDULE_TASKLET, &tp->flags);
-+ schedule_delayed_work(&tp->schedule, 0);
-+ } else {
-+ usb_mark_last_busy(tp->udev);
-+ tasklet_schedule(&tp->tl);
-+ }
-+ } else if (skb_queue_len(&tp->tx_queue) > tp->tx_qlen) {
++ if (list_empty(&tp->tx_free) &&
++ skb_queue_len(&tp->tx_queue) > tp->tx_qlen)
+ netif_stop_queue(netdev);
-+ }
++
++ if (!list_empty(&tp->tx_free))
++ tasklet_schedule(&tp->tl);
+
+ return NETDEV_TX_OK;
+}
+ for (i = 0; i < 1000; i++) {
+ if (!(ocp_read_byte(tp, MCU_TYPE_PLA, PLA_CR) & CR_RST))
+ break;
-+ usleep_range(100, 400);
++ udelay(100);
+ }
+}
+
+{
+ struct net_device *netdev = tp->netdev;
+
-+ tp->tx_qlen = agg_buf_sz / (netdev->mtu + VLAN_ETH_HLEN + VLAN_HLEN +
-+ sizeof(struct tx_desc));
++ tp->tx_qlen = rx_buf_sz / (netdev->mtu + VLAN_ETH_HLEN + VLAN_HLEN +
++ sizeof(struct tx_desc));
+}
+
+static inline u8 rtl8152_get_speed(struct r8152 *tp)
+ }
+}
+
-+static void rxdy_gated_en(struct r8152 *tp, bool enable)
++static int rtl_enable(struct r8152 *tp)
+{
+ u32 ocp_data;
++ int i, ret;
++
++ r8152b_reset_packet_filter(tp);
++
++ ocp_data = ocp_read_byte(tp, MCU_TYPE_PLA, PLA_CR);
++ ocp_data |= CR_RE | CR_TE;
++ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_CR, ocp_data);
+
+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_MISC_1);
-+ if (enable)
-+ ocp_data |= RXDY_GATED_EN;
-+ else
-+ ocp_data &= ~RXDY_GATED_EN;
++ ocp_data &= ~RXDY_GATED_EN;
+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_MISC_1, ocp_data);
-+}
-+
-+static int rtl_start_rx(struct r8152 *tp)
-+{
-+ int i, ret = 0;
+
+ INIT_LIST_HEAD(&tp->rx_done);
++ ret = 0;
+ for (i = 0; i < RTL8152_MAX_RX; i++) {
+ INIT_LIST_HEAD(&tp->rx_info[i].list);
-+ ret = r8152_submit_rx(tp, &tp->rx_info[i], GFP_KERNEL);
-+ if (ret)
-+ break;
++ ret |= r8152_submit_rx(tp, &tp->rx_info[i], GFP_KERNEL);
+ }
+
+ return ret;
+}
+
-+static int rtl_stop_rx(struct r8152 *tp)
-+{
-+ int i;
-+
-+ for (i = 0; i < RTL8152_MAX_RX; i++)
-+ usb_kill_urb(tp->rx_info[i].urb);
-+
-+ return 0;
-+}
-+
-+static int rtl_enable(struct r8152 *tp)
-+{
-+ u32 ocp_data;
-+
-+ r8152b_reset_packet_filter(tp);
-+
-+ ocp_data = ocp_read_byte(tp, MCU_TYPE_PLA, PLA_CR);
-+ ocp_data |= CR_RE | CR_TE;
-+ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_CR, ocp_data);
-+
-+ rxdy_gated_en(tp, false);
-+
-+ return rtl_start_rx(tp);
-+}
-+
+static int rtl8152_enable(struct r8152 *tp)
+{
-+ if (test_bit(RTL8152_UNPLUG, &tp->flags))
-+ return -ENODEV;
-+
+ set_tx_qlen(tp);
+ rtl_set_eee_plus(tp);
+
+
+static int rtl8153_enable(struct r8152 *tp)
+{
-+ if (test_bit(RTL8152_UNPLUG, &tp->flags))
-+ return -ENODEV;
-+
+ set_tx_qlen(tp);
+ rtl_set_eee_plus(tp);
+ r8153_set_rx_agg(tp);
+ return rtl_enable(tp);
+}
+
-+static void rtl_disable(struct r8152 *tp)
++static void rtl8152_disable(struct r8152 *tp)
+{
++ struct net_device_stats *stats = rtl8152_get_stats(tp->netdev);
++ struct sk_buff *skb;
+ u32 ocp_data;
+ int i;
+
-+ if (test_bit(RTL8152_UNPLUG, &tp->flags)) {
-+ rtl_drop_queued_tx(tp);
-+ return;
-+ }
-+
+ ocp_data = ocp_read_dword(tp, MCU_TYPE_PLA, PLA_RCR);
+ ocp_data &= ~RCR_ACPT_ALL;
+ ocp_write_dword(tp, MCU_TYPE_PLA, PLA_RCR, ocp_data);
+
-+ rtl_drop_queued_tx(tp);
++ while ((skb = skb_dequeue(&tp->tx_queue))) {
++ dev_kfree_skb(skb);
++ stats->tx_dropped++;
++ }
+
+ for (i = 0; i < RTL8152_MAX_TX; i++)
+ usb_kill_urb(tp->tx_info[i].urb);
+
-+ rxdy_gated_en(tp, true);
++ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_MISC_1);
++ ocp_data |= RXDY_GATED_EN;
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_MISC_1, ocp_data);
+
+ for (i = 0; i < 1000; i++) {
+ ocp_data = ocp_read_byte(tp, MCU_TYPE_PLA, PLA_OOB_CTRL);
+ if ((ocp_data & FIFO_EMPTY) == FIFO_EMPTY)
+ break;
-+ usleep_range(1000, 2000);
++ mdelay(1);
+ }
+
+ for (i = 0; i < 1000; i++) {
+ if (ocp_read_word(tp, MCU_TYPE_PLA, PLA_TCR0) & TCR0_TX_EMPTY)
+ break;
-+ usleep_range(1000, 2000);
++ mdelay(1);
+ }
+
-+ rtl_stop_rx(tp);
++ for (i = 0; i < RTL8152_MAX_RX; i++)
++ usb_kill_urb(tp->rx_info[i].urb);
+
+ rtl8152_nic_reset(tp);
+}
+
-+static void r8152_power_cut_en(struct r8152 *tp, bool enable)
-+{
-+ u32 ocp_data;
-+
-+ ocp_data = ocp_read_word(tp, MCU_TYPE_USB, USB_UPS_CTRL);
-+ if (enable)
-+ ocp_data |= POWER_CUT;
-+ else
-+ ocp_data &= ~POWER_CUT;
-+ ocp_write_word(tp, MCU_TYPE_USB, USB_UPS_CTRL, ocp_data);
-+
-+ ocp_data = ocp_read_word(tp, MCU_TYPE_USB, USB_PM_CTRL_STATUS);
-+ ocp_data &= ~RESUME_INDICATE;
-+ ocp_write_word(tp, MCU_TYPE_USB, USB_PM_CTRL_STATUS, ocp_data);
-+}
-+
-+static void rtl_rx_vlan_en(struct r8152 *tp, bool enable)
-+{
-+ u32 ocp_data;
-+
-+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_CPCR);
-+ if (enable)
-+ ocp_data |= CPCR_RX_VLAN;
-+ else
-+ ocp_data &= ~CPCR_RX_VLAN;
-+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_CPCR, ocp_data);
-+}
-+
-+static int rtl8152_set_features(struct net_device *dev,
-+ netdev_features_t features)
-+{
-+ netdev_features_t changed = features ^ dev->features;
-+ struct r8152 *tp = netdev_priv(dev);
-+ int ret;
-+
-+ ret = usb_autopm_get_interface(tp->intf);
-+ if (ret < 0)
-+ goto out;
-+
-+ mutex_lock(&tp->control);
-+
-+ if (changed & NETIF_F_HW_VLAN_CTAG_RX) {
-+ if (features & NETIF_F_HW_VLAN_CTAG_RX)
-+ rtl_rx_vlan_en(tp, true);
-+ else
-+ rtl_rx_vlan_en(tp, false);
-+ }
-+
-+ mutex_unlock(&tp->control);
-+
-+ usb_autopm_put_interface(tp->intf);
-+
-+out:
-+ return ret;
-+}
-+
-+#define WAKE_ANY (WAKE_PHY | WAKE_MAGIC | WAKE_UCAST | WAKE_BCAST | WAKE_MCAST)
-+
-+static u32 __rtl_get_wol(struct r8152 *tp)
-+{
-+ u32 ocp_data;
-+ u32 wolopts = 0;
-+
-+ ocp_data = ocp_read_byte(tp, MCU_TYPE_PLA, PLA_CONFIG5);
-+ if (!(ocp_data & LAN_WAKE_EN))
-+ return 0;
-+
-+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_CONFIG34);
-+ if (ocp_data & LINK_ON_WAKE_EN)
-+ wolopts |= WAKE_PHY;
-+
-+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_CONFIG5);
-+ if (ocp_data & UWF_EN)
-+ wolopts |= WAKE_UCAST;
-+ if (ocp_data & BWF_EN)
-+ wolopts |= WAKE_BCAST;
-+ if (ocp_data & MWF_EN)
-+ wolopts |= WAKE_MCAST;
-+
-+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_CFG_WOL);
-+ if (ocp_data & MAGIC_EN)
-+ wolopts |= WAKE_MAGIC;
-+
-+ return wolopts;
-+}
-+
-+static void __rtl_set_wol(struct r8152 *tp, u32 wolopts)
-+{
-+ u32 ocp_data;
-+
-+ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_CRWECR, CRWECR_CONFIG);
-+
-+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_CONFIG34);
-+ ocp_data &= ~LINK_ON_WAKE_EN;
-+ if (wolopts & WAKE_PHY)
-+ ocp_data |= LINK_ON_WAKE_EN;
-+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_CONFIG34, ocp_data);
-+
-+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_CONFIG5);
-+ ocp_data &= ~(UWF_EN | BWF_EN | MWF_EN | LAN_WAKE_EN);
-+ if (wolopts & WAKE_UCAST)
-+ ocp_data |= UWF_EN;
-+ if (wolopts & WAKE_BCAST)
-+ ocp_data |= BWF_EN;
-+ if (wolopts & WAKE_MCAST)
-+ ocp_data |= MWF_EN;
-+ if (wolopts & WAKE_ANY)
-+ ocp_data |= LAN_WAKE_EN;
-+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_CONFIG5, ocp_data);
-+
-+ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_CRWECR, CRWECR_NORAML);
-+
-+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_CFG_WOL);
-+ ocp_data &= ~MAGIC_EN;
-+ if (wolopts & WAKE_MAGIC)
-+ ocp_data |= MAGIC_EN;
-+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_CFG_WOL, ocp_data);
-+
-+ if (wolopts & WAKE_ANY)
-+ device_set_wakeup_enable(&tp->udev->dev, true);
-+ else
-+ device_set_wakeup_enable(&tp->udev->dev, false);
-+}
-+
-+static void rtl_runtime_suspend_enable(struct r8152 *tp, bool enable)
-+{
-+ if (enable) {
-+ u32 ocp_data;
-+
-+ __rtl_set_wol(tp, WAKE_ANY);
-+
-+ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_CRWECR, CRWECR_CONFIG);
-+
-+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_CONFIG34);
-+ ocp_data |= LINK_OFF_WAKE_EN;
-+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_CONFIG34, ocp_data);
-+
-+ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_CRWECR, CRWECR_NORAML);
-+ } else {
-+ __rtl_set_wol(tp, tp->saved_wolopts);
-+ }
-+}
-+
-+static void rtl_phy_reset(struct r8152 *tp)
-+{
-+ u16 data;
-+ int i;
-+
-+ clear_bit(PHY_RESET, &tp->flags);
-+
-+ data = r8152_mdio_read(tp, MII_BMCR);
-+
-+ /* don't reset again before the previous one complete */
-+ if (data & BMCR_RESET)
-+ return;
-+
-+ data |= BMCR_RESET;
-+ r8152_mdio_write(tp, MII_BMCR, data);
-+
-+ for (i = 0; i < 50; i++) {
-+ msleep(20);
-+ if ((r8152_mdio_read(tp, MII_BMCR) & BMCR_RESET) == 0)
-+ break;
-+ }
-+}
-+
-+static void r8153_teredo_off(struct r8152 *tp)
-+{
-+ u32 ocp_data;
-+
-+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_TEREDO_CFG);
-+ ocp_data &= ~(TEREDO_SEL | TEREDO_RS_EVENT_MASK | OOB_TEREDO_EN);
-+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_TEREDO_CFG, ocp_data);
-+
-+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_WDT6_CTRL, WDT6_SET_MODE);
-+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_REALWOW_TIMER, 0);
-+ ocp_write_dword(tp, MCU_TYPE_PLA, PLA_TEREDO_TIMER, 0);
-+}
-+
-+static void r8152b_disable_aldps(struct r8152 *tp)
-+{
-+ ocp_reg_write(tp, OCP_ALDPS_CONFIG, ENPDNPS | LINKENA | DIS_SDSAVE);
-+ msleep(20);
-+}
-+
-+static inline void r8152b_enable_aldps(struct r8152 *tp)
-+{
-+ ocp_reg_write(tp, OCP_ALDPS_CONFIG, ENPWRSAVE | ENPDNPS |
-+ LINKENA | DIS_SDSAVE);
-+}
-+
-+static void rtl8152_disable(struct r8152 *tp)
-+{
-+ r8152b_disable_aldps(tp);
-+ rtl_disable(tp);
-+ r8152b_enable_aldps(tp);
-+}
-+
-+static void r8152b_hw_phy_cfg(struct r8152 *tp)
-+{
-+ u16 data;
-+
-+ data = r8152_mdio_read(tp, MII_BMCR);
-+ if (data & BMCR_PDOWN) {
-+ data &= ~BMCR_PDOWN;
-+ r8152_mdio_write(tp, MII_BMCR, data);
-+ }
-+
-+ set_bit(PHY_RESET, &tp->flags);
-+}
-+
+static void r8152b_exit_oob(struct r8152 *tp)
+{
-+ u32 ocp_data;
-+ int i;
++ u32 ocp_data;
++ int i;
+
+ ocp_data = ocp_read_dword(tp, MCU_TYPE_PLA, PLA_RCR);
+ ocp_data &= ~RCR_ACPT_ALL;
+ ocp_write_dword(tp, MCU_TYPE_PLA, PLA_RCR, ocp_data);
+
-+ rxdy_gated_en(tp, true);
-+ r8153_teredo_off(tp);
-+ r8152b_hw_phy_cfg(tp);
++ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_MISC_1);
++ ocp_data |= RXDY_GATED_EN;
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_MISC_1, ocp_data);
+
+ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_CRWECR, CRWECR_NORAML);
+ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_CR, 0x00);
+ ocp_data = ocp_read_byte(tp, MCU_TYPE_PLA, PLA_OOB_CTRL);
+ if (ocp_data & LINK_LIST_READY)
+ break;
-+ usleep_range(1000, 2000);
++ mdelay(1);
+ }
+
+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_SFF_STS_7);
+ ocp_data = ocp_read_byte(tp, MCU_TYPE_PLA, PLA_OOB_CTRL);
+ if (ocp_data & LINK_LIST_READY)
+ break;
-+ usleep_range(1000, 2000);
++ mdelay(1);
+ }
+
+ rtl8152_nic_reset(tp);
+ /* rx share fifo credit full threshold */
+ ocp_write_dword(tp, MCU_TYPE_PLA, PLA_RXFIFO_CTRL0, RXFIFO_THR1_NORMAL);
+
-+ if (tp->udev->speed == USB_SPEED_FULL ||
-+ tp->udev->speed == USB_SPEED_LOW) {
++ ocp_data = ocp_read_word(tp, MCU_TYPE_USB, USB_DEV_STAT);
++ ocp_data &= STAT_SPEED_MASK;
++ if (ocp_data == STAT_SPEED_FULL) {
+ /* rx share fifo credit near full threshold */
+ ocp_write_dword(tp, MCU_TYPE_PLA, PLA_RXFIFO_CTRL1,
+ RXFIFO_THR2_FULL);
+ ocp_write_dword(tp, MCU_TYPE_USB, USB_TX_DMA,
+ TEST_MODE_DISABLE | TX_SIZE_ADJUST1);
+
-+ rtl_rx_vlan_en(tp, tp->netdev->features & NETIF_F_HW_VLAN_CTAG_RX);
++ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_CPCR);
++ ocp_data &= ~CPCR_RX_VLAN;
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_CPCR, ocp_data);
+
+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_RMS, RTL8152_RMS);
+
+ ocp_write_dword(tp, MCU_TYPE_PLA, PLA_RXFIFO_CTRL1, RXFIFO_THR2_OOB);
+ ocp_write_dword(tp, MCU_TYPE_PLA, PLA_RXFIFO_CTRL2, RXFIFO_THR3_OOB);
+
-+ rtl_disable(tp);
++ rtl8152_disable(tp);
+
+ for (i = 0; i < 1000; i++) {
+ ocp_data = ocp_read_byte(tp, MCU_TYPE_PLA, PLA_OOB_CTRL);
+ if (ocp_data & LINK_LIST_READY)
+ break;
-+ usleep_range(1000, 2000);
++ mdelay(1);
+ }
+
+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_SFF_STS_7);
+ ocp_data = ocp_read_byte(tp, MCU_TYPE_PLA, PLA_OOB_CTRL);
+ if (ocp_data & LINK_LIST_READY)
+ break;
-+ usleep_range(1000, 2000);
++ mdelay(1);
+ }
+
+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_RMS, RTL8152_RMS);
+
-+ rtl_rx_vlan_en(tp, true);
++ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_CFG_WOL);
++ ocp_data |= MAGIC_EN;
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_CFG_WOL, ocp_data);
++
++ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_CPCR);
++ ocp_data |= CPCR_RX_VLAN;
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_CPCR, ocp_data);
+
+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PAL_BDC_CR);
+ ocp_data |= ALDPS_PROXY_MODE;
+ ocp_data |= NOW_IS_OOB | DIS_MCU_CLROOB;
+ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_OOB_CTRL, ocp_data);
+
-+ rxdy_gated_en(tp, false);
++ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_CONFIG5, LAN_WAKE_EN);
++
++ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_MISC_1);
++ ocp_data &= ~RXDY_GATED_EN;
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_MISC_1, ocp_data);
+
+ ocp_data = ocp_read_dword(tp, MCU_TYPE_PLA, PLA_RCR);
+ ocp_data |= RCR_APM | RCR_AM | RCR_AB;
+ ocp_write_dword(tp, MCU_TYPE_PLA, PLA_RCR, ocp_data);
+}
+
++static void r8152b_disable_aldps(struct r8152 *tp)
++{
++ ocp_reg_write(tp, OCP_ALDPS_CONFIG, ENPDNPS | LINKENA | DIS_SDSAVE);
++ msleep(20);
++}
++
++static inline void r8152b_enable_aldps(struct r8152 *tp)
++{
++ ocp_reg_write(tp, OCP_ALDPS_CONFIG, ENPWRSAVE | ENPDNPS |
++ LINKENA | DIS_SDSAVE);
++}
++
+static void r8153_hw_phy_cfg(struct r8152 *tp)
+{
+ u32 ocp_data;
+ u16 data;
+
+ ocp_reg_write(tp, OCP_ADC_CFG, CKADSEL_L | ADC_EN | EN_EMI_L);
-+ data = r8152_mdio_read(tp, MII_BMCR);
-+ if (data & BMCR_PDOWN) {
-+ data &= ~BMCR_PDOWN;
-+ r8152_mdio_write(tp, MII_BMCR, data);
-+ }
++ r8152_mdio_write(tp, MII_BMCR, BMCR_ANENABLE);
+
+ if (tp->version == RTL_VER_03) {
+ data = ocp_reg_read(tp, OCP_EEE_CFG);
+ data = sram_read(tp, SRAM_10M_AMP2);
+ data |= AMP_DN;
+ sram_write(tp, SRAM_10M_AMP2, data);
-+
-+ set_bit(PHY_RESET, &tp->flags);
+}
+
-+static void r8153_u1u2en(struct r8152 *tp, bool enable)
++static void r8153_u1u2en(struct r8152 *tp, int enable)
+{
+ u8 u1u2[8];
+
+ usb_ocp_write(tp, USB_TOLERANCE, BYTE_EN_SIX_BYTES, sizeof(u1u2), u1u2);
+}
+
-+static void r8153_u2p3en(struct r8152 *tp, bool enable)
++static void r8153_u2p3en(struct r8152 *tp, int enable)
+{
+ u32 ocp_data;
+
+ ocp_write_word(tp, MCU_TYPE_USB, USB_U2P3_CTRL, ocp_data);
+}
+
-+static void r8153_power_cut_en(struct r8152 *tp, bool enable)
++static void r8153_power_cut_en(struct r8152 *tp, int enable)
+{
+ u32 ocp_data;
+
+ ocp_write_word(tp, MCU_TYPE_USB, USB_MISC_0, ocp_data);
+}
+
++static void r8153_teredo_off(struct r8152 *tp)
++{
++ u32 ocp_data;
++
++ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_TEREDO_CFG);
++ ocp_data &= ~(TEREDO_SEL | TEREDO_RS_EVENT_MASK | OOB_TEREDO_EN);
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_TEREDO_CFG, ocp_data);
++
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_WDT6_CTRL, WDT6_SET_MODE);
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_REALWOW_TIMER, 0);
++ ocp_write_dword(tp, MCU_TYPE_PLA, PLA_TEREDO_TIMER, 0);
++}
++
+static void r8153_first_init(struct r8152 *tp)
+{
+ u32 ocp_data;
+ int i;
+
-+ rxdy_gated_en(tp, true);
++ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_MISC_1);
++ ocp_data |= RXDY_GATED_EN;
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_MISC_1, ocp_data);
++
+ r8153_teredo_off(tp);
+
+ ocp_data = ocp_read_dword(tp, MCU_TYPE_PLA, PLA_RCR);
+ ocp_data = ocp_read_byte(tp, MCU_TYPE_PLA, PLA_OOB_CTRL);
+ if (ocp_data & LINK_LIST_READY)
+ break;
-+ usleep_range(1000, 2000);
++ mdelay(1);
+ }
+
+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_SFF_STS_7);
+ ocp_data = ocp_read_byte(tp, MCU_TYPE_PLA, PLA_OOB_CTRL);
+ if (ocp_data & LINK_LIST_READY)
+ break;
-+ usleep_range(1000, 2000);
++ mdelay(1);
+ }
+
-+ rtl_rx_vlan_en(tp, tp->netdev->features & NETIF_F_HW_VLAN_CTAG_RX);
++ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_CPCR);
++ ocp_data &= ~CPCR_RX_VLAN;
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_CPCR, ocp_data);
+
-+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_RMS, RTL8153_RMS);
-+ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_MTPS, MTPS_JUMBO);
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_RMS, RTL8152_RMS);
+
+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_TCR0);
+ ocp_data |= TCR0_AUTO_FIFO;
+ ocp_data &= ~NOW_IS_OOB;
+ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_OOB_CTRL, ocp_data);
+
-+ rtl_disable(tp);
++ rtl8152_disable(tp);
+
+ for (i = 0; i < 1000; i++) {
+ ocp_data = ocp_read_byte(tp, MCU_TYPE_PLA, PLA_OOB_CTRL);
+ if (ocp_data & LINK_LIST_READY)
+ break;
-+ usleep_range(1000, 2000);
++ mdelay(1);
+ }
+
+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_SFF_STS_7);
+ ocp_data = ocp_read_byte(tp, MCU_TYPE_PLA, PLA_OOB_CTRL);
+ if (ocp_data & LINK_LIST_READY)
+ break;
-+ usleep_range(1000, 2000);
++ mdelay(1);
+ }
+
-+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_RMS, RTL8153_RMS);
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_RMS, RTL8152_RMS);
++
++ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_CFG_WOL);
++ ocp_data |= MAGIC_EN;
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_CFG_WOL, ocp_data);
+
+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_TEREDO_CFG);
+ ocp_data &= ~TEREDO_WAKE_MASK;
+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_TEREDO_CFG, ocp_data);
+
-+ rtl_rx_vlan_en(tp, true);
++ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_CPCR);
++ ocp_data |= CPCR_RX_VLAN;
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_CPCR, ocp_data);
+
+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PAL_BDC_CR);
+ ocp_data |= ALDPS_PROXY_MODE;
+ ocp_data |= NOW_IS_OOB | DIS_MCU_CLROOB;
+ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_OOB_CTRL, ocp_data);
+
-+ rxdy_gated_en(tp, false);
++ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_CONFIG5, LAN_WAKE_EN);
++
++ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_MISC_1);
++ ocp_data &= ~RXDY_GATED_EN;
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_MISC_1, ocp_data);
+
+ ocp_data = ocp_read_dword(tp, MCU_TYPE_PLA, PLA_RCR);
+ ocp_data |= RCR_APM | RCR_AM | RCR_AB;
+ ocp_reg_write(tp, OCP_POWER_CFG, data);
+}
+
-+static void rtl8153_disable(struct r8152 *tp)
-+{
-+ r8153_disable_aldps(tp);
-+ rtl_disable(tp);
-+ r8153_enable_aldps(tp);
-+}
-+
+static int rtl8152_set_speed(struct r8152 *tp, u8 autoneg, u16 speed, u8 duplex)
+{
+ u16 bmcr, anar, gbcr;
+ bmcr = BMCR_ANENABLE | BMCR_ANRESTART;
+ }
+
-+ if (test_bit(PHY_RESET, &tp->flags))
-+ bmcr |= BMCR_RESET;
-+
+ if (tp->mii.supports_gmii)
+ r8152_mdio_write(tp, MII_CTRL1000, gbcr);
+
+ r8152_mdio_write(tp, MII_ADVERTISE, anar);
+ r8152_mdio_write(tp, MII_BMCR, bmcr);
+
-+ if (test_bit(PHY_RESET, &tp->flags)) {
-+ int i;
-+
-+ clear_bit(PHY_RESET, &tp->flags);
-+ for (i = 0; i < 50; i++) {
-+ msleep(20);
-+ if ((r8152_mdio_read(tp, MII_BMCR) & BMCR_RESET) == 0)
-+ break;
-+ }
-+ }
-+
+out:
+
+ return ret;
+}
+
-+static void rtl8152_up(struct r8152 *tp)
-+{
-+ if (test_bit(RTL8152_UNPLUG, &tp->flags))
-+ return;
-+
-+ r8152b_disable_aldps(tp);
-+ r8152b_exit_oob(tp);
-+ r8152b_enable_aldps(tp);
-+}
-+
+static void rtl8152_down(struct r8152 *tp)
+{
-+ if (test_bit(RTL8152_UNPLUG, &tp->flags)) {
-+ rtl_drop_queued_tx(tp);
-+ return;
-+ }
++ u32 ocp_data;
++
++ ocp_data = ocp_read_word(tp, MCU_TYPE_USB, USB_UPS_CTRL);
++ ocp_data &= ~POWER_CUT;
++ ocp_write_word(tp, MCU_TYPE_USB, USB_UPS_CTRL, ocp_data);
+
-+ r8152_power_cut_en(tp, false);
+ r8152b_disable_aldps(tp);
+ r8152b_enter_oob(tp);
+ r8152b_enable_aldps(tp);
+}
+
-+static void rtl8153_up(struct r8152 *tp)
-+{
-+ if (test_bit(RTL8152_UNPLUG, &tp->flags))
-+ return;
-+
-+ r8153_disable_aldps(tp);
-+ r8153_first_init(tp);
-+ r8153_enable_aldps(tp);
-+}
-+
+static void rtl8153_down(struct r8152 *tp)
+{
-+ if (test_bit(RTL8152_UNPLUG, &tp->flags)) {
-+ rtl_drop_queued_tx(tp);
-+ return;
-+ }
-+
-+ r8153_u1u2en(tp, false);
-+ r8153_power_cut_en(tp, false);
++ r8153_u1u2en(tp, 0);
++ r8153_power_cut_en(tp, 0);
+ r8153_disable_aldps(tp);
+ r8153_enter_oob(tp);
+ r8153_enable_aldps(tp);
+{
+ struct r8152 *tp = container_of(work, struct r8152, schedule.work);
+
-+ if (usb_autopm_get_interface(tp->intf) < 0)
-+ return;
-+
+ if (!test_bit(WORK_ENABLE, &tp->flags))
+ goto out1;
+
+ if (test_bit(RTL8152_UNPLUG, &tp->flags))
+ goto out1;
+
-+ if (!mutex_trylock(&tp->control)) {
-+ schedule_delayed_work(&tp->schedule, 0);
-+ goto out1;
-+ }
-+
+ if (test_bit(RTL8152_LINK_CHG, &tp->flags))
+ set_carrier(tp);
+
+ if (test_bit(RTL8152_SET_RX_MODE, &tp->flags))
+ _rtl8152_set_rx_mode(tp->netdev);
+
-+ if (test_bit(SCHEDULE_TASKLET, &tp->flags) &&
-+ (tp->speed & LINK_STATUS)) {
-+ clear_bit(SCHEDULE_TASKLET, &tp->flags);
-+ tasklet_schedule(&tp->tl);
-+ }
-+
-+ if (test_bit(PHY_RESET, &tp->flags))
-+ rtl_phy_reset(tp);
-+
-+ mutex_unlock(&tp->control);
-+
+out1:
-+ usb_autopm_put_interface(tp->intf);
++ return;
+}
+
+static int rtl8152_open(struct net_device *netdev)
+ struct r8152 *tp = netdev_priv(netdev);
+ int res = 0;
+
-+ res = alloc_all_mem(tp);
-+ if (res)
-+ goto out;
-+
-+ /* set speed to 0 to avoid autoresume try to submit rx */
-+ tp->speed = 0;
-+
-+ res = usb_autopm_get_interface(tp->intf);
-+ if (res < 0) {
-+ free_all_mem(tp);
-+ goto out;
-+ }
-+
-+ mutex_lock(&tp->control);
-+
-+ /* The WORK_ENABLE may be set when autoresume occurs */
-+ if (test_bit(WORK_ENABLE, &tp->flags)) {
-+ clear_bit(WORK_ENABLE, &tp->flags);
-+ usb_kill_urb(tp->intr_urb);
-+ cancel_delayed_work_sync(&tp->schedule);
-+
-+ /* disable the tx/rx, if the workqueue has enabled them. */
-+ if (tp->speed & LINK_STATUS)
-+ tp->rtl_ops.disable(tp);
-+ }
-+
-+ tp->rtl_ops.up(tp);
-+
+ rtl8152_set_speed(tp, AUTONEG_ENABLE,
+ tp->mii.supports_gmii ? SPEED_1000 : SPEED_100,
+ DUPLEX_FULL);
+ netif_carrier_off(netdev);
+ netif_start_queue(netdev);
+ set_bit(WORK_ENABLE, &tp->flags);
-+
+ res = usb_submit_urb(tp->intr_urb, GFP_KERNEL);
+ if (res) {
+ if (res == -ENODEV)
+ netif_device_detach(tp->netdev);
+ netif_warn(tp, ifup, netdev, "intr_urb submit failed: %d\n",
+ res);
-+ free_all_mem(tp);
+ }
+
-+ mutex_unlock(&tp->control);
-+
-+ usb_autopm_put_interface(tp->intf);
+
-+out:
+ return res;
+}
+
+ usb_kill_urb(tp->intr_urb);
+ cancel_delayed_work_sync(&tp->schedule);
+ netif_stop_queue(netdev);
-+
-+ res = usb_autopm_get_interface(tp->intf);
-+ if (res < 0) {
-+ rtl_drop_queued_tx(tp);
-+ } else {
-+ mutex_lock(&tp->control);
-+
-+ /* The autosuspend may have been enabled and wouldn't
-+ * be disable when autoresume occurs, because the
-+ * netif_running() would be false.
-+ */
-+ rtl_runtime_suspend_enable(tp, false);
-+
-+ tasklet_disable(&tp->tl);
-+ tp->rtl_ops.down(tp);
-+ tasklet_enable(&tp->tl);
-+
-+ mutex_unlock(&tp->control);
-+
-+ usb_autopm_put_interface(tp->intf);
-+ }
-+
-+ free_all_mem(tp);
++ tasklet_disable(&tp->tl);
++ tp->rtl_ops.disable(tp);
++ tasklet_enable(&tp->tl);
+
+ return res;
+}
+
-+static inline void r8152_mmd_indirect(struct r8152 *tp, u16 dev, u16 reg)
-+{
-+ ocp_reg_write(tp, OCP_EEE_AR, FUN_ADDR | dev);
-+ ocp_reg_write(tp, OCP_EEE_DATA, reg);
-+ ocp_reg_write(tp, OCP_EEE_AR, FUN_DATA | dev);
-+}
-+
-+static u16 r8152_mmd_read(struct r8152 *tp, u16 dev, u16 reg)
++static void rtl_clear_bp(struct r8152 *tp)
+{
-+ u16 data;
-+
-+ r8152_mmd_indirect(tp, dev, reg);
-+ data = ocp_reg_read(tp, OCP_EEE_DATA);
-+ ocp_reg_write(tp, OCP_EEE_AR, 0x0000);
-+
-+ return data;
++ ocp_write_dword(tp, MCU_TYPE_PLA, PLA_BP_0, 0);
++ ocp_write_dword(tp, MCU_TYPE_PLA, PLA_BP_2, 0);
++ ocp_write_dword(tp, MCU_TYPE_PLA, PLA_BP_4, 0);
++ ocp_write_dword(tp, MCU_TYPE_PLA, PLA_BP_6, 0);
++ ocp_write_dword(tp, MCU_TYPE_USB, USB_BP_0, 0);
++ ocp_write_dword(tp, MCU_TYPE_USB, USB_BP_2, 0);
++ ocp_write_dword(tp, MCU_TYPE_USB, USB_BP_4, 0);
++ ocp_write_dword(tp, MCU_TYPE_USB, USB_BP_6, 0);
++ mdelay(3);
++ ocp_write_word(tp, MCU_TYPE_PLA, PLA_BP_BA, 0);
++ ocp_write_word(tp, MCU_TYPE_USB, USB_BP_BA, 0);
+}
+
-+static void r8152_mmd_write(struct r8152 *tp, u16 dev, u16 reg, u16 data)
++static void r8153_clear_bp(struct r8152 *tp)
+{
-+ r8152_mmd_indirect(tp, dev, reg);
-+ ocp_reg_write(tp, OCP_EEE_DATA, data);
-+ ocp_reg_write(tp, OCP_EEE_AR, 0x0000);
++ ocp_write_byte(tp, MCU_TYPE_PLA, PLA_BP_EN, 0);
++ ocp_write_byte(tp, MCU_TYPE_USB, USB_BP_EN, 0);
++ rtl_clear_bp(tp);
+}
+
-+static void r8152_eee_en(struct r8152 *tp, bool enable)
++static void r8152b_enable_eee(struct r8152 *tp)
+{
-+ u16 config1, config2, config3;
+ u32 ocp_data;
+
+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_EEE_CR);
-+ config1 = ocp_reg_read(tp, OCP_EEE_CONFIG1) & ~sd_rise_time_mask;
-+ config2 = ocp_reg_read(tp, OCP_EEE_CONFIG2);
-+ config3 = ocp_reg_read(tp, OCP_EEE_CONFIG3) & ~fast_snr_mask;
-+
-+ if (enable) {
-+ ocp_data |= EEE_RX_EN | EEE_TX_EN;
-+ config1 |= EEE_10_CAP | EEE_NWAY_EN | TX_QUIET_EN | RX_QUIET_EN;
-+ config1 |= sd_rise_time(1);
-+ config2 |= RG_DACQUIET_EN | RG_LDVQUIET_EN;
-+ config3 |= fast_snr(42);
-+ } else {
-+ ocp_data &= ~(EEE_RX_EN | EEE_TX_EN);
-+ config1 &= ~(EEE_10_CAP | EEE_NWAY_EN | TX_QUIET_EN |
-+ RX_QUIET_EN);
-+ config1 |= sd_rise_time(7);
-+ config2 &= ~(RG_DACQUIET_EN | RG_LDVQUIET_EN);
-+ config3 |= fast_snr(511);
-+ }
-+
++ ocp_data |= EEE_RX_EN | EEE_TX_EN;
+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_EEE_CR, ocp_data);
-+ ocp_reg_write(tp, OCP_EEE_CONFIG1, config1);
-+ ocp_reg_write(tp, OCP_EEE_CONFIG2, config2);
-+ ocp_reg_write(tp, OCP_EEE_CONFIG3, config3);
-+}
-+
-+static void r8152b_enable_eee(struct r8152 *tp)
-+{
-+ r8152_eee_en(tp, true);
-+ r8152_mmd_write(tp, MDIO_MMD_AN, MDIO_AN_EEE_ADV, MDIO_EEE_100TX);
++ ocp_reg_write(tp, OCP_EEE_CONFIG1, RG_TXLPI_MSK_HFDUP | RG_MATCLR_EN |
++ EEE_10_CAP | EEE_NWAY_EN |
++ TX_QUIET_EN | RX_QUIET_EN |
++ SDRISETIME | RG_RXLPI_MSK_HFDUP |
++ SDFALLTIME);
++ ocp_reg_write(tp, OCP_EEE_CONFIG2, RG_LPIHYS_NUM | RG_DACQUIET_EN |
++ RG_LDVQUIET_EN | RG_CKRSEL |
++ RG_EEEPRG_EN);
++ ocp_reg_write(tp, OCP_EEE_CONFIG3, FST_SNR_EYE_R | RG_LFS_SEL | MSK_PH);
++ ocp_reg_write(tp, OCP_EEE_AR, FUN_ADDR | DEVICE_ADDR);
++ ocp_reg_write(tp, OCP_EEE_DATA, EEE_ADDR);
++ ocp_reg_write(tp, OCP_EEE_AR, FUN_DATA | DEVICE_ADDR);
++ ocp_reg_write(tp, OCP_EEE_DATA, EEE_DATA);
++ ocp_reg_write(tp, OCP_EEE_AR, 0x0000);
+}
+
-+static void r8153_eee_en(struct r8152 *tp, bool enable)
++static void r8153_enable_eee(struct r8152 *tp)
+{
+ u32 ocp_data;
-+ u16 config;
++ u16 data;
+
+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_EEE_CR);
-+ config = ocp_reg_read(tp, OCP_EEE_CFG);
-+
-+ if (enable) {
-+ ocp_data |= EEE_RX_EN | EEE_TX_EN;
-+ config |= EEE10_EN;
-+ } else {
-+ ocp_data &= ~(EEE_RX_EN | EEE_TX_EN);
-+ config &= ~EEE10_EN;
-+ }
-+
++ ocp_data |= EEE_RX_EN | EEE_TX_EN;
+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_EEE_CR, ocp_data);
-+ ocp_reg_write(tp, OCP_EEE_CFG, config);
-+}
-+
-+static void r8153_enable_eee(struct r8152 *tp)
-+{
-+ r8153_eee_en(tp, true);
-+ ocp_reg_write(tp, OCP_EEE_ADV, MDIO_EEE_1000T | MDIO_EEE_100TX);
++ data = ocp_reg_read(tp, OCP_EEE_CFG);
++ data |= EEE10_EN;
++ ocp_reg_write(tp, OCP_EEE_CFG, data);
++ data = ocp_reg_read(tp, OCP_EEE_CFG2);
++ data |= MY1000_EEE | MY100_EEE;
++ ocp_reg_write(tp, OCP_EEE_CFG2, data);
+}
+
+static void r8152b_enable_fc(struct r8152 *tp)
+ r8152_mdio_write(tp, MII_ADVERTISE, anar);
+}
+
-+static void rtl_tally_reset(struct r8152 *tp)
++static void r8152b_hw_phy_cfg(struct r8152 *tp)
+{
-+ u32 ocp_data;
-+
-+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_RSTTALLY);
-+ ocp_data |= TALLY_RESET;
-+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_RSTTALLY, ocp_data);
++ r8152_mdio_write(tp, MII_BMCR, BMCR_ANENABLE);
++ r8152b_disable_aldps(tp);
+}
+
+static void r8152b_init(struct r8152 *tp)
+{
+ u32 ocp_data;
++ int i;
+
-+ if (test_bit(RTL8152_UNPLUG, &tp->flags))
-+ return;
-+
-+ r8152b_disable_aldps(tp);
++ rtl_clear_bp(tp);
+
+ if (tp->version == RTL_VER_01) {
+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_LED_FEATURE);
+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_LED_FEATURE, ocp_data);
+ }
+
-+ r8152_power_cut_en(tp, false);
++ r8152b_hw_phy_cfg(tp);
++
++ ocp_data = ocp_read_word(tp, MCU_TYPE_USB, USB_UPS_CTRL);
++ ocp_data &= ~POWER_CUT;
++ ocp_write_word(tp, MCU_TYPE_USB, USB_UPS_CTRL, ocp_data);
++
++ ocp_data = ocp_read_word(tp, MCU_TYPE_USB, USB_PM_CTRL_STATUS);
++ ocp_data &= ~RESUME_INDICATE;
++ ocp_write_word(tp, MCU_TYPE_USB, USB_PM_CTRL_STATUS, ocp_data);
++
++ r8152b_exit_oob(tp);
+
+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_PHY_PWR);
+ ocp_data |= TX_10M_IDLE_EN | PFM_PWM_SWITCH;
+ r8152b_enable_eee(tp);
+ r8152b_enable_aldps(tp);
+ r8152b_enable_fc(tp);
-+ rtl_tally_reset(tp);
++
++ r8152_mdio_write(tp, MII_BMCR, BMCR_RESET | BMCR_ANENABLE |
++ BMCR_ANRESTART);
++ for (i = 0; i < 100; i++) {
++ udelay(100);
++ if (!(r8152_mdio_read(tp, MII_BMCR) & BMCR_RESET))
++ break;
++ }
+
+ /* enable rx aggregation */
+ ocp_data = ocp_read_word(tp, MCU_TYPE_USB, USB_USB_CTRL);
+ u32 ocp_data;
+ int i;
+
-+ if (test_bit(RTL8152_UNPLUG, &tp->flags))
-+ return;
-+
-+ r8153_disable_aldps(tp);
-+ r8153_u1u2en(tp, false);
++ r8153_u1u2en(tp, 0);
+
+ for (i = 0; i < 500; i++) {
+ if (ocp_read_word(tp, MCU_TYPE_PLA, PLA_BOOT_CTRL) &
+ msleep(20);
+ }
+
-+ r8153_u2p3en(tp, false);
++ r8153_u2p3en(tp, 0);
+
+ ocp_data = ocp_read_word(tp, MCU_TYPE_USB, USB_WDT11_CTRL);
+ ocp_data &= ~TIMER11_EN;
+ ocp_write_word(tp, MCU_TYPE_USB, USB_WDT11_CTRL, ocp_data);
+
++ r8153_clear_bp(tp);
++
+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_LED_FEATURE);
+ ocp_data &= ~LED_MODE_MASK;
+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_LED_FEATURE, ocp_data);
+ ocp_data |= SEN_VAL_NORMAL | SEL_RXIDLE;
+ ocp_write_word(tp, MCU_TYPE_USB, USB_AFE_CTRL2, ocp_data);
+
-+ r8153_power_cut_en(tp, false);
-+ r8153_u1u2en(tp, true);
++ r8153_power_cut_en(tp, 0);
++ r8153_u1u2en(tp, 1);
++
++ r8153_first_init(tp);
+
+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_MAC_PWR_CTRL, ALDPS_SPDWN_RATIO);
+ ocp_write_word(tp, MCU_TYPE_PLA, PLA_MAC_PWR_CTRL2, EEE_SPDWN_RATIO);
+ r8153_enable_eee(tp);
+ r8153_enable_aldps(tp);
+ r8152b_enable_fc(tp);
-+ rtl_tally_reset(tp);
++
++ r8152_mdio_write(tp, MII_BMCR, BMCR_RESET | BMCR_ANENABLE |
++ BMCR_ANRESTART);
+}
+
+static int rtl8152_suspend(struct usb_interface *intf, pm_message_t message)
+{
+ struct r8152 *tp = usb_get_intfdata(intf);
-+ struct net_device *netdev = tp->netdev;
-+ int ret = 0;
-+
-+ mutex_lock(&tp->control);
-+
-+ if (PMSG_IS_AUTO(message)) {
-+ if (netif_running(netdev) && work_busy(&tp->schedule.work)) {
-+ ret = -EBUSY;
-+ goto out1;
-+ }
+
-+ set_bit(SELECTIVE_SUSPEND, &tp->flags);
-+ } else {
-+ netif_device_detach(netdev);
-+ }
++ netif_device_detach(tp->netdev);
+
-+ if (netif_running(netdev) && test_bit(WORK_ENABLE, &tp->flags)) {
++ if (netif_running(tp->netdev)) {
+ clear_bit(WORK_ENABLE, &tp->flags);
+ usb_kill_urb(tp->intr_urb);
++ cancel_delayed_work_sync(&tp->schedule);
+ tasklet_disable(&tp->tl);
-+ if (test_bit(SELECTIVE_SUSPEND, &tp->flags)) {
-+ rtl_stop_rx(tp);
-+ rtl_runtime_suspend_enable(tp, true);
-+ } else {
-+ cancel_delayed_work_sync(&tp->schedule);
-+ tp->rtl_ops.down(tp);
-+ }
-+ tasklet_enable(&tp->tl);
+ }
-+out1:
-+ mutex_unlock(&tp->control);
+
-+ return ret;
++ tp->rtl_ops.down(tp);
++
++ return 0;
+}
+
+static int rtl8152_resume(struct usb_interface *intf)
+{
+ struct r8152 *tp = usb_get_intfdata(intf);
+
-+ mutex_lock(&tp->control);
-+
-+ if (!test_bit(SELECTIVE_SUSPEND, &tp->flags)) {
-+ tp->rtl_ops.init(tp);
-+ netif_device_attach(tp->netdev);
-+ }
-+
++ tp->rtl_ops.init(tp);
++ netif_device_attach(tp->netdev);
+ if (netif_running(tp->netdev)) {
-+ if (test_bit(SELECTIVE_SUSPEND, &tp->flags)) {
-+ rtl_runtime_suspend_enable(tp, false);
-+ clear_bit(SELECTIVE_SUSPEND, &tp->flags);
-+ set_bit(WORK_ENABLE, &tp->flags);
-+ if (tp->speed & LINK_STATUS)
-+ rtl_start_rx(tp);
-+ } else {
-+ tp->rtl_ops.up(tp);
-+ rtl8152_set_speed(tp, AUTONEG_ENABLE,
-+ tp->mii.supports_gmii ?
-+ SPEED_1000 : SPEED_100,
-+ DUPLEX_FULL);
-+ tp->speed = 0;
-+ netif_carrier_off(tp->netdev);
-+ set_bit(WORK_ENABLE, &tp->flags);
-+ }
++ rtl8152_set_speed(tp, AUTONEG_ENABLE,
++ tp->mii.supports_gmii ? SPEED_1000 : SPEED_100,
++ DUPLEX_FULL);
++ tp->speed = 0;
++ netif_carrier_off(tp->netdev);
++ set_bit(WORK_ENABLE, &tp->flags);
+ usb_submit_urb(tp->intr_urb, GFP_KERNEL);
-+ } else if (test_bit(SELECTIVE_SUSPEND, &tp->flags)) {
-+ clear_bit(SELECTIVE_SUSPEND, &tp->flags);
++ tasklet_enable(&tp->tl);
+ }
+
-+ mutex_unlock(&tp->control);
-+
+ return 0;
+}
+
-+static void rtl8152_get_wol(struct net_device *dev, struct ethtool_wolinfo *wol)
-+{
-+ struct r8152 *tp = netdev_priv(dev);
-+
-+ if (usb_autopm_get_interface(tp->intf) < 0)
-+ return;
-+
-+ mutex_lock(&tp->control);
-+
-+ wol->supported = WAKE_ANY;
-+ wol->wolopts = __rtl_get_wol(tp);
-+
-+ mutex_unlock(&tp->control);
-+
-+ usb_autopm_put_interface(tp->intf);
-+}
-+
-+static int rtl8152_set_wol(struct net_device *dev, struct ethtool_wolinfo *wol)
-+{
-+ struct r8152 *tp = netdev_priv(dev);
-+ int ret;
-+
-+ ret = usb_autopm_get_interface(tp->intf);
-+ if (ret < 0)
-+ goto out_set_wol;
-+
-+ mutex_lock(&tp->control);
-+
-+ __rtl_set_wol(tp, wol->wolopts);
-+ tp->saved_wolopts = wol->wolopts & WAKE_ANY;
-+
-+ mutex_unlock(&tp->control);
-+
-+ usb_autopm_put_interface(tp->intf);
-+
-+out_set_wol:
-+ return ret;
-+}
-+
-+static u32 rtl8152_get_msglevel(struct net_device *dev)
-+{
-+ struct r8152 *tp = netdev_priv(dev);
-+
-+ return tp->msg_enable;
-+}
-+
-+static void rtl8152_set_msglevel(struct net_device *dev, u32 value)
-+{
-+ struct r8152 *tp = netdev_priv(dev);
-+
-+ tp->msg_enable = value;
-+}
-+
+static void rtl8152_get_drvinfo(struct net_device *netdev,
+ struct ethtool_drvinfo *info)
+{
+ struct r8152 *tp = netdev_priv(netdev);
+
-+ strlcpy(info->driver, MODULENAME, sizeof(info->driver));
-+ strlcpy(info->version, DRIVER_VERSION, sizeof(info->version));
++ strncpy(info->driver, MODULENAME, ETHTOOL_BUSINFO_LEN);
++ strncpy(info->version, DRIVER_VERSION, ETHTOOL_BUSINFO_LEN);
+ usb_make_path(tp->udev, info->bus_info, sizeof(info->bus_info));
+}
+
+int rtl8152_get_settings(struct net_device *netdev, struct ethtool_cmd *cmd)
+{
+ struct r8152 *tp = netdev_priv(netdev);
-+ int ret;
+
+ if (!tp->mii.mdio_read)
+ return -EOPNOTSUPP;
+
-+ ret = usb_autopm_get_interface(tp->intf);
-+ if (ret < 0)
-+ goto out;
-+
-+ mutex_lock(&tp->control);
-+
-+ ret = mii_ethtool_gset(&tp->mii, cmd);
-+
-+ mutex_unlock(&tp->control);
-+
-+ usb_autopm_put_interface(tp->intf);
-+
-+out:
-+ return ret;
++ return mii_ethtool_gset(&tp->mii, cmd);
+}
+
+static int rtl8152_set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
+{
+ struct r8152 *tp = netdev_priv(dev);
-+ int ret;
-+
-+ ret = usb_autopm_get_interface(tp->intf);
-+ if (ret < 0)
-+ goto out;
-+
-+ mutex_lock(&tp->control);
-+
-+ ret = rtl8152_set_speed(tp, cmd->autoneg, cmd->speed, cmd->duplex);
-+
-+ mutex_unlock(&tp->control);
-+
-+ usb_autopm_put_interface(tp->intf);
-+
-+out:
-+ return ret;
-+}
-+
-+static const char rtl8152_gstrings[][ETH_GSTRING_LEN] = {
-+ "tx_packets",
-+ "rx_packets",
-+ "tx_errors",
-+ "rx_errors",
-+ "rx_missed",
-+ "align_errors",
-+ "tx_single_collisions",
-+ "tx_multi_collisions",
-+ "rx_unicast",
-+ "rx_broadcast",
-+ "rx_multicast",
-+ "tx_aborted",
-+ "tx_underrun",
-+};
-+
-+static int rtl8152_get_sset_count(struct net_device *dev, int sset)
-+{
-+ switch (sset) {
-+ case ETH_SS_STATS:
-+ return ARRAY_SIZE(rtl8152_gstrings);
-+ default:
-+ return -EOPNOTSUPP;
-+ }
-+}
-+
-+static void rtl8152_get_ethtool_stats(struct net_device *dev,
-+ struct ethtool_stats *stats, u64 *data)
-+{
-+ struct r8152 *tp = netdev_priv(dev);
-+ struct tally_counter tally;
-+
-+ if (usb_autopm_get_interface(tp->intf) < 0)
-+ return;
-+
-+ generic_ocp_read(tp, PLA_TALLYCNT, sizeof(tally), &tally, MCU_TYPE_PLA);
-+
-+ usb_autopm_put_interface(tp->intf);
-+
-+ data[0] = le64_to_cpu(tally.tx_packets);
-+ data[1] = le64_to_cpu(tally.rx_packets);
-+ data[2] = le64_to_cpu(tally.tx_errors);
-+ data[3] = le32_to_cpu(tally.rx_errors);
-+ data[4] = le16_to_cpu(tally.rx_missed);
-+ data[5] = le16_to_cpu(tally.align_errors);
-+ data[6] = le32_to_cpu(tally.tx_one_collision);
-+ data[7] = le32_to_cpu(tally.tx_multi_collision);
-+ data[8] = le64_to_cpu(tally.rx_unicast);
-+ data[9] = le64_to_cpu(tally.rx_broadcast);
-+ data[10] = le32_to_cpu(tally.rx_multicast);
-+ data[11] = le16_to_cpu(tally.tx_aborted);
-+ data[12] = le16_to_cpu(tally.tx_underun);
-+}
-+
-+static void rtl8152_get_strings(struct net_device *dev, u32 stringset, u8 *data)
-+{
-+ switch (stringset) {
-+ case ETH_SS_STATS:
-+ memcpy(data, *rtl8152_gstrings, sizeof(rtl8152_gstrings));
-+ break;
-+ }
-+}
-+
-+static int r8152_get_eee(struct r8152 *tp, struct ethtool_eee *eee)
-+{
-+ u32 ocp_data, lp, adv, supported = 0;
-+ u16 val;
-+
-+ val = r8152_mmd_read(tp, MDIO_MMD_PCS, MDIO_PCS_EEE_ABLE);
-+ supported = mmd_eee_cap_to_ethtool_sup_t(val);
-+
-+ val = r8152_mmd_read(tp, MDIO_MMD_AN, MDIO_AN_EEE_ADV);
-+ adv = mmd_eee_adv_to_ethtool_adv_t(val);
-+
-+ val = r8152_mmd_read(tp, MDIO_MMD_AN, MDIO_AN_EEE_LPABLE);
-+ lp = mmd_eee_adv_to_ethtool_adv_t(val);
-+
-+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_EEE_CR);
-+ ocp_data &= EEE_RX_EN | EEE_TX_EN;
-+
-+ eee->eee_enabled = !!ocp_data;
-+ eee->eee_active = !!(supported & adv & lp);
-+ eee->supported = supported;
-+ eee->advertised = adv;
-+ eee->lp_advertised = lp;
-+
-+ return 0;
-+}
-+
-+static int r8152_set_eee(struct r8152 *tp, struct ethtool_eee *eee)
-+{
-+ u16 val = ethtool_adv_to_mmd_eee_adv_t(eee->advertised);
-+
-+ r8152_eee_en(tp, eee->eee_enabled);
-+
-+ if (!eee->eee_enabled)
-+ val = 0;
-+
-+ r8152_mmd_write(tp, MDIO_MMD_AN, MDIO_AN_EEE_ADV, val);
-+
-+ return 0;
-+}
-+
-+static int r8153_get_eee(struct r8152 *tp, struct ethtool_eee *eee)
-+{
-+ u32 ocp_data, lp, adv, supported = 0;
-+ u16 val;
-+
-+ val = ocp_reg_read(tp, OCP_EEE_ABLE);
-+ supported = mmd_eee_cap_to_ethtool_sup_t(val);
-+
-+ val = ocp_reg_read(tp, OCP_EEE_ADV);
-+ adv = mmd_eee_adv_to_ethtool_adv_t(val);
-+
-+ val = ocp_reg_read(tp, OCP_EEE_LPABLE);
-+ lp = mmd_eee_adv_to_ethtool_adv_t(val);
-+
-+ ocp_data = ocp_read_word(tp, MCU_TYPE_PLA, PLA_EEE_CR);
-+ ocp_data &= EEE_RX_EN | EEE_TX_EN;
-+
-+ eee->eee_enabled = !!ocp_data;
-+ eee->eee_active = !!(supported & adv & lp);
-+ eee->supported = supported;
-+ eee->advertised = adv;
-+ eee->lp_advertised = lp;
-+
-+ return 0;
-+}
-+
-+static int r8153_set_eee(struct r8152 *tp, struct ethtool_eee *eee)
-+{
-+ u16 val = ethtool_adv_to_mmd_eee_adv_t(eee->advertised);
-+
-+ r8153_eee_en(tp, eee->eee_enabled);
-+
-+ if (!eee->eee_enabled)
-+ val = 0;
-+
-+ ocp_reg_write(tp, OCP_EEE_ADV, val);
-+
-+ return 0;
-+}
-+
-+static int
-+rtl_ethtool_get_eee(struct net_device *net, struct ethtool_eee *edata)
-+{
-+ struct r8152 *tp = netdev_priv(net);
-+ int ret;
-+
-+ ret = usb_autopm_get_interface(tp->intf);
-+ if (ret < 0)
-+ goto out;
-+
-+ mutex_lock(&tp->control);
-+
-+ ret = tp->rtl_ops.eee_get(tp, edata);
-+
-+ mutex_unlock(&tp->control);
-+
-+ usb_autopm_put_interface(tp->intf);
-+
-+out:
-+ return ret;
-+}
-+
-+static int
-+rtl_ethtool_set_eee(struct net_device *net, struct ethtool_eee *edata)
-+{
-+ struct r8152 *tp = netdev_priv(net);
-+ int ret;
-+
-+ ret = usb_autopm_get_interface(tp->intf);
-+ if (ret < 0)
-+ goto out;
-+
-+ mutex_lock(&tp->control);
-+
-+ ret = tp->rtl_ops.eee_set(tp, edata);
-+ if (!ret)
-+ ret = mii_nway_restart(&tp->mii);
+
-+ mutex_unlock(&tp->control);
-+
-+ usb_autopm_put_interface(tp->intf);
-+
-+out:
-+ return ret;
++ return rtl8152_set_speed(tp, cmd->autoneg, cmd->speed, cmd->duplex);
+}
+
+static struct ethtool_ops ops = {
+ .get_settings = rtl8152_get_settings,
+ .set_settings = rtl8152_set_settings,
+ .get_link = ethtool_op_get_link,
-+ .get_msglevel = rtl8152_get_msglevel,
-+ .set_msglevel = rtl8152_set_msglevel,
-+ .get_wol = rtl8152_get_wol,
-+ .set_wol = rtl8152_set_wol,
-+ .get_strings = rtl8152_get_strings,
-+ .get_sset_count = rtl8152_get_sset_count,
-+ .get_ethtool_stats = rtl8152_get_ethtool_stats,
-+ .get_eee = rtl_ethtool_get_eee,
-+ .set_eee = rtl_ethtool_set_eee,
+};
+
+static int rtl8152_ioctl(struct net_device *netdev, struct ifreq *rq, int cmd)
+{
+ struct r8152 *tp = netdev_priv(netdev);
+ struct mii_ioctl_data *data = if_mii(rq);
-+ int res;
-+
-+ if (test_bit(RTL8152_UNPLUG, &tp->flags))
-+ return -ENODEV;
-+
-+ res = usb_autopm_get_interface(tp->intf);
-+ if (res < 0)
-+ goto out;
++ int res = 0;
+
+ switch (cmd) {
+ case SIOCGMIIPHY:
+ break;
+
+ case SIOCGMIIREG:
-+ mutex_lock(&tp->control);
+ data->val_out = r8152_mdio_read(tp, data->reg_num);
-+ mutex_unlock(&tp->control);
+ break;
+
+ case SIOCSMIIREG:
+ res = -EPERM;
+ break;
+ }
-+ mutex_lock(&tp->control);
+ r8152_mdio_write(tp, data->reg_num, data->val_in);
-+ mutex_unlock(&tp->control);
+ break;
+
+ default:
+ res = -EOPNOTSUPP;
+ }
+
-+ usb_autopm_put_interface(tp->intf);
-+
-+out:
+ return res;
+}
+
-+static int rtl8152_change_mtu(struct net_device *dev, int new_mtu)
-+{
-+ struct r8152 *tp = netdev_priv(dev);
-+
-+ switch (tp->version) {
-+ case RTL_VER_01:
-+ case RTL_VER_02:
-+ return eth_change_mtu(dev, new_mtu);
-+ default:
-+ break;
-+ }
-+
-+ if (new_mtu < 68 || new_mtu > RTL8153_MAX_MTU)
-+ return -EINVAL;
-+
-+ dev->mtu = new_mtu;
-+
-+ return 0;
-+}
-+
+static const struct net_device_ops rtl8152_netdev_ops = {
+ .ndo_open = rtl8152_open,
+ .ndo_stop = rtl8152_close,
+ .ndo_do_ioctl = rtl8152_ioctl,
+ .ndo_start_xmit = rtl8152_start_xmit,
+ .ndo_tx_timeout = rtl8152_tx_timeout,
-+ .ndo_set_features = rtl8152_set_features,
+ .ndo_set_rx_mode = rtl8152_set_rx_mode,
+ .ndo_set_mac_address = rtl8152_set_mac_address,
-+ .ndo_change_mtu = rtl8152_change_mtu,
++
++ .ndo_change_mtu = eth_change_mtu,
+ .ndo_validate_addr = eth_validate_addr,
+};
+
+
+static void rtl8152_unload(struct r8152 *tp)
+{
-+ if (test_bit(RTL8152_UNPLUG, &tp->flags))
-+ return;
++ u32 ocp_data;
+
-+ if (tp->version != RTL_VER_01)
-+ r8152_power_cut_en(tp, true);
++ if (tp->version != RTL_VER_01) {
++ ocp_data = ocp_read_word(tp, MCU_TYPE_USB, USB_UPS_CTRL);
++ ocp_data |= POWER_CUT;
++ ocp_write_word(tp, MCU_TYPE_USB, USB_UPS_CTRL, ocp_data);
++ }
++
++ ocp_data = ocp_read_word(tp, MCU_TYPE_USB, USB_PM_CTRL_STATUS);
++ ocp_data &= ~RESUME_INDICATE;
++ ocp_write_word(tp, MCU_TYPE_USB, USB_PM_CTRL_STATUS, ocp_data);
+}
+
+static void rtl8153_unload(struct r8152 *tp)
+{
-+ if (test_bit(RTL8152_UNPLUG, &tp->flags))
-+ return;
-+
-+ r8153_power_cut_en(tp, false);
++ r8153_power_cut_en(tp, 1);
+}
+
+static int rtl_ops_init(struct r8152 *tp, const struct usb_device_id *id)
+ ops->init = r8152b_init;
+ ops->enable = rtl8152_enable;
+ ops->disable = rtl8152_disable;
-+ ops->up = rtl8152_up;
+ ops->down = rtl8152_down;
+ ops->unload = rtl8152_unload;
-+ ops->eee_get = r8152_get_eee;
-+ ops->eee_set = r8152_set_eee;
+ ret = 0;
+ break;
+ case PRODUCT_ID_RTL8153:
+ ops->init = r8153_init;
+ ops->enable = rtl8153_enable;
-+ ops->disable = rtl8153_disable;
-+ ops->up = rtl8153_up;
++ ops->disable = rtl8152_disable;
+ ops->down = rtl8153_down;
+ ops->unload = rtl8153_unload;
-+ ops->eee_get = r8153_get_eee;
-+ ops->eee_set = r8153_set_eee;
+ ret = 0;
+ break;
+ default:
+ case PRODUCT_ID_SAMSUNG:
+ ops->init = r8153_init;
+ ops->enable = rtl8153_enable;
-+ ops->disable = rtl8153_disable;
-+ ops->up = rtl8153_up;
++ ops->disable = rtl8152_disable;
+ ops->down = rtl8153_down;
+ ops->unload = rtl8153_unload;
-+ ops->eee_get = r8153_get_eee;
-+ ops->eee_set = r8153_set_eee;
+ ret = 0;
+ break;
+ default:
+ goto out;
+
+ tasklet_init(&tp->tl, bottom_half, (unsigned long)tp);
-+ mutex_init(&tp->control);
+ INIT_DELAYED_WORK(&tp->schedule, rtl_work_func_t);
+
+ netdev->netdev_ops = &rtl8152_netdev_ops;
+ netdev->watchdog_timeo = RTL8152_TX_TIMEOUT;
+
-+ netdev->features |= NETIF_F_RXCSUM | NETIF_F_IP_CSUM | NETIF_F_SG |
-+ NETIF_F_TSO | NETIF_F_FRAGLIST | NETIF_F_IPV6_CSUM |
-+ NETIF_F_TSO6 | NETIF_F_HW_VLAN_CTAG_RX |
-+ NETIF_F_HW_VLAN_CTAG_TX;
-+ netdev->hw_features = NETIF_F_RXCSUM | NETIF_F_IP_CSUM | NETIF_F_SG |
-+ NETIF_F_TSO | NETIF_F_FRAGLIST |
-+ NETIF_F_IPV6_CSUM | NETIF_F_TSO6 |
-+ NETIF_F_HW_VLAN_CTAG_RX |
-+ NETIF_F_HW_VLAN_CTAG_TX;
-+ netdev->vlan_features = NETIF_F_SG | NETIF_F_IP_CSUM | NETIF_F_TSO |
-+ NETIF_F_HIGHDMA | NETIF_F_FRAGLIST |
-+ NETIF_F_IPV6_CSUM | NETIF_F_TSO6;
-+
-+ netdev->ethtool_ops = &ops;
-+ netif_set_gso_max_size(netdev, RTL_LIMITED_TSO_SIZE);
++ netdev->features |= NETIF_F_IP_CSUM;
++ netdev->hw_features = NETIF_F_IP_CSUM;
++ SET_ETHTOOL_OPS(netdev, &ops);
+
+ tp->mii.dev = netdev;
+ tp->mii.mdio_read = read_mii_word;
+ tp->mii.phy_id = R8152_PHY_ID;
+ tp->mii.supports_gmii = 0;
+
-+ intf->needs_remote_wakeup = 1;
-+
+ r8152b_get_version(tp);
+ tp->rtl_ops.init(tp);
+ set_ethernet_addr(tp);
+
++ ret = alloc_all_mem(tp);
++ if (ret)
++ goto out;
++
+ usb_set_intfdata(intf, tp);
+
+ ret = register_netdev(netdev);
+ goto out1;
+ }
+
-+ tp->saved_wolopts = __rtl_get_wol(tp);
-+ if (tp->saved_wolopts)
-+ device_set_wakeup_enable(&udev->dev, true);
-+ else
-+ device_set_wakeup_enable(&udev->dev, false);
-+
+ netif_info(tp, probe, netdev, "%s\n", DRIVER_VERSION);
+
+ return 0;
+
+ usb_set_intfdata(intf, NULL);
+ if (tp) {
-+ struct usb_device *udev = tp->udev;
-+
-+ if (udev->state == USB_STATE_NOTATTACHED)
-+ set_bit(RTL8152_UNPLUG, &tp->flags);
-+
++ set_bit(RTL8152_UNPLUG, &tp->flags);
+ tasklet_kill(&tp->tl);
+ unregister_netdev(tp->netdev);
+ tp->rtl_ops.unload(tp);
++ free_all_mem(tp);
+ free_netdev(tp->netdev);
+ }
+}
+ .suspend = rtl8152_suspend,
+ .resume = rtl8152_resume,
+ .reset_resume = rtl8152_resume,
-+ .supports_autosuspend = 1,
-+ .disable_hub_initiated_lpm = 1,
+};
+
+module_usb_driver(rtl8152_driver);
+MODULE_AUTHOR(DRIVER_AUTHOR);
+MODULE_DESCRIPTION(DRIVER_DESC);
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/rtl8150.c backports-3.18.1-1/drivers/net/usb/rtl8150.c
---- backports-3.18.1-1.org/drivers/net/usb/rtl8150.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/rtl8150.c 2014-12-16 18:39:45.000000000 +0100
-@@ -0,0 +1,950 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/rtl8150.c backports-4.2.6-1/drivers/net/usb/rtl8150.c
+--- backports-4.2.6-1.org/drivers/net/usb/rtl8150.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/rtl8150.c 2015-11-09 23:37:56.000000000 +0100
+@@ -0,0 +1,949 @@
+/*
+ * Copyright (c) 2002 Petko Manolov (petkan@users.sourceforge.net)
+ *
+static int rtl8150_close(struct net_device *netdev)
+{
+ rtl8150_t *dev = netdev_priv(netdev);
-+ int res = 0;
+
+ netif_stop_queue(netdev);
+ if (!test_bit(RTL8150_UNPLUG, &dev->flags))
+ disable_net_traffic(dev);
+ unlink_all_urbs(dev);
+
-+ return res;
++ return 0;
+}
+
+static void rtl8150_get_drvinfo(struct net_device *netdev, struct ethtool_drvinfo *info)
+MODULE_AUTHOR(DRIVER_AUTHOR);
+MODULE_DESCRIPTION(DRIVER_DESC);
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/smsc75xx.c backports-3.18.1-1/drivers/net/usb/smsc75xx.c
---- backports-3.18.1-1.org/drivers/net/usb/smsc75xx.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/smsc75xx.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/smsc75xx.c backports-4.2.6-1/drivers/net/usb/smsc75xx.c
+--- backports-4.2.6-1.org/drivers/net/usb/smsc75xx.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/smsc75xx.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,2286 @@
+ /***************************************************************************
+ *
+MODULE_AUTHOR("Steve Glendinning <steve.glendinning@shawell.net>");
+MODULE_DESCRIPTION("SMSC75XX USB 2.0 Gigabit Ethernet Devices");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/smsc75xx.h backports-3.18.1-1/drivers/net/usb/smsc75xx.h
---- backports-3.18.1-1.org/drivers/net/usb/smsc75xx.h 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/smsc75xx.h 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/smsc75xx.h backports-4.2.6-1/drivers/net/usb/smsc75xx.h
+--- backports-4.2.6-1.org/drivers/net/usb/smsc75xx.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/smsc75xx.h 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,421 @@
+ /***************************************************************************
+ *
+#define INT_ENP_RX_FIFO_DATA_INT ((u32)BIT(12))
+
+#endif /* _SMSC75XX_H */
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/smsc95xx.c backports-3.18.1-1/drivers/net/usb/smsc95xx.c
---- backports-3.18.1-1.org/drivers/net/usb/smsc95xx.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/smsc95xx.c 2014-12-16 18:39:45.000000000 +0100
-@@ -0,0 +1,2030 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/smsc95xx.c backports-4.2.6-1/drivers/net/usb/smsc95xx.c
+--- backports-4.2.6-1.org/drivers/net/usb/smsc95xx.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/smsc95xx.c 2015-11-09 23:37:56.000000000 +0100
+@@ -0,0 +1,2032 @@
+ /***************************************************************************
+ *
+ * Copyright (C) 2007-2008 SMSC
+static int smsc95xx_resume(struct usb_interface *intf)
+{
+ struct usbnet *dev = usb_get_intfdata(intf);
-+ struct smsc95xx_priv *pdata = (struct smsc95xx_priv *)(dev->data[0]);
-+ u8 suspend_flags = pdata->suspend_flags;
++ struct smsc95xx_priv *pdata;
++ u8 suspend_flags;
+ int ret;
+ u32 val;
+
+ BUG_ON(!dev);
++ pdata = (struct smsc95xx_priv *)(dev->data[0]);
++ suspend_flags = pdata->suspend_flags;
+
+ netdev_dbg(dev->net, "resume suspend_flags=0x%02x\n", suspend_flags);
+
+MODULE_AUTHOR("Steve Glendinning <steve.glendinning@shawell.net>");
+MODULE_DESCRIPTION("SMSC95XX USB 2.0 Ethernet Devices");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/smsc95xx.h backports-3.18.1-1/drivers/net/usb/smsc95xx.h
---- backports-3.18.1-1.org/drivers/net/usb/smsc95xx.h 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/smsc95xx.h 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/smsc95xx.h backports-4.2.6-1/drivers/net/usb/smsc95xx.h
+--- backports-4.2.6-1.org/drivers/net/usb/smsc95xx.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/smsc95xx.h 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,290 @@
+ /***************************************************************************
+ *
+#define INT_ENP_RXDF_ ((u32)BIT(11))
+
+#endif /* _SMSC95XX_H */
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/sr9700.c backports-3.18.1-1/drivers/net/usb/sr9700.c
---- backports-3.18.1-1.org/drivers/net/usb/sr9700.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/sr9700.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/sr9700.c backports-4.2.6-1/drivers/net/usb/sr9700.c
+--- backports-4.2.6-1.org/drivers/net/usb/sr9700.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/sr9700.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,559 @@
+/*
+ * CoreChip-sz SR9700 one chip USB 1.1 Ethernet Devices
+ int ret;
+
+ udelay(1);
-+ ret = sr_read_reg(dev, EPCR, &tmp);
++ ret = sr_read_reg(dev, SR_EPCR, &tmp);
+ if (ret < 0)
+ return ret;
+
+
+ mutex_lock(&dev->phy_mutex);
+
-+ sr_write_reg(dev, EPAR, phy ? (reg | EPAR_PHY_ADR) : reg);
-+ sr_write_reg(dev, EPCR, phy ? (EPCR_EPOS | EPCR_ERPRR) : EPCR_ERPRR);
++ sr_write_reg(dev, SR_EPAR, phy ? (reg | EPAR_PHY_ADR) : reg);
++ sr_write_reg(dev, SR_EPCR, phy ? (EPCR_EPOS | EPCR_ERPRR) : EPCR_ERPRR);
+
+ ret = wait_phy_eeprom_ready(dev, phy);
+ if (ret < 0)
+ goto out_unlock;
+
-+ sr_write_reg(dev, EPCR, 0x0);
-+ ret = sr_read(dev, EPDR, 2, value);
++ sr_write_reg(dev, SR_EPCR, 0x0);
++ ret = sr_read(dev, SR_EPDR, 2, value);
+
+ netdev_dbg(dev->net, "read shared %d 0x%02x returned 0x%04x, %d\n",
+ phy, reg, *value, ret);
+
+ mutex_lock(&dev->phy_mutex);
+
-+ ret = sr_write(dev, EPDR, 2, &value);
++ ret = sr_write(dev, SR_EPDR, 2, &value);
+ if (ret < 0)
+ goto out_unlock;
+
-+ sr_write_reg(dev, EPAR, phy ? (reg | EPAR_PHY_ADR) : reg);
-+ sr_write_reg(dev, EPCR, phy ? (EPCR_WEP | EPCR_EPOS | EPCR_ERPRW) :
++ sr_write_reg(dev, SR_EPAR, phy ? (reg | EPAR_PHY_ADR) : reg);
++ sr_write_reg(dev, SR_EPCR, phy ? (EPCR_WEP | EPCR_EPOS | EPCR_ERPRW) :
+ (EPCR_WEP | EPCR_ERPRW));
+
+ ret = wait_phy_eeprom_ready(dev, phy);
+ if (ret < 0)
+ goto out_unlock;
+
-+ sr_write_reg(dev, EPCR, 0x0);
++ sr_write_reg(dev, SR_EPCR, 0x0);
+
+out_unlock:
+ mutex_unlock(&dev->phy_mutex);
+ if (loc == MII_BMSR) {
+ u8 value;
+
-+ sr_read_reg(dev, NSR, &value);
++ sr_read_reg(dev, SR_NSR, &value);
+ if (value & NSR_LINKST)
+ rc = 1;
+ }
+ int rc = 0;
+
+ /* Get the Link Status directly */
-+ sr_read_reg(dev, NSR, &value);
++ sr_read_reg(dev, SR_NSR, &value);
+ if (value & NSR_LINKST)
+ rc = 1;
+
+ }
+ }
+
-+ sr_write_async(dev, MAR, SR_MCAST_SIZE, hashes);
-+ sr_write_reg_async(dev, RCR, rx_ctl);
++ sr_write_async(dev, SR_MAR, SR_MCAST_SIZE, hashes);
++ sr_write_reg_async(dev, SR_RCR, rx_ctl);
+}
+
+static int sr9700_set_mac_address(struct net_device *netdev, void *p)
+ }
+
+ memcpy(netdev->dev_addr, addr->sa_data, netdev->addr_len);
-+ sr_write_async(dev, PAR, 6, netdev->dev_addr);
++ sr_write_async(dev, SR_PAR, 6, netdev->dev_addr);
+
+ return 0;
+}
+ mii->phy_id_mask = 0x1f;
+ mii->reg_num_mask = 0x1f;
+
-+ sr_write_reg(dev, NCR, NCR_RST);
++ sr_write_reg(dev, SR_NCR, NCR_RST);
+ udelay(20);
+
+ /* read MAC
+ * EEPROM automatically to PAR. In case there is no EEPROM externally,
+ * a default MAC address is stored in PAR for making chip work properly.
+ */
-+ if (sr_read(dev, PAR, ETH_ALEN, netdev->dev_addr) < 0) {
++ if (sr_read(dev, SR_PAR, ETH_ALEN, netdev->dev_addr) < 0) {
+ netdev_err(netdev, "Error reading MAC address\n");
+ ret = -ENODEV;
+ goto out;
+ }
+
+ /* power up and reset phy */
-+ sr_write_reg(dev, PRR, PRR_PHY_RST);
++ sr_write_reg(dev, SR_PRR, PRR_PHY_RST);
+ /* at least 10ms, here 20ms for safe */
+ mdelay(20);
-+ sr_write_reg(dev, PRR, 0);
++ sr_write_reg(dev, SR_PRR, 0);
+ /* at least 1ms, here 2ms for reading right register */
+ udelay(2 * 1000);
+
+MODULE_AUTHOR("liujl <liujunliang_ljl@163.com>");
+MODULE_DESCRIPTION("SR9700 one chip USB 1.1 USB to Ethernet device from http://www.corechip-sz.com/");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/sr9700.h backports-3.18.1-1/drivers/net/usb/sr9700.h
---- backports-3.18.1-1.org/drivers/net/usb/sr9700.h 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/sr9700.h 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/sr9700.h backports-4.2.6-1/drivers/net/usb/sr9700.h
+--- backports-4.2.6-1.org/drivers/net/usb/sr9700.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/sr9700.h 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,173 @@
+/*
+ * CoreChip-sz SR9700 one chip USB 1.1 Ethernet Devices
+/* sr9700 spec. register table on Linux platform */
+
+/* Network Control Reg */
-+#define NCR 0x00
++#define SR_NCR 0x00
+#define NCR_RST (1 << 0)
+#define NCR_LBK (3 << 1)
+#define NCR_FDX (1 << 3)
+#define NCR_WAKEEN (1 << 6)
+/* Network Status Reg */
-+#define NSR 0x01
++#define SR_NSR 0x01
+#define NSR_RXRDY (1 << 0)
+#define NSR_RXOV (1 << 1)
+#define NSR_TX1END (1 << 2)
+#define NSR_LINKST (1 << 6)
+#define NSR_SPEED (1 << 7)
+/* Tx Control Reg */
-+#define TCR 0x02
++#define SR_TCR 0x02
+#define TCR_CRC_DIS (1 << 1)
+#define TCR_PAD_DIS (1 << 2)
+#define TCR_LC_CARE (1 << 3)
+#define TCR_EXCECM (1 << 5)
+#define TCR_LF_EN (1 << 6)
+/* Tx Status Reg for Packet Index 1 */
-+#define TSR1 0x03
++#define SR_TSR1 0x03
+#define TSR1_EC (1 << 2)
+#define TSR1_COL (1 << 3)
+#define TSR1_LC (1 << 4)
+#define TSR1_LOC (1 << 6)
+#define TSR1_TLF (1 << 7)
+/* Tx Status Reg for Packet Index 2 */
-+#define TSR2 0x04
++#define SR_TSR2 0x04
+#define TSR2_EC (1 << 2)
+#define TSR2_COL (1 << 3)
+#define TSR2_LC (1 << 4)
+#define TSR2_LOC (1 << 6)
+#define TSR2_TLF (1 << 7)
+/* Rx Control Reg*/
-+#define RCR 0x05
++#define SR_RCR 0x05
+#define RCR_RXEN (1 << 0)
+#define RCR_PRMSC (1 << 1)
+#define RCR_RUNT (1 << 2)
+#define RCR_DIS_CRC (1 << 4)
+#define RCR_DIS_LONG (1 << 5)
+/* Rx Status Reg */
-+#define RSR 0x06
++#define SR_RSR 0x06
+#define RSR_AE (1 << 2)
+#define RSR_MF (1 << 6)
+#define RSR_RF (1 << 7)
+/* Rx Overflow Counter Reg */
-+#define ROCR 0x07
++#define SR_ROCR 0x07
+#define ROCR_ROC (0x7F << 0)
+#define ROCR_RXFU (1 << 7)
+/* Back Pressure Threshold Reg */
-+#define BPTR 0x08
++#define SR_BPTR 0x08
+#define BPTR_JPT (0x0F << 0)
+#define BPTR_BPHW (0x0F << 4)
+/* Flow Control Threshold Reg */
-+#define FCTR 0x09
++#define SR_FCTR 0x09
+#define FCTR_LWOT (0x0F << 0)
+#define FCTR_HWOT (0x0F << 4)
+/* rx/tx Flow Control Reg */
-+#define FCR 0x0A
++#define SR_FCR 0x0A
+#define FCR_FLCE (1 << 0)
+#define FCR_BKPA (1 << 4)
+#define FCR_TXPEN (1 << 5)
+#define FCR_TXPF (1 << 6)
+#define FCR_TXP0 (1 << 7)
+/* Eeprom & Phy Control Reg */
-+#define EPCR 0x0B
++#define SR_EPCR 0x0B
+#define EPCR_ERRE (1 << 0)
+#define EPCR_ERPRW (1 << 1)
+#define EPCR_ERPRR (1 << 2)
+#define EPCR_EPOS (1 << 3)
+#define EPCR_WEP (1 << 4)
+/* Eeprom & Phy Address Reg */
-+#define EPAR 0x0C
++#define SR_EPAR 0x0C
+#define EPAR_EROA (0x3F << 0)
+#define EPAR_PHY_ADR_MASK (0x03 << 6)
+#define EPAR_PHY_ADR (0x01 << 6)
+/* Eeprom & Phy Data Reg */
-+#define EPDR 0x0D /* 0x0D ~ 0x0E for Data Reg Low & High */
++#define SR_EPDR 0x0D /* 0x0D ~ 0x0E for Data Reg Low & High */
+/* Wakeup Control Reg */
-+#define WCR 0x0F
++#define SR_WCR 0x0F
+#define WCR_MAGICST (1 << 0)
+#define WCR_LINKST (1 << 2)
+#define WCR_MAGICEN (1 << 3)
+#define WCR_LINKEN (1 << 5)
+/* Physical Address Reg */
-+#define PAR 0x10 /* 0x10 ~ 0x15 6 bytes for PAR */
++#define SR_PAR 0x10 /* 0x10 ~ 0x15 6 bytes for PAR */
+/* Multicast Address Reg */
-+#define MAR 0x16 /* 0x16 ~ 0x1D 8 bytes for MAR */
++#define SR_MAR 0x16 /* 0x16 ~ 0x1D 8 bytes for MAR */
+/* 0x1e unused */
+/* Phy Reset Reg */
-+#define PRR 0x1F
++#define SR_PRR 0x1F
+#define PRR_PHY_RST (1 << 0)
+/* Tx sdram Write Pointer Address Low */
-+#define TWPAL 0x20
++#define SR_TWPAL 0x20
+/* Tx sdram Write Pointer Address High */
-+#define TWPAH 0x21
++#define SR_TWPAH 0x21
+/* Tx sdram Read Pointer Address Low */
-+#define TRPAL 0x22
++#define SR_TRPAL 0x22
+/* Tx sdram Read Pointer Address High */
-+#define TRPAH 0x23
++#define SR_TRPAH 0x23
+/* Rx sdram Write Pointer Address Low */
-+#define RWPAL 0x24
++#define SR_RWPAL 0x24
+/* Rx sdram Write Pointer Address High */
-+#define RWPAH 0x25
++#define SR_RWPAH 0x25
+/* Rx sdram Read Pointer Address Low */
-+#define RRPAL 0x26
++#define SR_RRPAL 0x26
+/* Rx sdram Read Pointer Address High */
-+#define RRPAH 0x27
++#define SR_RRPAH 0x27
+/* Vendor ID register */
-+#define VID 0x28 /* 0x28 ~ 0x29 2 bytes for VID */
++#define SR_VID 0x28 /* 0x28 ~ 0x29 2 bytes for VID */
+/* Product ID register */
-+#define PID 0x2A /* 0x2A ~ 0x2B 2 bytes for PID */
++#define SR_PID 0x2A /* 0x2A ~ 0x2B 2 bytes for PID */
+/* CHIP Revision register */
-+#define CHIPR 0x2C
++#define SR_CHIPR 0x2C
+/* 0x2D --> 0xEF unused */
+/* USB Device Address */
-+#define USBDA 0xF0
++#define SR_USBDA 0xF0
+#define USBDA_USBFA (0x7F << 0)
+/* RX packet Counter Reg */
-+#define RXC 0xF1
++#define SR_RXC 0xF1
+/* Tx packet Counter & USB Status Reg */
-+#define TXC_USBS 0xF2
++#define SR_TXC_USBS 0xF2
+#define TXC_USBS_TXC0 (1 << 0)
+#define TXC_USBS_TXC1 (1 << 1)
+#define TXC_USBS_TXC2 (1 << 2)
+#define TXC_USBS_SUSFLAG (1 << 6)
+#define TXC_USBS_RXFAULT (1 << 7)
+/* USB Control register */
-+#define USBC 0xF4
++#define SR_USBC 0xF4
+#define USBC_EP3NAK (1 << 4)
+#define USBC_EP3ACK (1 << 5)
+
+#define SR_RX_OVERHEAD 7 /* 3bytes header + 4crc tail */
+
+#endif /* _SR9700_H */
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/sr9800.c backports-3.18.1-1/drivers/net/usb/sr9800.c
---- backports-3.18.1-1.org/drivers/net/usb/sr9800.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/sr9800.c 2014-12-16 18:39:45.000000000 +0100
-@@ -0,0 +1,874 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/sr9800.c backports-4.2.6-1/drivers/net/usb/sr9800.c
+--- backports-4.2.6-1.org/drivers/net/usb/sr9800.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/sr9800.c 2015-11-09 23:37:56.000000000 +0100
+@@ -0,0 +1,875 @@
+/* CoreChip-sz SR9800 one chip USB 2.0 Ethernet Devices
+ *
+ * Author : Liu Junliang <liujunliang_ljl@163.com>
+ skb_put(skb, sizeof(padbytes));
+ }
+
++ usbnet_set_skb_tx_stats(skb, 1, 0);
+ return skb;
+}
+
+MODULE_VERSION(DRIVER_VERSION);
+MODULE_DESCRIPTION("SR9800 USB 2.0 USB2NET Dev : http://www.corechip-sz.com");
+MODULE_LICENSE("GPL");
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/sr9800.h backports-3.18.1-1/drivers/net/usb/sr9800.h
---- backports-3.18.1-1.org/drivers/net/usb/sr9800.h 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/sr9800.h 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/sr9800.h backports-4.2.6-1/drivers/net/usb/sr9800.h
+--- backports-4.2.6-1.org/drivers/net/usb/sr9800.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/sr9800.h 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,202 @@
+/* CoreChip-sz SR9800 one chip USB 2.0 Ethernet Devices
+ *
+} __packed;
+
+#endif /* _SR9800_H */
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/zaurus.c backports-3.18.1-1/drivers/net/usb/zaurus.c
---- backports-3.18.1-1.org/drivers/net/usb/zaurus.c 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/zaurus.c 2014-12-16 18:39:45.000000000 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/zaurus.c backports-4.2.6-1/drivers/net/usb/zaurus.c
+--- backports-4.2.6-1.org/drivers/net/usb/zaurus.c 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/zaurus.c 2015-11-09 23:37:56.000000000 +0100
@@ -0,0 +1,385 @@
+/*
+ * Copyright (C) 2002 Pavel Machek <pavel@ucw.cz>
-diff -Naur backports-3.18.1-1.org/drivers/bluetooth/btwilink.c backports-3.18.1-1/drivers/bluetooth/btwilink.c
---- backports-3.18.1-1.org/drivers/bluetooth/btwilink.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/drivers/bluetooth/btwilink.c 2014-12-28 14:10:09.480888533 +0100
+diff -Naur backports-4.2.6-1.org/drivers/bluetooth/btwilink.c backports-4.2.6-1/drivers/bluetooth/btwilink.c
+--- backports-4.2.6-1.org/drivers/bluetooth/btwilink.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/drivers/bluetooth/btwilink.c 2016-01-27 12:26:16.319959957 +0100
@@ -288,7 +288,7 @@
static int bt_ti_probe(struct platform_device *pdev)
struct hci_dev *hdev;
int err;
-diff -Naur backports-3.18.1-1.org/drivers/media/dvb-core/dvbdev.c backports-3.18.1-1/drivers/media/dvb-core/dvbdev.c
---- backports-3.18.1-1.org/drivers/media/dvb-core/dvbdev.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/dvb-core/dvbdev.c 2014-12-28 14:10:09.528888772 +0100
-@@ -185,7 +185,7 @@
+diff -Naur backports-4.2.6-1.org/drivers/media/dvb-core/dvbdev.c backports-4.2.6-1/drivers/media/dvb-core/dvbdev.c
+--- backports-4.2.6-1.org/drivers/media/dvb-core/dvbdev.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/media/dvb-core/dvbdev.c 2016-01-27 12:26:21.266626324 +0100
+@@ -272,7 +272,7 @@
const struct dvb_device *template, void *priv, int type)
{
struct dvb_device *dvbdev;
struct device *clsdev;
int minor;
int id;
-diff -Naur backports-3.18.1-1.org/drivers/media/dvb-frontends/af9033.h backports-3.18.1-1/drivers/media/dvb-frontends/af9033.h
---- backports-3.18.1-1.org/drivers/media/dvb-frontends/af9033.h 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/dvb-frontends/af9033.h 2014-12-28 14:10:09.528888772 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/dvb-frontends/af9033.h backports-4.2.6-1/drivers/media/dvb-frontends/af9033.h
+--- backports-4.2.6-1.org/drivers/media/dvb-frontends/af9033.h 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/dvb-frontends/af9033.h 2016-01-27 12:26:21.266626324 +0100
@@ -96,6 +96,6 @@
int (*pid_filter_ctrl)(struct dvb_frontend *fe, int onoff);
int (*pid_filter)(struct dvb_frontend *fe, int index, u16 pid,
+} __no_const;
#endif /* AF9033_H */
-diff -Naur backports-3.18.1-1.org/drivers/media/dvb-frontends/dib3000.h backports-3.18.1-1/drivers/media/dvb-frontends/dib3000.h
---- backports-3.18.1-1.org/drivers/media/dvb-frontends/dib3000.h 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/dvb-frontends/dib3000.h 2014-12-28 14:10:09.528888772 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/dvb-frontends/dib3000.h backports-4.2.6-1/drivers/media/dvb-frontends/dib3000.h
+--- backports-4.2.6-1.org/drivers/media/dvb-frontends/dib3000.h 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/dvb-frontends/dib3000.h 2016-01-27 12:26:21.266626324 +0100
@@ -39,7 +39,7 @@
int (*fifo_ctrl)(struct dvb_frontend *fe, int onoff);
int (*pid_ctrl)(struct dvb_frontend *fe, int index, int pid, int onoff);
-};
+} __no_const;
- #if IS_ENABLED(CPTCFG_DVB_DIB3000MB)
+ #if IS_REACHABLE(CPTCFG_DVB_DIB3000MB)
extern struct dvb_frontend* dib3000mb_attach(const struct dib3000_config* config,
-diff -Naur backports-3.18.1-1.org/drivers/media/dvb-frontends/dib7000p.h backports-3.18.1-1/drivers/media/dvb-frontends/dib7000p.h
---- backports-3.18.1-1.org/drivers/media/dvb-frontends/dib7000p.h 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/dvb-frontends/dib7000p.h 2014-12-28 14:10:09.528888772 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/dvb-frontends/dib7000p.h backports-4.2.6-1/drivers/media/dvb-frontends/dib7000p.h
+--- backports-4.2.6-1.org/drivers/media/dvb-frontends/dib7000p.h 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/dvb-frontends/dib7000p.h 2016-01-27 12:26:21.266626324 +0100
@@ -64,7 +64,7 @@
int (*get_adc_power)(struct dvb_frontend *fe);
int (*slave_reset)(struct dvb_frontend *fe);
-};
+} __no_const;
- #if IS_ENABLED(CPTCFG_DVB_DIB7000P)
+ #if IS_REACHABLE(CPTCFG_DVB_DIB7000P)
void *dib7000p_attach(struct dib7000p_ops *ops);
-diff -Naur backports-3.18.1-1.org/drivers/media/dvb-frontends/dib8000.h backports-3.18.1-1/drivers/media/dvb-frontends/dib8000.h
---- backports-3.18.1-1.org/drivers/media/dvb-frontends/dib8000.h 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/dvb-frontends/dib8000.h 2014-12-28 14:10:09.528888772 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/dvb-frontends/dib8000.h backports-4.2.6-1/drivers/media/dvb-frontends/dib8000.h
+--- backports-4.2.6-1.org/drivers/media/dvb-frontends/dib8000.h 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/dvb-frontends/dib8000.h 2016-01-27 12:26:21.266626324 +0100
@@ -61,7 +61,7 @@
int (*pid_filter_ctrl)(struct dvb_frontend *fe, u8 onoff);
int (*pid_filter)(struct dvb_frontend *fe, u8 id, u16 pid, u8 onoff);
-};
+} __no_const;
- #if IS_ENABLED(CPTCFG_DVB_DIB8000)
+ #if IS_REACHABLE(CPTCFG_DVB_DIB8000)
void *dib8000_attach(struct dib8000_ops *ops);
-diff -Naur backports-3.18.1-1.org/drivers/media/pci/cx88/cx88-video.c backports-3.18.1-1/drivers/media/pci/cx88/cx88-video.c
---- backports-3.18.1-1.org/drivers/media/pci/cx88/cx88-video.c 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/pci/cx88/cx88-video.c 2014-12-28 14:10:09.528888772 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/pci/cx88/cx88-video.c backports-4.2.6-1/drivers/media/pci/cx88/cx88-video.c
+--- backports-4.2.6-1.org/drivers/media/pci/cx88/cx88-video.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/pci/cx88/cx88-video.c 2016-01-27 12:26:21.266626324 +0100
@@ -50,9 +50,9 @@
/* ------------------------------------------------------------------ */
module_param_array(video_nr, int, NULL, 0444);
module_param_array(vbi_nr, int, NULL, 0444);
-diff -Naur backports-3.18.1-1.org/drivers/media/pci/ivtv/ivtv-driver.c backports-3.18.1-1/drivers/media/pci/ivtv/ivtv-driver.c
---- backports-3.18.1-1.org/drivers/media/pci/ivtv/ivtv-driver.c 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/pci/ivtv/ivtv-driver.c 2014-12-28 14:10:09.528888772 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/pci/ivtv/ivtv-driver.c backports-4.2.6-1/drivers/media/pci/ivtv/ivtv-driver.c
+--- backports-4.2.6-1.org/drivers/media/pci/ivtv/ivtv-driver.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/pci/ivtv/ivtv-driver.c 2016-01-27 12:26:21.266626324 +0100
@@ -83,7 +83,7 @@
MODULE_DEVICE_TABLE(pci,ivtv_pci_tbl);
/* Parameter declarations */
static int cardtype[IVTV_MAX_CARDS];
-diff -Naur backports-3.18.1-1.org/drivers/media/pci/solo6x10/solo6x10-core.c backports-3.18.1-1/drivers/media/pci/solo6x10/solo6x10-core.c
---- backports-3.18.1-1.org/drivers/media/pci/solo6x10/solo6x10-core.c 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/pci/solo6x10/solo6x10-core.c 2014-12-28 14:10:09.528888772 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/pci/solo6x10/solo6x10-core.c backports-4.2.6-1/drivers/media/pci/solo6x10/solo6x10-core.c
+--- backports-4.2.6-1.org/drivers/media/pci/solo6x10/solo6x10-core.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/pci/solo6x10/solo6x10-core.c 2016-01-27 12:26:21.266626324 +0100
@@ -424,7 +424,7 @@
static int solo_sysfs_init(struct solo_dev *solo_dev)
struct device *dev = &solo_dev->dev;
const char *driver;
int i;
-diff -Naur backports-3.18.1-1.org/drivers/media/pci/solo6x10/solo6x10-g723.c backports-3.18.1-1/drivers/media/pci/solo6x10/solo6x10-g723.c
---- backports-3.18.1-1.org/drivers/media/pci/solo6x10/solo6x10-g723.c 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/pci/solo6x10/solo6x10-g723.c 2014-12-28 14:10:09.528888772 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/pci/solo6x10/solo6x10-g723.c backports-4.2.6-1/drivers/media/pci/solo6x10/solo6x10-g723.c
+--- backports-4.2.6-1.org/drivers/media/pci/solo6x10/solo6x10-g723.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/pci/solo6x10/solo6x10-g723.c 2016-01-27 12:26:21.266626324 +0100
@@ -351,7 +351,7 @@
int solo_g723_init(struct solo_dev *solo_dev)
struct snd_card *card;
struct snd_kcontrol_new kctl;
char name[32];
-diff -Naur backports-3.18.1-1.org/drivers/media/pci/solo6x10/solo6x10.h backports-3.18.1-1/drivers/media/pci/solo6x10/solo6x10.h
---- backports-3.18.1-1.org/drivers/media/pci/solo6x10/solo6x10.h 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/pci/solo6x10/solo6x10.h 2014-12-28 14:10:09.532888798 +0100
-@@ -219,7 +219,7 @@
+diff -Naur backports-4.2.6-1.org/drivers/media/pci/solo6x10/solo6x10.h backports-4.2.6-1/drivers/media/pci/solo6x10/solo6x10.h
+--- backports-4.2.6-1.org/drivers/media/pci/solo6x10/solo6x10.h 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/pci/solo6x10/solo6x10.h 2016-01-27 12:26:21.266626324 +0100
+@@ -218,7 +218,7 @@
/* P2M DMA Engine */
struct solo_p2m_dev p2m_dev[SOLO_NR_P2M];
int p2m_jiffies;
unsigned int p2m_timeouts;
-diff -Naur backports-3.18.1-1.org/drivers/media/pci/solo6x10/solo6x10-p2m.c backports-3.18.1-1/drivers/media/pci/solo6x10/solo6x10-p2m.c
---- backports-3.18.1-1.org/drivers/media/pci/solo6x10/solo6x10-p2m.c 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/pci/solo6x10/solo6x10-p2m.c 2014-12-28 14:10:09.532888798 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/pci/solo6x10/solo6x10-p2m.c backports-4.2.6-1/drivers/media/pci/solo6x10/solo6x10-p2m.c
+--- backports-4.2.6-1.org/drivers/media/pci/solo6x10/solo6x10-p2m.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/pci/solo6x10/solo6x10-p2m.c 2016-01-27 12:26:21.266626324 +0100
@@ -73,7 +73,7 @@
/* Get next ID. According to Softlogic, 6110 has problems on !=0 P2M */
if (p2m_id < 0)
p2m_id = -p2m_id;
}
-diff -Naur backports-3.18.1-1.org/drivers/media/platform/omap/omap_vout.c backports-3.18.1-1/drivers/media/platform/omap/omap_vout.c
---- backports-3.18.1-1.org/drivers/media/platform/omap/omap_vout.c 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/platform/omap/omap_vout.c 2014-12-28 14:10:09.532888798 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/pci/tw68/tw68-core.c backports-4.2.6-1/drivers/media/pci/tw68/tw68-core.c
+--- backports-4.2.6-1.org/drivers/media/pci/tw68/tw68-core.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/pci/tw68/tw68-core.c 2016-01-27 12:26:21.266626324 +0100
+@@ -60,7 +60,7 @@
+ module_param_array(card, int, NULL, 0444);
+ MODULE_PARM_DESC(card, "card type");
+
+-static atomic_t tw68_instance = ATOMIC_INIT(0);
++static atomic_unchecked_t tw68_instance = ATOMIC_INIT(0);
+
+ /* ------------------------------------------------------------------ */
+
+diff -Naur backports-4.2.6-1.org/drivers/media/platform/omap/omap_vout.c backports-4.2.6-1/drivers/media/platform/omap/omap_vout.c
+--- backports-4.2.6-1.org/drivers/media/platform/omap/omap_vout.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/platform/omap/omap_vout.c 2016-01-27 12:26:21.266626324 +0100
@@ -63,7 +63,6 @@
OMAP_VIDEO2,
};
/* Variables configurable through module params*/
static u32 video1_numbuffers = 3;
static u32 video2_numbuffers = 3;
-@@ -1012,6 +1011,12 @@
+@@ -1008,6 +1007,12 @@
{
struct videobuf_queue *q;
struct omap_vout_device *vout = NULL;
vout = video_drvdata(file);
v4l2_dbg(1, debug, &vout->vid_dev->v4l2_dev, "Entering %s\n", __func__);
-@@ -1029,10 +1034,6 @@
+@@ -1025,10 +1030,6 @@
vout->type = V4L2_BUF_TYPE_VIDEO_OUTPUT;
q = &vout->vbq;
spin_lock_init(&vout->vbq_lock);
videobuf_queue_dma_contig_init(q, &video_vbq_ops, q->dev,
-diff -Naur backports-3.18.1-1.org/drivers/media/platform/s5p-tv/mixer_grp_layer.c backports-3.18.1-1/drivers/media/platform/s5p-tv/mixer_grp_layer.c
---- backports-3.18.1-1.org/drivers/media/platform/s5p-tv/mixer_grp_layer.c 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/platform/s5p-tv/mixer_grp_layer.c 2014-12-28 14:10:09.532888798 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/platform/s5p-tv/mixer_grp_layer.c backports-4.2.6-1/drivers/media/platform/s5p-tv/mixer_grp_layer.c
+--- backports-4.2.6-1.org/drivers/media/platform/s5p-tv/mixer_grp_layer.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/platform/s5p-tv/mixer_grp_layer.c 2016-01-27 12:26:21.266626324 +0100
@@ -235,7 +235,7 @@
{
struct mxr_layer *layer;
.release = mxr_graph_layer_release,
.buffer_set = mxr_graph_buffer_set,
.stream_set = mxr_graph_stream_set,
-diff -Naur backports-3.18.1-1.org/drivers/media/platform/s5p-tv/mixer.h backports-3.18.1-1/drivers/media/platform/s5p-tv/mixer.h
---- backports-3.18.1-1.org/drivers/media/platform/s5p-tv/mixer.h 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/platform/s5p-tv/mixer.h 2014-12-28 14:10:09.532888798 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/platform/s5p-tv/mixer.h backports-4.2.6-1/drivers/media/platform/s5p-tv/mixer.h
+--- backports-4.2.6-1.org/drivers/media/platform/s5p-tv/mixer.h 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/platform/s5p-tv/mixer.h 2016-01-27 12:26:21.266626324 +0100
@@ -156,7 +156,7 @@
/** layer index (unique identifier) */
int idx;
/** format array */
const struct mxr_format **fmt_array;
/** size of format array */
-diff -Naur backports-3.18.1-1.org/drivers/media/platform/s5p-tv/mixer_reg.c backports-3.18.1-1/drivers/media/platform/s5p-tv/mixer_reg.c
---- backports-3.18.1-1.org/drivers/media/platform/s5p-tv/mixer_reg.c 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/platform/s5p-tv/mixer_reg.c 2014-12-28 14:10:09.532888798 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/platform/s5p-tv/mixer_reg.c backports-4.2.6-1/drivers/media/platform/s5p-tv/mixer_reg.c
+--- backports-4.2.6-1.org/drivers/media/platform/s5p-tv/mixer_reg.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/platform/s5p-tv/mixer_reg.c 2016-01-27 12:26:21.266626324 +0100
@@ -276,7 +276,7 @@
layer->update_buf = next;
}
if (done && done != layer->shadow_buf)
vb2_buffer_done(&done->vb, VB2_BUF_STATE_DONE);
-diff -Naur backports-3.18.1-1.org/drivers/media/platform/s5p-tv/mixer_video.c backports-3.18.1-1/drivers/media/platform/s5p-tv/mixer_video.c
---- backports-3.18.1-1.org/drivers/media/platform/s5p-tv/mixer_video.c 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/platform/s5p-tv/mixer_video.c 2014-12-28 14:10:09.532888798 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/platform/s5p-tv/mixer_video.c backports-4.2.6-1/drivers/media/platform/s5p-tv/mixer_video.c
+--- backports-4.2.6-1.org/drivers/media/platform/s5p-tv/mixer_video.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/platform/s5p-tv/mixer_video.c 2016-01-27 12:26:21.266626324 +0100
@@ -210,7 +210,7 @@
layer->geo.src.height = layer->geo.src.full_height;
/* retrieve update selection rectangle */
res.left = target->x_offset;
-@@ -954,13 +954,13 @@
+@@ -938,13 +938,13 @@
mxr_output_get(mdev);
mxr_layer_update_output(layer);
mxr_streamer_get(mdev);
return 0;
-@@ -1030,7 +1030,7 @@
+@@ -1014,7 +1014,7 @@
spin_unlock_irqrestore(&layer->enq_slock, flags);
/* disabling layer in hardware */
/* remove one streamer */
mxr_streamer_put(mdev);
/* allow changes in output configuration */
-@@ -1068,8 +1068,8 @@
+@@ -1052,8 +1052,8 @@
void mxr_layer_release(struct mxr_layer *layer)
{
}
void mxr_base_layer_release(struct mxr_layer *layer)
-@@ -1095,7 +1095,7 @@
+@@ -1079,7 +1079,7 @@
layer->mdev = mdev;
layer->idx = idx;
spin_lock_init(&layer->enq_slock);
INIT_LIST_HEAD(&layer->enq_list);
-diff -Naur backports-3.18.1-1.org/drivers/media/platform/s5p-tv/mixer_vp_layer.c backports-3.18.1-1/drivers/media/platform/s5p-tv/mixer_vp_layer.c
---- backports-3.18.1-1.org/drivers/media/platform/s5p-tv/mixer_vp_layer.c 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/platform/s5p-tv/mixer_vp_layer.c 2014-12-28 14:10:09.532888798 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/platform/s5p-tv/mixer_vp_layer.c backports-4.2.6-1/drivers/media/platform/s5p-tv/mixer_vp_layer.c
+--- backports-4.2.6-1.org/drivers/media/platform/s5p-tv/mixer_vp_layer.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/platform/s5p-tv/mixer_vp_layer.c 2016-01-27 12:26:21.266626324 +0100
@@ -206,7 +206,7 @@
{
struct mxr_layer *layer;
.release = mxr_vp_layer_release,
.buffer_set = mxr_vp_buffer_set,
.stream_set = mxr_vp_stream_set,
-diff -Naur backports-3.18.1-1.org/drivers/media/radio/radio-cadet.c backports-3.18.1-1/drivers/media/radio/radio-cadet.c
---- backports-3.18.1-1.org/drivers/media/radio/radio-cadet.c 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/radio/radio-cadet.c 2014-12-28 14:10:09.532888798 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/platform/vivid/vivid-osd.c backports-4.2.6-1/drivers/media/platform/vivid/vivid-osd.c
+--- backports-4.2.6-1.org/drivers/media/platform/vivid/vivid-osd.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/platform/vivid/vivid-osd.c 2016-01-27 12:26:21.269959657 +0100
+@@ -85,6 +85,7 @@
+ case FBIOGET_VBLANK: {
+ struct fb_vblank vblank;
+
++ memset(&vblank, 0, sizeof(vblank));
+ vblank.flags = FB_VBLANK_HAVE_COUNT | FB_VBLANK_HAVE_VCOUNT |
+ FB_VBLANK_HAVE_VSYNC;
+ vblank.count = 0;
+diff -Naur backports-4.2.6-1.org/drivers/media/radio/radio-cadet.c backports-4.2.6-1/drivers/media/radio/radio-cadet.c
+--- backports-4.2.6-1.org/drivers/media/radio/radio-cadet.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/radio/radio-cadet.c 2016-01-27 12:26:21.269959657 +0100
@@ -333,6 +333,8 @@
unsigned char readbuf[RDS_BUFFER];
int i = 0;
return i;
}
-diff -Naur backports-3.18.1-1.org/drivers/media/radio/radio-maxiradio.c backports-3.18.1-1/drivers/media/radio/radio-maxiradio.c
---- backports-3.18.1-1.org/drivers/media/radio/radio-maxiradio.c 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/radio/radio-maxiradio.c 2014-12-28 14:10:09.532888798 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/radio/radio-maxiradio.c backports-4.2.6-1/drivers/media/radio/radio-maxiradio.c
+--- backports-4.2.6-1.org/drivers/media/radio/radio-maxiradio.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/radio/radio-maxiradio.c 2016-01-27 12:26:21.269959657 +0100
@@ -61,7 +61,7 @@
/* TEA5757 pin mappings */
static const int clk = 1, data = 2, wren = 4, mo_st = 8, power = 16;
#define PCI_VENDOR_ID_GUILLEMOT 0x5046
#define PCI_DEVICE_ID_GUILLEMOT_MAXIRADIO 0x1001
-diff -Naur backports-3.18.1-1.org/drivers/media/radio/radio-shark2.c backports-3.18.1-1/drivers/media/radio/radio-shark2.c
---- backports-3.18.1-1.org/drivers/media/radio/radio-shark2.c 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/radio/radio-shark2.c 2014-12-28 14:10:09.532888798 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/radio/radio-shark2.c backports-4.2.6-1/drivers/media/radio/radio-shark2.c
+--- backports-4.2.6-1.org/drivers/media/radio/radio-shark2.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/radio/radio-shark2.c 2016-01-27 12:26:21.269959657 +0100
@@ -74,7 +74,7 @@
u8 *transfer_buffer;
};
static int shark_write_reg(struct radio_tea5777 *tea, u64 reg)
{
-diff -Naur backports-3.18.1-1.org/drivers/media/radio/radio-shark.c backports-3.18.1-1/drivers/media/radio/radio-shark.c
---- backports-3.18.1-1.org/drivers/media/radio/radio-shark.c 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/radio/radio-shark.c 2014-12-28 14:10:09.532888798 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/radio/radio-shark.c backports-4.2.6-1/drivers/media/radio/radio-shark.c
+--- backports-4.2.6-1.org/drivers/media/radio/radio-shark.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/radio/radio-shark.c 2016-01-27 12:26:21.269959657 +0100
@@ -79,7 +79,7 @@
u32 last_val;
};
static void shark_write_val(struct snd_tea575x *tea, u32 val)
{
-diff -Naur backports-3.18.1-1.org/drivers/media/radio/radio-si476x.c backports-3.18.1-1/drivers/media/radio/radio-si476x.c
---- backports-3.18.1-1.org/drivers/media/radio/radio-si476x.c 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/radio/radio-si476x.c 2014-12-28 14:10:09.532888798 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/radio/radio-si476x.c backports-4.2.6-1/drivers/media/radio/radio-si476x.c
+--- backports-4.2.6-1.org/drivers/media/radio/radio-si476x.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/radio/radio-si476x.c 2016-01-27 12:26:21.269959657 +0100
@@ -1445,7 +1445,7 @@
struct si476x_radio *radio;
struct v4l2_ctrl *ctrl;
radio = devm_kzalloc(&pdev->dev, sizeof(*radio), GFP_KERNEL);
if (!radio)
-diff -Naur backports-3.18.1-1.org/drivers/media/usb/dvb-usb/cinergyT2-core.c backports-3.18.1-1/drivers/media/usb/dvb-usb/cinergyT2-core.c
---- backports-3.18.1-1.org/drivers/media/usb/dvb-usb/cinergyT2-core.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/usb/dvb-usb/cinergyT2-core.c 2014-12-28 14:10:09.532888798 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/radio/wl128x/fmdrv_common.c backports-4.2.6-1/drivers/media/radio/wl128x/fmdrv_common.c
+--- backports-4.2.6-1.org/drivers/media/radio/wl128x/fmdrv_common.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/radio/wl128x/fmdrv_common.c 2016-01-27 12:26:21.269959657 +0100
+@@ -71,7 +71,7 @@
+ MODULE_PARM_DESC(rds_buf, "RDS buffer entries");
+
+ /* Radio Nr */
+-static u32 radio_nr = -1;
++static int radio_nr = -1;
+ module_param(radio_nr, int, 0444);
+ MODULE_PARM_DESC(radio_nr, "Radio Nr");
+
+diff -Naur backports-4.2.6-1.org/drivers/media/usb/dvb-usb/cinergyT2-core.c backports-4.2.6-1/drivers/media/usb/dvb-usb/cinergyT2-core.c
+--- backports-4.2.6-1.org/drivers/media/usb/dvb-usb/cinergyT2-core.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/media/usb/dvb-usb/cinergyT2-core.c 2016-01-27 12:26:21.269959657 +0100
@@ -50,29 +50,73 @@
static int cinergyt2_streaming_ctrl(struct dvb_usb_adapter *adap, int enable)
return 0;
}
-diff -Naur backports-3.18.1-1.org/drivers/media/usb/dvb-usb/cinergyT2-fe.c backports-3.18.1-1/drivers/media/usb/dvb-usb/cinergyT2-fe.c
---- backports-3.18.1-1.org/drivers/media/usb/dvb-usb/cinergyT2-fe.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/usb/dvb-usb/cinergyT2-fe.c 2014-12-28 14:10:09.532888798 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/usb/dvb-usb/cinergyT2-fe.c backports-4.2.6-1/drivers/media/usb/dvb-usb/cinergyT2-fe.c
+--- backports-4.2.6-1.org/drivers/media/usb/dvb-usb/cinergyT2-fe.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/media/usb/dvb-usb/cinergyT2-fe.c 2016-01-27 12:26:21.269959657 +0100
@@ -145,103 +145,176 @@
- fe_status_t *status)
+ enum fe_status *status)
{
struct cinergyt2_fe_state *state = fe->demodulator_priv;
- struct dvbt_get_status_msg result;
}
static void cinergyt2_fe_release(struct dvb_frontend *fe)
-diff -Naur backports-3.18.1-1.org/drivers/media/usb/dvb-usb/dvb-usb-firmware.c backports-3.18.1-1/drivers/media/usb/dvb-usb/dvb-usb-firmware.c
---- backports-3.18.1-1.org/drivers/media/usb/dvb-usb/dvb-usb-firmware.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/usb/dvb-usb/dvb-usb-firmware.c 2014-12-28 14:10:09.532888798 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/usb/dvb-usb/dvb-usb-firmware.c backports-4.2.6-1/drivers/media/usb/dvb-usb/dvb-usb-firmware.c
+--- backports-4.2.6-1.org/drivers/media/usb/dvb-usb/dvb-usb-firmware.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/media/usb/dvb-usb/dvb-usb-firmware.c 2016-01-27 12:26:21.269959657 +0100
@@ -35,42 +35,57 @@
int usb_cypress_load_firmware(struct usb_device *udev, const struct firmware *fw, int type)
return ret;
}
EXPORT_SYMBOL(usb_cypress_load_firmware);
-diff -Naur backports-3.18.1-1.org/drivers/media/usb/dvb-usb/dw2102.c backports-3.18.1-1/drivers/media/usb/dvb-usb/dw2102.c
---- backports-3.18.1-1.org/drivers/media/usb/dvb-usb/dw2102.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/usb/dvb-usb/dw2102.c 2014-12-28 14:10:09.536888811 +0100
-@@ -118,7 +118,7 @@
-
- struct s6x0_state {
- int (*old_set_voltage)(struct dvb_frontend *f, fe_sec_voltage_t v);
--};
-+} __no_const;
-
- /* debug */
- static int dvb_usb_dw2102_debug;
-diff -Naur backports-3.18.1-1.org/drivers/media/usb/dvb-usb/technisat-usb2.c backports-3.18.1-1/drivers/media/usb/dvb-usb/technisat-usb2.c
---- backports-3.18.1-1.org/drivers/media/usb/dvb-usb/technisat-usb2.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/usb/dvb-usb/technisat-usb2.c 2014-12-28 14:10:09.536888811 +0100
+diff -Naur backports-4.2.6-1.org/drivers/media/usb/dvb-usb/technisat-usb2.c backports-4.2.6-1/drivers/media/usb/dvb-usb/technisat-usb2.c
+--- backports-4.2.6-1.org/drivers/media/usb/dvb-usb/technisat-usb2.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/media/usb/dvb-usb/technisat-usb2.c 2016-01-27 12:26:21.269959657 +0100
@@ -87,8 +87,11 @@
static int technisat_usb2_i2c_access(struct usb_device *udev,
u8 device_addr, u8 *tx, u8 txlen, u8 *rx, u8 rxlen)
return 0;
}
-@@ -591,10 +615,15 @@
+@@ -594,10 +618,15 @@
static int technisat_usb2_get_ir(struct dvb_usb_device *d)
{
buf[0] = GET_IR_DATA_VENDOR_REQUEST;
buf[1] = 0x08;
buf[2] = 0x8f;
-@@ -617,16 +646,20 @@
+@@ -620,16 +649,20 @@
GET_IR_DATA_VENDOR_REQUEST,
USB_TYPE_VENDOR | USB_DIR_IN,
0x8080, 0,
/* decoding */
b = buf+1;
-@@ -653,6 +686,8 @@
+@@ -656,6 +689,8 @@
ir_raw_event_handle(d->rc_dev);
return 1;
}
-diff -Naur backports-3.18.1-1.org/drivers/media/v4l2-core/v4l2-device.c backports-3.18.1-1/drivers/media/v4l2-core/v4l2-device.c
---- backports-3.18.1-1.org/drivers/media/v4l2-core/v4l2-device.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/v4l2-core/v4l2-device.c 2014-12-28 14:10:09.536888811 +0100
-@@ -75,9 +75,9 @@
+diff -Naur backports-4.2.6-1.org/drivers/media/v4l2-core/v4l2-compat-ioctl32.c backports-4.2.6-1/drivers/media/v4l2-core/v4l2-compat-ioctl32.c
+--- backports-4.2.6-1.org/drivers/media/v4l2-core/v4l2-compat-ioctl32.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/v4l2-core/v4l2-compat-ioctl32.c 2016-01-27 12:26:21.269959657 +0100
+@@ -429,7 +429,7 @@
+ * by passing a very big num_planes value */
+ uplane = compat_alloc_user_space(num_planes *
+ sizeof(struct v4l2_plane));
+- kp->m.planes = (__force struct v4l2_plane *)uplane;
++ kp->m.planes = (__force_kernel struct v4l2_plane *)uplane;
+
+ while (--num_planes >= 0) {
+ ret = get_v4l2_plane32(uplane, uplane32, kp->memory);
+@@ -500,7 +500,7 @@
+ if (num_planes == 0)
+ return 0;
+
+- uplane = (__force struct v4l2_plane __user *)kp->m.planes;
++ uplane = (struct v4l2_plane __force_user *)kp->m.planes;
+ if (get_user(p, &up->m.planes))
+ return -EFAULT;
+ uplane32 = compat_ptr(p);
+@@ -564,7 +564,7 @@
+ get_user(kp->flags, &up->flags) ||
+ copy_from_user(&kp->fmt, &up->fmt, sizeof(up->fmt)))
+ return -EFAULT;
+- kp->base = (__force void *)compat_ptr(tmp);
++ kp->base = (__force_kernel void *)compat_ptr(tmp);
+ return 0;
+ }
+
+@@ -669,7 +669,7 @@
+ n * sizeof(struct v4l2_ext_control32)))
+ return -EFAULT;
+ kcontrols = compat_alloc_user_space(n * sizeof(struct v4l2_ext_control));
+- kp->controls = (__force struct v4l2_ext_control *)kcontrols;
++ kp->controls = (__force_kernel struct v4l2_ext_control *)kcontrols;
+ while (--n >= 0) {
+ u32 id;
+
+@@ -696,7 +696,7 @@
+ {
+ struct v4l2_ext_control32 __user *ucontrols;
+ struct v4l2_ext_control __user *kcontrols =
+- (__force struct v4l2_ext_control __user *)kp->controls;
++ (struct v4l2_ext_control __force_user *)kp->controls;
+ int n = kp->count;
+ compat_caddr_t p;
+
+@@ -780,7 +780,7 @@
+ get_user(tmp, &up->edid) ||
+ copy_from_user(kp->reserved, up->reserved, sizeof(kp->reserved)))
+ return -EFAULT;
+- kp->edid = (__force u8 *)compat_ptr(tmp);
++ kp->edid = (__force_kernel u8 *)compat_ptr(tmp);
+ return 0;
+ }
+
+diff -Naur backports-4.2.6-1.org/drivers/media/v4l2-core/v4l2-device.c backports-4.2.6-1/drivers/media/v4l2-core/v4l2-device.c
+--- backports-4.2.6-1.org/drivers/media/v4l2-core/v4l2-device.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/v4l2-core/v4l2-device.c 2016-01-27 12:26:21.269959657 +0100
+@@ -74,9 +74,9 @@
EXPORT_SYMBOL_GPL(v4l2_device_put);
int v4l2_device_set_name(struct v4l2_device *v4l2_dev, const char *basename,
int len = strlen(basename);
if (basename[len - 1] >= '0' && basename[len - 1] <= '9')
-diff -Naur backports-3.18.1-1.org/drivers/media/v4l2-core/v4l2-ioctl.c backports-3.18.1-1/drivers/media/v4l2-core/v4l2-ioctl.c
---- backports-3.18.1-1.org/drivers/media/v4l2-core/v4l2-ioctl.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/media/v4l2-core/v4l2-ioctl.c 2014-12-28 14:10:09.536888811 +0100
-@@ -2142,7 +2142,8 @@
+diff -Naur backports-4.2.6-1.org/drivers/media/v4l2-core/v4l2-ioctl.c backports-4.2.6-1/drivers/media/v4l2-core/v4l2-ioctl.c
+--- backports-4.2.6-1.org/drivers/media/v4l2-core/v4l2-ioctl.c 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/drivers/media/v4l2-core/v4l2-ioctl.c 2016-01-27 12:26:21.269959657 +0100
+@@ -2341,7 +2341,8 @@
struct file *file, void *fh, void *p);
} u;
void (*debug)(const void *arg, bool write_only);
/* This control needs a priority check */
#define INFO_FL_PRIO (1 << 0)
-@@ -2326,7 +2327,7 @@
+@@ -2525,7 +2526,7 @@
struct video_device *vfd = video_devdata(file);
const struct v4l2_ioctl_ops *ops = vfd->ioctl_ops;
bool write_only = false;
const struct v4l2_ioctl_info *info;
void *fh = file->private_data;
struct v4l2_fh *vfh = NULL;
-@@ -2413,7 +2414,7 @@
+@@ -2616,7 +2617,7 @@
ret = -EINVAL;
break;
}
*kernel_ptr = (void **)&buf->m.planes;
*array_size = sizeof(struct v4l2_plane) * buf->length;
ret = 1;
-@@ -2430,7 +2431,7 @@
+@@ -2633,7 +2634,7 @@
ret = -EINVAL;
break;
}
*kernel_ptr = (void **)&edid->edid;
*array_size = edid->blocks * 128;
ret = 1;
-@@ -2448,7 +2449,7 @@
+@@ -2651,7 +2652,7 @@
ret = -EINVAL;
break;
}
*kernel_ptr = (void **)&ctrls->controls;
*array_size = sizeof(struct v4l2_ext_control)
* ctrls->count;
-@@ -2549,7 +2550,7 @@
+@@ -2752,7 +2753,7 @@
}
if (has_array_args) {
if (copy_to_user(user_ptr, mbuf, array_size))
err = -EFAULT;
goto out_array_args;
-diff -Naur backports-3.18.1-1.org/drivers/net/ieee802154/fakehard.c backports-3.18.1-1/drivers/net/ieee802154/fakehard.c
---- backports-3.18.1-1.org/drivers/net/ieee802154/fakehard.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/ieee802154/fakehard.c 2014-12-28 14:10:09.556888909 +0100
-@@ -365,7 +365,7 @@
- phy->transmit_power = 0xbf;
-
- dev->netdev_ops = &fake_ops;
-- dev->ml_priv = &fake_mlme;
-+ dev->ml_priv = (void *)&fake_mlme;
-
- priv = netdev_priv(dev);
- priv->phy = phy;
-diff -Naur backports-3.18.1-1.org/drivers/net/usb/sierra_net.c backports-3.18.1-1/drivers/net/usb/sierra_net.c
---- backports-3.18.1-1.org/drivers/net/usb/sierra_net.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/usb/sierra_net.c 2014-12-28 14:10:09.560888936 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/usb/sierra_net.c backports-4.2.6-1/drivers/net/usb/sierra_net.c
+--- backports-4.2.6-1.org/drivers/net/usb/sierra_net.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/usb/sierra_net.c 2016-01-27 12:26:21.283292990 +0100
@@ -51,7 +51,7 @@
/* atomic counter partially included in MAC address to make sure 2 devices
* do not end up with the same MAC - concept breaks in case of > 255 ifaces
dev->net->dev_addr[ETH_ALEN-1] = ifacenum;
/* we will have to manufacture ethernet headers, prepare template */
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/at76c50x-usb.c backports-3.18.1-1/drivers/net/wireless/at76c50x-usb.c
---- backports-3.18.1-1.org/drivers/net/wireless/at76c50x-usb.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/at76c50x-usb.c 2014-12-28 14:10:09.560888936 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/airo.c backports-4.2.6-1/drivers/net/wireless/airo.c
+--- backports-4.2.6-1.org/drivers/net/wireless/airo.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/airo.c 2016-01-27 12:26:21.286626323 +0100
+@@ -7846,7 +7846,7 @@
+ struct airo_info *ai = dev->ml_priv;
+ int ridcode;
+ int enabled;
+- static int (* writer)(struct airo_info *, u16 rid, const void *, int, int);
++ int (* writer)(struct airo_info *, u16 rid, const void *, int, int);
+ unsigned char *iobuf;
+
+ /* Only super-user can write RIDs */
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/at76c50x-usb.c backports-4.2.6-1/drivers/net/wireless/at76c50x-usb.c
+--- backports-4.2.6-1.org/drivers/net/wireless/at76c50x-usb.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/at76c50x-usb.c 2016-01-27 12:26:21.286626323 +0100
@@ -353,7 +353,7 @@
}
{
return msecs_to_jiffies((s->poll_timeout[2] << 16)
| (s->poll_timeout[1] << 8)
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/ath/ath10k/htc.c backports-3.18.1-1/drivers/net/wireless/ath/ath10k/htc.c
---- backports-3.18.1-1.org/drivers/net/wireless/ath/ath10k/htc.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/ath/ath10k/htc.c 2014-12-28 14:10:09.560888936 +0100
-@@ -848,7 +848,10 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/ath/ath10k/ce.c backports-4.2.6-1/drivers/net/wireless/ath/ath10k/ce.c
+--- backports-4.2.6-1.org/drivers/net/wireless/ath/ath10k/ce.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/ath/ath10k/ce.c 2016-01-27 12:26:21.286626323 +0100
+@@ -896,12 +896,12 @@
+ return 0;
+ }
+
+-static struct ath10k_ce_ring *
++static struct ath10k_ce_ring * __intentional_overflow(-1)
+ ath10k_ce_alloc_src_ring(struct ath10k *ar, unsigned int ce_id,
+ const struct ce_attr *attr)
+ {
+ struct ath10k_ce_ring *src_ring;
+- u32 nentries = attr->src_nentries;
++ unsigned long nentries = attr->src_nentries;
+ dma_addr_t base_addr;
+
+ nentries = roundup_pow_of_two(nentries);
+@@ -968,7 +968,7 @@
+ const struct ce_attr *attr)
+ {
+ struct ath10k_ce_ring *dest_ring;
+- u32 nentries;
++ unsigned long nentries;
+ dma_addr_t base_addr;
+
+ nentries = roundup_pow_of_two(attr->dest_nentries);
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/ath/ath10k/htc.c backports-4.2.6-1/drivers/net/wireless/ath/ath10k/htc.c
+--- backports-4.2.6-1.org/drivers/net/wireless/ath/ath10k/htc.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/ath/ath10k/htc.c 2016-01-27 12:26:21.286626323 +0100
+@@ -841,7 +841,10 @@
/* registered target arrival callback from the HIF layer */
int ath10k_htc_init(struct ath10k *ar)
{
struct ath10k_htc_ep *ep = NULL;
struct ath10k_htc *htc = &ar->htc;
-@@ -857,8 +860,6 @@
+@@ -850,8 +853,6 @@
ath10k_htc_reset_endpoint_states(htc);
/* setup HIF layer callbacks */
htc->ar = ar;
/* Get HIF default pipe for HTC message exchange */
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/ath/ath10k/htc.h backports-3.18.1-1/drivers/net/wireless/ath/ath10k/htc.h
---- backports-3.18.1-1.org/drivers/net/wireless/ath/ath10k/htc.h 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/ath/ath10k/htc.h 2014-12-28 14:10:09.560888936 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/ath/ath10k/htc.h backports-4.2.6-1/drivers/net/wireless/ath/ath10k/htc.h
+--- backports-4.2.6-1.org/drivers/net/wireless/ath/ath10k/htc.h 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/ath/ath10k/htc.h 2016-01-27 12:26:21.286626323 +0100
@@ -270,13 +270,13 @@
struct ath10k_htc_ops {
/* service connection information */
struct ath10k_htc_svc_conn_req {
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/ath/ath9k/ar9002_mac.c backports-3.18.1-1/drivers/net/wireless/ath/ath9k/ar9002_mac.c
---- backports-3.18.1-1.org/drivers/net/wireless/ath/ath9k/ar9002_mac.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/ath/ath9k/ar9002_mac.c 2014-12-28 14:10:09.560888936 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/ath/ath9k/ar9002_mac.c backports-4.2.6-1/drivers/net/wireless/ath/ath9k/ar9002_mac.c
+--- backports-4.2.6-1.org/drivers/net/wireless/ath/ath9k/ar9002_mac.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/ath/ath9k/ar9002_mac.c 2016-01-27 12:26:21.286626323 +0100
@@ -220,8 +220,8 @@
ads->ds_txstatus6 = ads->ds_txstatus7 = 0;
ads->ds_txstatus8 = ads->ds_txstatus9 = 0;
- ACCESS_ONCE(ads->ds_ctl0) = (i->pkt_len & AR_FrameLen)
+ ACCESS_ONCE_RW(ads->ds_ctl0) = (i->pkt_len & AR_FrameLen)
| (i->flags & ATH9K_TXDESC_VMF ? AR_VirtMoreFrag : 0)
- | SM(i->txpower, AR_XmitPower0)
+ | SM(i->txpower[0], AR_XmitPower0)
| (i->flags & ATH9K_TXDESC_VEOL ? AR_VEOL : 0)
@@ -289,27 +289,27 @@
| (i->flags & ATH9K_TXDESC_RTSENA ? AR_RTSEnable :
| set11nRateFlags(i->rates, 3)
| SM(i->rtscts_rate, AR_RTSCTSRate);
-- ACCESS_ONCE(ads->ds_ctl9) = SM(i->txpower, AR_XmitPower1);
-- ACCESS_ONCE(ads->ds_ctl10) = SM(i->txpower, AR_XmitPower2);
-- ACCESS_ONCE(ads->ds_ctl11) = SM(i->txpower, AR_XmitPower3);
-+ ACCESS_ONCE_RW(ads->ds_ctl9) = SM(i->txpower, AR_XmitPower1);
-+ ACCESS_ONCE_RW(ads->ds_ctl10) = SM(i->txpower, AR_XmitPower2);
-+ ACCESS_ONCE_RW(ads->ds_ctl11) = SM(i->txpower, AR_XmitPower3);
+- ACCESS_ONCE(ads->ds_ctl9) = SM(i->txpower[1], AR_XmitPower1);
+- ACCESS_ONCE(ads->ds_ctl10) = SM(i->txpower[2], AR_XmitPower2);
+- ACCESS_ONCE(ads->ds_ctl11) = SM(i->txpower[3], AR_XmitPower3);
++ ACCESS_ONCE_RW(ads->ds_ctl9) = SM(i->txpower[1], AR_XmitPower1);
++ ACCESS_ONCE_RW(ads->ds_ctl10) = SM(i->txpower[2], AR_XmitPower2);
++ ACCESS_ONCE_RW(ads->ds_ctl11) = SM(i->txpower[3], AR_XmitPower3);
}
static int ar9002_hw_proc_txdesc(struct ath_hw *ah, void *ds,
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/ath/ath9k/ar9003_mac.c backports-3.18.1-1/drivers/net/wireless/ath/ath9k/ar9003_mac.c
---- backports-3.18.1-1.org/drivers/net/wireless/ath/ath9k/ar9003_mac.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/ath/ath9k/ar9003_mac.c 2014-12-28 14:10:09.560888936 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/ath/ath9k/ar9003_mac.c backports-4.2.6-1/drivers/net/wireless/ath/ath9k/ar9003_mac.c
+--- backports-4.2.6-1.org/drivers/net/wireless/ath/ath9k/ar9003_mac.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/ath/ath9k/ar9003_mac.c 2016-01-27 12:26:21.286626323 +0100
@@ -39,47 +39,47 @@
(i->qcu << AR_TxQcuNum_S) | desc_len;
- ACCESS_ONCE(ads->ctl11) = (i->pkt_len & AR_FrameLen)
+ ACCESS_ONCE_RW(ads->ctl11) = (i->pkt_len & AR_FrameLen)
| (i->flags & ATH9K_TXDESC_VMF ? AR_VirtMoreFrag : 0)
- | SM(i->txpower, AR_XmitPower0)
+ | SM(i->txpower[0], AR_XmitPower0)
| (i->flags & ATH9K_TXDESC_VEOL ? AR_VEOL : 0)
@@ -135,26 +135,26 @@
val = (i->flags & ATH9K_TXDESC_PAPRD) >> ATH9K_TXDESC_PAPRD_S;
- ACCESS_ONCE(ads->ctl19) = AR_Not_Sounding;
+ ACCESS_ONCE_RW(ads->ctl19) = AR_Not_Sounding;
-- ACCESS_ONCE(ads->ctl20) = SM(i->txpower, AR_XmitPower1);
-- ACCESS_ONCE(ads->ctl21) = SM(i->txpower, AR_XmitPower2);
-- ACCESS_ONCE(ads->ctl22) = SM(i->txpower, AR_XmitPower3);
-+ ACCESS_ONCE_RW(ads->ctl20) = SM(i->txpower, AR_XmitPower1);
-+ ACCESS_ONCE_RW(ads->ctl21) = SM(i->txpower, AR_XmitPower2);
-+ ACCESS_ONCE_RW(ads->ctl22) = SM(i->txpower, AR_XmitPower3);
+- ACCESS_ONCE(ads->ctl20) = SM(i->txpower[1], AR_XmitPower1);
+- ACCESS_ONCE(ads->ctl21) = SM(i->txpower[2], AR_XmitPower2);
+- ACCESS_ONCE(ads->ctl22) = SM(i->txpower[3], AR_XmitPower3);
++ ACCESS_ONCE_RW(ads->ctl20) = SM(i->txpower[1], AR_XmitPower1);
++ ACCESS_ONCE_RW(ads->ctl21) = SM(i->txpower[2], AR_XmitPower2);
++ ACCESS_ONCE_RW(ads->ctl22) = SM(i->txpower[3], AR_XmitPower3);
}
static u16 ar9003_calc_ptr_chksum(struct ar9003_txc *ads)
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/ath/ath9k/hw.h backports-3.18.1-1/drivers/net/wireless/ath/ath9k/hw.h
---- backports-3.18.1-1.org/drivers/net/wireless/ath/ath9k/hw.h 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/ath/ath9k/hw.h 2014-12-28 14:10:09.564888946 +0100
-@@ -630,7 +630,7 @@
-
- /* ANI */
- void (*ani_cache_ini_regs)(struct ath_hw *ah);
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/ath/ath9k/hw.h backports-4.2.6-1/drivers/net/wireless/ath/ath9k/hw.h
+--- backports-4.2.6-1.org/drivers/net/wireless/ath/ath9k/hw.h 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/ath/ath9k/hw.h 2016-01-27 12:33:44.649931973 +0100
+@@ -671,7 +671,7 @@
+ #ifdef CPTCFG_ATH9K_BTCOEX_SUPPORT
+ bool (*is_aic_enabled)(struct ath_hw *ah);
+ #endif /* CPTCFG_ATH9K_BTCOEX_SUPPORT */
-};
+} __no_const;
/**
* struct ath_spec_scan - parameters for Atheros spectral scan
-@@ -708,7 +708,7 @@
+@@ -747,7 +747,7 @@
#ifdef CPTCFG_ATH9K_BTCOEX_SUPPORT
void (*set_bt_ant_diversity)(struct ath_hw *hw, bool enable);
#endif
struct ath_nf_limits {
s16 max;
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/ath/ath9k/main.c backports-3.18.1-1/drivers/net/wireless/ath/ath9k/main.c
---- backports-3.18.1-1.org/drivers/net/wireless/ath/ath9k/main.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/ath/ath9k/main.c 2014-12-28 14:24:49.169250593 +0100
-@@ -2454,16 +2454,18 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/ath/ath9k/Kconfig backports-4.2.6-1/drivers/net/wireless/ath/ath9k/Kconfig
+--- backports-4.2.6-1.org/drivers/net/wireless/ath/ath9k/Kconfig 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/ath/ath9k/Kconfig 2016-01-27 12:34:48.923262299 +0100
+@@ -5,7 +5,6 @@
+ tristate
+ depends on m
+ select ATH_COMMON
+- depends on DEBUG_FS
+ depends on RELAY
+ config ATH9K_DFS_DEBUGFS
+ def_bool y
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/ath/ath9k/main.c backports-4.2.6-1/drivers/net/wireless/ath/ath9k/main.c
+--- backports-4.2.6-1.org/drivers/net/wireless/ath/ath9k/main.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/ath/ath9k/main.c 2016-01-27 12:26:21.289959656 +0100
+@@ -2574,16 +2574,18 @@
if (!ath9k_is_chanctx_enabled())
return;
}
#endif
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/b43/phy_lp.c backports-3.18.1-1/drivers/net/wireless/b43/phy_lp.c
---- backports-3.18.1-1.org/drivers/net/wireless/b43/phy_lp.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/b43/phy_lp.c 2014-12-28 14:10:09.564888946 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/b43/phy_lp.c backports-4.2.6-1/drivers/net/wireless/b43/phy_lp.c
+--- backports-4.2.6-1.org/drivers/net/wireless/b43/phy_lp.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/b43/phy_lp.c 2016-01-27 12:26:21.289959656 +0100
@@ -2502,7 +2502,7 @@
{
struct ssb_bus *bus = dev->dev->sdev->bus;
u32 crystal_freq = bus->chipco.pmu.crystalfreq * 1000;
u32 freqref, vco_freq, val1, val2, val3, timeout, timeoutref, count;
u16 old_comm15, scale;
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/iwlegacy/3945-mac.c backports-3.18.1-1/drivers/net/wireless/iwlegacy/3945-mac.c
---- backports-3.18.1-1.org/drivers/net/wireless/iwlegacy/3945-mac.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/iwlegacy/3945-mac.c 2014-12-28 14:10:09.564888946 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/iwlegacy/3945-mac.c backports-4.2.6-1/drivers/net/wireless/iwlegacy/3945-mac.c
+--- backports-4.2.6-1.org/drivers/net/wireless/iwlegacy/3945-mac.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/iwlegacy/3945-mac.c 2016-01-27 12:26:21.289959656 +0100
@@ -3633,7 +3633,9 @@
*/
if (il3945_mod_params.disable_hw_scan) {
}
D_INFO("*** LOAD DRIVER ***\n");
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/iwlwifi/dvm/debugfs.c backports-3.18.1-1/drivers/net/wireless/iwlwifi/dvm/debugfs.c
---- backports-3.18.1-1.org/drivers/net/wireless/iwlwifi/dvm/debugfs.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/iwlwifi/dvm/debugfs.c 2014-12-28 14:10:09.564888946 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/iwlwifi/dvm/debugfs.c backports-4.2.6-1/drivers/net/wireless/iwlwifi/dvm/debugfs.c
+--- backports-4.2.6-1.org/drivers/net/wireless/iwlwifi/dvm/debugfs.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/iwlwifi/dvm/debugfs.c 2016-01-27 12:26:21.289959656 +0100
@@ -188,7 +188,7 @@
{
struct iwl_priv *priv = file->private_data;
memset(buf, 0, sizeof(buf));
buf_size = min(count, sizeof(buf) - 1);
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/iwlwifi/pcie/trans.c backports-3.18.1-1/drivers/net/wireless/iwlwifi/pcie/trans.c
---- backports-3.18.1-1.org/drivers/net/wireless/iwlwifi/pcie/trans.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/iwlwifi/pcie/trans.c 2014-12-28 14:10:09.564888946 +0100
-@@ -1689,7 +1689,7 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/iwlwifi/pcie/trans.c backports-4.2.6-1/drivers/net/wireless/iwlwifi/pcie/trans.c
+--- backports-4.2.6-1.org/drivers/net/wireless/iwlwifi/pcie/trans.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/iwlwifi/pcie/trans.c 2016-01-27 12:26:21.289959656 +0100
+@@ -1950,7 +1950,7 @@
struct isr_statistics *isr_stats = &trans_pcie->isr_stats;
char buf[8];
u32 reset_flag;
memset(buf, 0, sizeof(buf));
-@@ -1710,7 +1710,7 @@
+@@ -1971,7 +1971,7 @@
{
struct iwl_trans *trans = file->private_data;
char buf[8];
int csr;
memset(buf, 0, sizeof(buf));
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/mac80211_hwsim.c backports-3.18.1-1/drivers/net/wireless/mac80211_hwsim.c
---- backports-3.18.1-1.org/drivers/net/wireless/mac80211_hwsim.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/mac80211_hwsim.c 2014-12-28 14:10:09.568888967 +0100
-@@ -2578,20 +2578,20 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/mac80211_hwsim.c backports-4.2.6-1/drivers/net/wireless/mac80211_hwsim.c
+--- backports-4.2.6-1.org/drivers/net/wireless/mac80211_hwsim.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/mac80211_hwsim.c 2016-01-27 12:26:21.289959656 +0100
+@@ -3150,20 +3150,20 @@
if (channels < 1)
return -EINVAL;
spin_lock_init(&hwsim_radio_lock);
INIT_LIST_HEAD(&hwsim_radios);
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/rndis_wlan.c backports-3.18.1-1/drivers/net/wireless/rndis_wlan.c
---- backports-3.18.1-1.org/drivers/net/wireless/rndis_wlan.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/rndis_wlan.c 2014-12-28 14:10:09.568888967 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/rndis_wlan.c backports-4.2.6-1/drivers/net/wireless/rndis_wlan.c
+--- backports-4.2.6-1.org/drivers/net/wireless/rndis_wlan.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/rndis_wlan.c 2016-01-27 12:26:21.293292990 +0100
@@ -1236,7 +1236,7 @@
netdev_dbg(usbdev->net, "%s(): %i\n", __func__, rts_threshold);
rts_threshold = 2347;
tmp = cpu_to_le32(rts_threshold);
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/rt2x00/rt2x00.h backports-3.18.1-1/drivers/net/wireless/rt2x00/rt2x00.h
---- backports-3.18.1-1.org/drivers/net/wireless/rt2x00/rt2x00.h 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/rt2x00/rt2x00.h 2014-12-28 14:10:09.568888967 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/rt2x00/rt2x00.h backports-4.2.6-1/drivers/net/wireless/rt2x00/rt2x00.h
+--- backports-4.2.6-1.org/drivers/net/wireless/rt2x00/rt2x00.h 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/rt2x00/rt2x00.h 2016-01-27 12:26:21.293292990 +0100
@@ -375,7 +375,7 @@
* for hardware which doesn't support hardware
* sequence counting.
};
static inline struct rt2x00_intf* vif_to_intf(struct ieee80211_vif *vif)
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/rt2x00/rt2x00queue.c backports-3.18.1-1/drivers/net/wireless/rt2x00/rt2x00queue.c
---- backports-3.18.1-1.org/drivers/net/wireless/rt2x00/rt2x00queue.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/rt2x00/rt2x00queue.c 2014-12-28 14:10:09.568888967 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/rt2x00/rt2x00queue.c backports-4.2.6-1/drivers/net/wireless/rt2x00/rt2x00queue.c
+--- backports-4.2.6-1.org/drivers/net/wireless/rt2x00/rt2x00queue.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/rt2x00/rt2x00queue.c 2016-01-27 12:26:21.293292990 +0100
@@ -224,9 +224,9 @@
* sequence counter given by mac80211.
*/
hdr->seq_ctrl &= cpu_to_le16(IEEE80211_SCTL_FRAG);
hdr->seq_ctrl |= cpu_to_le16(seqno);
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/ti/wl1251/sdio.c backports-3.18.1-1/drivers/net/wireless/ti/wl1251/sdio.c
---- backports-3.18.1-1.org/drivers/net/wireless/ti/wl1251/sdio.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/ti/wl1251/sdio.c 2014-12-28 14:10:09.568888967 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/ti/wl1251/sdio.c backports-4.2.6-1/drivers/net/wireless/ti/wl1251/sdio.c
+--- backports-4.2.6-1.org/drivers/net/wireless/ti/wl1251/sdio.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/ti/wl1251/sdio.c 2016-01-27 12:26:21.293292990 +0100
@@ -282,13 +282,17 @@
irq_set_irq_type(wl->irq, IRQ_TYPE_EDGE_RISING);
wl1251_info("using SDIO interrupt");
}
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/ti/wl12xx/main.c backports-3.18.1-1/drivers/net/wireless/ti/wl12xx/main.c
---- backports-3.18.1-1.org/drivers/net/wireless/ti/wl12xx/main.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/ti/wl12xx/main.c 2014-12-28 14:10:09.568888967 +0100
-@@ -656,7 +656,9 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/ti/wl12xx/main.c backports-4.2.6-1/drivers/net/wireless/ti/wl12xx/main.c
+--- backports-4.2.6-1.org/drivers/net/wireless/ti/wl12xx/main.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/ti/wl12xx/main.c 2016-01-27 12:26:21.293292990 +0100
+@@ -655,7 +655,9 @@
sizeof(wl->conf.mem));
/* read data preparation is only needed by wl127x */
wlcore_set_min_fw_ver(wl, WL127X_CHIP_VER,
WL127X_IFTYPE_SR_VER, WL127X_MAJOR_SR_VER,
-@@ -681,7 +683,9 @@
+@@ -680,7 +682,9 @@
sizeof(wl->conf.mem));
/* read data preparation is only needed by wl127x */
wlcore_set_min_fw_ver(wl, WL127X_CHIP_VER,
WL127X_IFTYPE_SR_VER, WL127X_MAJOR_SR_VER,
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/ti/wl18xx/main.c backports-3.18.1-1/drivers/net/wireless/ti/wl18xx/main.c
---- backports-3.18.1-1.org/drivers/net/wireless/ti/wl18xx/main.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/ti/wl18xx/main.c 2014-12-28 14:10:09.568888967 +0100
-@@ -1916,8 +1916,10 @@
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/ti/wl18xx/main.c backports-4.2.6-1/drivers/net/wireless/ti/wl18xx/main.c
+--- backports-4.2.6-1.org/drivers/net/wireless/ti/wl18xx/main.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/ti/wl18xx/main.c 2016-01-27 12:26:21.293292990 +0100
+@@ -1952,8 +1952,10 @@
}
if (!checksum_param) {
}
/* Enable 11a Band only if we have 5G antennas */
-diff -Naur backports-3.18.1-1.org/drivers/net/wireless/zd1211rw/zd_usb.c backports-3.18.1-1/drivers/net/wireless/zd1211rw/zd_usb.c
---- backports-3.18.1-1.org/drivers/net/wireless/zd1211rw/zd_usb.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/net/wireless/zd1211rw/zd_usb.c 2014-12-28 14:10:09.568888967 +0100
+diff -Naur backports-4.2.6-1.org/drivers/net/wireless/zd1211rw/zd_usb.c backports-4.2.6-1/drivers/net/wireless/zd1211rw/zd_usb.c
+--- backports-4.2.6-1.org/drivers/net/wireless/zd1211rw/zd_usb.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/net/wireless/zd1211rw/zd_usb.c 2016-01-27 12:26:21.293292990 +0100
@@ -385,7 +385,7 @@
{
struct zd_usb *usb = urb->context;
u16 int_num;
ZD_ASSERT(in_interrupt());
-diff -Naur backports-3.18.1-1.org/drivers/nfc/nfcwilink.c backports-3.18.1-1/drivers/nfc/nfcwilink.c
---- backports-3.18.1-1.org/drivers/nfc/nfcwilink.c 2014-12-21 22:37:14.000000000 +0100
-+++ backports-3.18.1-1/drivers/nfc/nfcwilink.c 2014-12-28 14:10:09.568888967 +0100
+diff -Naur backports-4.2.6-1.org/drivers/nfc/nfcwilink.c backports-4.2.6-1/drivers/nfc/nfcwilink.c
+--- backports-4.2.6-1.org/drivers/nfc/nfcwilink.c 2015-11-15 22:19:39.000000000 +0100
++++ backports-4.2.6-1/drivers/nfc/nfcwilink.c 2016-01-27 12:26:21.293292990 +0100
@@ -497,7 +497,7 @@
static int nfcwilink_probe(struct platform_device *pdev)
int rc;
__u32 protocols;
-diff -Naur backports-3.18.1-1.org/include/linux/gracl_compat.h backports-3.18.1-1/include/linux/gracl_compat.h
---- backports-3.18.1-1.org/include/linux/gracl_compat.h 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/include/linux/gracl_compat.h 2014-12-28 14:10:09.684889542 +0100
+diff -Naur backports-4.2.6-1.org/include/linux/gracl_compat.h backports-4.2.6-1/include/linux/gracl_compat.h
+--- backports-4.2.6-1.org/include/linux/gracl_compat.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/include/linux/gracl_compat.h 2016-01-27 12:26:26.289959354 +0100
@@ -0,0 +1,156 @@
+#ifndef GR_ACL_COMPAT_H
+#define GR_ACL_COMPAT_H
+
+struct acl_subject_label_compat {
+ compat_uptr_t filename;
-+ compat_ino_t inode;
++ compat_u64 inode;
+ __u32 device;
+ __u32 mode;
+ kernel_cap_t cap_mask;
+
+struct acl_object_label_compat {
+ compat_uptr_t filename;
-+ compat_ino_t inode;
++ compat_u64 inode;
+ __u32 device;
+ __u32 mode;
+
+ unsigned char sp_role[GR_SPROLE_LEN];
+ compat_uptr_t sprole_pws;
+ __u32 segv_device;
-+ compat_ino_t segv_inode;
++ compat_u64 segv_inode;
+ uid_t segv_uid;
+ __u16 num_sprole_pws;
+ __u16 mode;
+};
+
+#endif
-diff -Naur backports-3.18.1-1.org/include/linux/gracl.h backports-3.18.1-1/include/linux/gracl.h
---- backports-3.18.1-1.org/include/linux/gracl.h 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/include/linux/gracl.h 2014-12-28 14:10:09.684889542 +0100
-@@ -0,0 +1,340 @@
+diff -Naur backports-4.2.6-1.org/include/linux/gracl.h backports-4.2.6-1/include/linux/gracl.h
+--- backports-4.2.6-1.org/include/linux/gracl.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/include/linux/gracl.h 2016-01-27 12:26:26.289959354 +0100
+@@ -0,0 +1,342 @@
+#ifndef GR_ACL_H
+#define GR_ACL_H
+
+
+/* Major status information */
+
-+#define GR_VERSION "grsecurity 3.0"
-+#define GRSECURITY_VERSION 0x3000
++#define GR_VERSION "grsecurity 3.1"
++#define GRSECURITY_VERSION 0x3100
+
+enum {
+ GR_SHUTDOWN = 0,
+
+struct name_entry {
+ __u32 key;
-+ ino_t inode;
++ u64 inode;
+ dev_t device;
+ char *name;
+ __u16 len;
+
+struct acl_subject_label {
+ char *filename;
-+ ino_t inode;
++ u64 inode;
+ dev_t device;
+ __u32 mode;
+ kernel_cap_t cap_mask;
+
+struct acl_object_label {
+ char *filename;
-+ ino_t inode;
++ u64 inode;
+ dev_t device;
+ __u32 mode;
+
+ unsigned char sp_role[GR_SPROLE_LEN];
+ struct sprole_pw *sprole_pws;
+ dev_t segv_device;
-+ ino_t segv_inode;
++ u64 segv_inode;
+ uid_t segv_uid;
+ __u16 num_sprole_pws;
+ __u16 mode;
+}
+
+static __inline__ unsigned int
-+gr_fhash(const ino_t ino, const dev_t dev, const unsigned int sz)
++gr_fhash(const u64 ino, const dev_t dev, const unsigned int sz)
+{
-+ return (((ino + dev) ^ ((ino << 13) + (ino << 23) + (dev << 9))) % sz);
++ unsigned int rem;
++ div_u64_rem((ino + dev) ^ ((ino << 13) + (ino << 23) + (dev << 9)), sz, &rem);
++ return rem;
+}
+
+static __inline__ unsigned int
+
+#endif
+
-diff -Naur backports-3.18.1-1.org/include/linux/gralloc.h backports-3.18.1-1/include/linux/gralloc.h
---- backports-3.18.1-1.org/include/linux/gralloc.h 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/include/linux/gralloc.h 2014-12-28 14:10:09.684889542 +0100
+diff -Naur backports-4.2.6-1.org/include/linux/gralloc.h backports-4.2.6-1/include/linux/gralloc.h
+--- backports-4.2.6-1.org/include/linux/gralloc.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/include/linux/gralloc.h 2016-01-27 12:26:26.289959354 +0100
@@ -0,0 +1,9 @@
+#ifndef __GRALLOC_H
+#define __GRALLOC_H
+void *acl_alloc_num(unsigned long num, unsigned long len);
+
+#endif
-diff -Naur backports-3.18.1-1.org/include/linux/grdefs.h backports-3.18.1-1/include/linux/grdefs.h
---- backports-3.18.1-1.org/include/linux/grdefs.h 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/include/linux/grdefs.h 2014-12-28 14:10:09.688889562 +0100
+diff -Naur backports-4.2.6-1.org/include/linux/grdefs.h backports-4.2.6-1/include/linux/grdefs.h
+--- backports-4.2.6-1.org/include/linux/grdefs.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/include/linux/grdefs.h 2016-01-27 12:26:26.289959354 +0100
@@ -0,0 +1,140 @@
+#ifndef GRDEFS_H
+#define GRDEFS_H
+};
+
+#endif
-diff -Naur backports-3.18.1-1.org/include/linux/grinternal.h backports-3.18.1-1/include/linux/grinternal.h
---- backports-3.18.1-1.org/include/linux/grinternal.h 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/include/linux/grinternal.h 2014-12-28 14:10:09.688889562 +0100
-@@ -0,0 +1,229 @@
+diff -Naur backports-4.2.6-1.org/include/linux/grinternal.h backports-4.2.6-1/include/linux/grinternal.h
+--- backports-4.2.6-1.org/include/linux/grinternal.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/include/linux/grinternal.h 2016-01-27 12:26:26.289959354 +0100
+@@ -0,0 +1,230 @@
+#ifndef __GRINTERNAL_H
+#define __GRINTERNAL_H
+
+extern int grsec_enable_chroot_nice;
+extern int grsec_enable_chroot_execlog;
+extern int grsec_enable_chroot_caps;
++extern int grsec_enable_chroot_rename;
+extern int grsec_enable_chroot_sysctl;
+extern int grsec_enable_chroot_unix;
+extern int grsec_enable_symlinkown;
+#define gr_log_fs_str(audit, msg, dentry, mnt, str) gr_log_varargs(audit, msg, GR_FILENAME_STR, dentry, mnt, str)
+#define gr_log_fs_int2(audit, msg, dentry, mnt, num1, num2) gr_log_varargs(audit, msg, GR_FILENAME_TWO_INT, dentry, mnt, num1, num2)
+#define gr_log_fs_int2_str(audit, msg, dentry, mnt, num1, num2, str) gr_log_varargs(audit, msg, GR_FILENAME_TWO_INT_STR, dentry, mnt, num1, num2, str)
-+#define gr_log_textrel_ulong_ulong(audit, msg, file, ulong1, ulong2) gr_log_varargs(audit, msg, GR_TEXTREL, file, ulong1, ulong2)
++#define gr_log_textrel_ulong_ulong(audit, msg, str, file, ulong1, ulong2) gr_log_varargs(audit, msg, GR_TEXTREL, str, file, ulong1, ulong2)
+#define gr_log_ptrace(audit, msg, task) gr_log_varargs(audit, msg, GR_PTRACE, task)
+#define gr_log_res_ulong2_str(audit, msg, task, ulong1, str, ulong2) gr_log_varargs(audit, msg, GR_RESOURCE, task, ulong1, str, ulong2)
+#define gr_log_cap(audit, msg, task, str) gr_log_varargs(audit, msg, GR_CAP, task, str)
+#endif
+
+#endif
-diff -Naur backports-3.18.1-1.org/include/linux/grmsg.h backports-3.18.1-1/include/linux/grmsg.h
---- backports-3.18.1-1.org/include/linux/grmsg.h 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/include/linux/grmsg.h 2014-12-28 14:10:09.688889562 +0100
-@@ -0,0 +1,117 @@
+diff -Naur backports-4.2.6-1.org/include/linux/grmsg.h backports-4.2.6-1/include/linux/grmsg.h
+--- backports-4.2.6-1.org/include/linux/grmsg.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/include/linux/grmsg.h 2016-01-27 12:26:26.289959354 +0100
+@@ -0,0 +1,118 @@
+#define DEFAULTSECMSG "%.256s[%.16s:%d] uid/euid:%u/%u gid/egid:%u/%u, parent %.256s[%.16s:%d] uid/euid:%u/%u gid/egid:%u/%u"
+#define GR_ACL_PROCACCT_MSG "%.256s[%.16s:%d] IP:%pI4 TTY:%.64s uid/euid:%u/%u gid/egid:%u/%u run time:[%ud %uh %um %us] cpu time:[%ud %uh %um %us] %s with exit code %ld, parent %.256s[%.16s:%d] IP:%pI4 TTY:%.64s uid/euid:%u/%u gid/egid:%u/%u"
+#define GR_PTRACE_ACL_MSG "denied ptrace of %.950s(%.16s:%d) by "
+#define GR_ATIME_ACL_MSG "%s access time change of %.950s by "
+#define GR_ACCESS_ACL_MSG "%s access of %.950s for%s%s%s by "
+#define GR_CHROOT_CHROOT_MSG "denied double chroot to %.950s by "
++#define GR_CHROOT_RENAME_MSG "denied bad rename of %.950s out of a chroot by "
+#define GR_CHMOD_CHROOT_MSG "denied chmod +s of %.950s by "
+#define GR_CHMOD_ACL_MSG "%s chmod of %.950s by "
+#define GR_CHROOT_FCHDIR_MSG "denied fchdir outside of chroot to %.950s by "
+#define GR_RESOURCE_MSG "denied resource overstep by requesting %lu for %.16s against limit %lu for "
+#define GR_RWXMMAP_MSG "denied RWX mmap of %.950s by "
+#define GR_RWXMPROTECT_MSG "denied RWX mprotect of %.950s by "
-+#define GR_TEXTREL_AUDIT_MSG "denied text relocation in %.950s, VMA:0x%08lx 0x%08lx by "
++#define GR_TEXTREL_AUDIT_MSG "allowed %s text relocation transition in %.950s, VMA:0x%08lx 0x%08lx by "
+#define GR_PTGNUSTACK_MSG "denied marking stack executable as requested by PT_GNU_STACK marking in %.950s by "
+#define GR_VM86_MSG "denied use of vm86 by "
+#define GR_PTRACE_AUDIT_MSG "process %.950s(%.16s:%d) attached to via ptrace by "
+#define GR_BRUTE_SUID_MSG "bruteforce prevention initiated due to crash of %.950s against uid %u, banning suid/sgid execs for %u minutes. Please investigate the crash report for "
+#define GR_IPC_DENIED_MSG "denied %s of overly-permissive IPC object with creator uid %u by "
+#define GR_MSRWRITE_MSG "denied write to CPU MSR by "
-diff -Naur backports-3.18.1-1.org/include/linux/grsecurity.h backports-3.18.1-1/include/linux/grsecurity.h
---- backports-3.18.1-1.org/include/linux/grsecurity.h 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/include/linux/grsecurity.h 2014-12-28 14:10:09.688889562 +0100
-@@ -0,0 +1,254 @@
+diff -Naur backports-4.2.6-1.org/include/linux/grsecurity.h backports-4.2.6-1/include/linux/grsecurity.h
+--- backports-4.2.6-1.org/include/linux/grsecurity.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/include/linux/grsecurity.h 2016-01-27 12:26:26.289959354 +0100
+@@ -0,0 +1,255 @@
+#ifndef GR_SECURITY_H
+#define GR_SECURITY_H
+#include <linux/fs.h>
+#include <linux/gracl.h>
+
+/* notify of brain-dead configs */
++#if defined(CONFIG_DEBUG_FS) && defined(CONFIG_GRKERNSEC_KMEM)
++#error "CONFIG_DEBUG_FS being enabled is a security risk when CONFIG_GRKERNSEC_KMEM is enabled"
++#endif
++#if defined(CONFIG_PROC_PAGE_MONITOR) && defined(CONFIG_GRKERNSEC)
++#error "CONFIG_PROC_PAGE_MONITOR is a security risk"
++#endif
+#if defined(CONFIG_GRKERNSEC_PROC_USER) && defined(CONFIG_GRKERNSEC_PROC_USERGROUP)
+#error "CONFIG_GRKERNSEC_PROC_USER and CONFIG_GRKERNSEC_PROC_USERGROUP cannot both be enabled."
+#endif
+ const struct vfsmount *mnt);
+void gr_log_remount(const char *devname, const int retval);
+void gr_log_unmount(const char *devname, const int retval);
-+void gr_log_mount(const char *from, const char *to, const int retval);
-+void gr_log_textrel(struct vm_area_struct *vma);
++void gr_log_mount(const char *from, struct path *to, const int retval);
++void gr_log_textrel(struct vm_area_struct *vma, bool is_textrel_rw);
+void gr_log_ptgnustack(struct file *file);
+void gr_log_rwxmmap(struct file *file);
+void gr_log_rwxmprotect(struct vm_area_struct *vma);
+
-+int gr_handle_follow_link(const struct inode *parent,
-+ const struct inode *inode,
-+ const struct dentry *dentry,
++int gr_handle_follow_link(const struct dentry *dentry,
+ const struct vfsmount *mnt);
+int gr_handle_fifo(const struct dentry *dentry,
+ const struct vfsmount *mnt,
+ const int acc_mode);
+int gr_handle_hardlink(const struct dentry *dentry,
+ const struct vfsmount *mnt,
-+ struct inode *inode,
-+ const int mode, const struct filename *to);
++ const struct filename *to);
+
+int gr_is_capable(const int cap);
+int gr_is_capable_nolog(const int cap);
+ const struct vfsmount *parent_mnt);
+__u32 gr_acl_handle_rmdir(const struct dentry *dentry,
+ const struct vfsmount *mnt);
-+void gr_handle_delete(const ino_t ino, const dev_t dev);
++void gr_handle_delete(const u64 ino, const dev_t dev);
+__u32 gr_acl_handle_unlink(const struct dentry *dentry,
+ const struct vfsmount *mnt);
+__u32 gr_acl_handle_symlink(const struct dentry *new_dentry,
+ const struct dentry *old_dentry,
+ const struct vfsmount *old_mnt);
+int gr_acl_handle_filldir(const struct file *file, const char *name,
-+ const unsigned int namelen, const ino_t ino);
++ const unsigned int namelen, const u64 ino);
+
+__u32 gr_acl_handle_unix(const struct dentry *dentry,
+ const struct vfsmount *mnt);
+int gr_handle_rofs_blockwrite(struct dentry *dentry, struct vfsmount *mnt, int acc_mode);
+void gr_audit_ptrace(struct task_struct *task);
+dev_t gr_get_dev_from_dentry(struct dentry *dentry);
++u64 gr_get_ino_from_dentry(struct dentry *dentry);
+void gr_put_exec_file(struct task_struct *task);
+
++int gr_get_symlinkown_enabled(void);
++
+int gr_ptrace_readexec(struct file *file, int unsafe_flags);
+
-+#if defined(CONFIG_GRKERNSEC) && (defined(CONFIG_GRKERNSEC_RESLOG) || !defined(CONFIG_GRKERNSEC_NO_RBAC))
-+extern void gr_learn_resource(const struct task_struct *task, const int res,
-+ const unsigned long wanted, const int gt);
-+#else
-+static inline void gr_learn_resource(const struct task_struct *task, const int res,
-+ const unsigned long wanted, const int gt)
-+{
-+}
-+#endif
++void gr_inc_chroot_refcnts(struct dentry *dentry, struct vfsmount *mnt);
++void gr_dec_chroot_refcnts(struct dentry *dentry, struct vfsmount *mnt);
++int gr_bad_chroot_rename(struct dentry *olddentry, struct vfsmount *oldmnt,
++ struct dentry *newdentry, struct vfsmount *newmnt);
+
+#ifdef CONFIG_GRKERNSEC_RESLOG
+extern void gr_log_resource(const struct task_struct *task, const int res,
+#endif
+
+#endif
-diff -Naur backports-3.18.1-1.org/include/linux/grsock.h backports-3.18.1-1/include/linux/grsock.h
---- backports-3.18.1-1.org/include/linux/grsock.h 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/include/linux/grsock.h 2014-12-28 14:10:09.688889562 +0100
+diff -Naur backports-4.2.6-1.org/include/linux/grsock.h backports-4.2.6-1/include/linux/grsock.h
+--- backports-4.2.6-1.org/include/linux/grsock.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/include/linux/grsock.h 2016-01-27 12:26:26.289959354 +0100
@@ -0,0 +1,19 @@
+#ifndef __GRSOCK_H
+#define __GRSOCK_H
+ const int protocol);
+
+#endif
-diff -Naur backports-3.18.1-1.org/include/linux/unaligned/access_ok.h backports-3.18.1-1/include/linux/unaligned/access_ok.h
---- backports-3.18.1-1.org/include/linux/unaligned/access_ok.h 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/include/linux/unaligned/access_ok.h 2014-12-28 14:10:09.712889681 +0100
+diff -Naur backports-4.2.6-1.org/include/linux/netfilter/xt_gradm.h backports-4.2.6-1/include/linux/netfilter/xt_gradm.h
+--- backports-4.2.6-1.org/include/linux/netfilter/xt_gradm.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/include/linux/netfilter/xt_gradm.h 2016-01-27 12:26:31.209959056 +0100
+@@ -0,0 +1,9 @@
++#ifndef _LINUX_NETFILTER_XT_GRADM_H
++#define _LINUX_NETFILTER_XT_GRADM_H 1
++
++struct xt_gradm_mtinfo {
++ __u16 flags;
++ __u16 invflags;
++};
++
++#endif
+diff -Naur backports-4.2.6-1.org/include/linux/unaligned/access_ok.h backports-4.2.6-1/include/linux/unaligned/access_ok.h
+--- backports-4.2.6-1.org/include/linux/unaligned/access_ok.h 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/include/linux/unaligned/access_ok.h 2016-01-27 12:26:31.219959057 +0100
@@ -4,34 +4,34 @@
#include <linux/kernel.h>
#include <asm/byteorder.h>
}
static inline void put_unaligned_le16(u16 val, void *p)
-diff -Naur backports-3.18.1-1.org/include/media/v4l2-dev.h backports-3.18.1-1/include/media/v4l2-dev.h
---- backports-3.18.1-1.org/include/media/v4l2-dev.h 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/include/media/v4l2-dev.h 2014-12-28 14:10:09.716889709 +0100
-@@ -75,7 +75,7 @@
+diff -Naur backports-4.2.6-1.org/include/media/v4l2-dev.h backports-4.2.6-1/include/media/v4l2-dev.h
+--- backports-4.2.6-1.org/include/media/v4l2-dev.h 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/include/media/v4l2-dev.h 2016-01-27 12:26:31.219959057 +0100
+@@ -74,7 +74,7 @@
int (*mmap) (struct file *, struct vm_area_struct *);
int (*open) (struct file *);
int (*release) (struct file *);
/*
* Newer version of video_device, handled by videodev2.c
-diff -Naur backports-3.18.1-1.org/include/media/v4l2-device.h backports-3.18.1-1/include/media/v4l2-device.h
---- backports-3.18.1-1.org/include/media/v4l2-device.h 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/include/media/v4l2-device.h 2014-12-28 14:10:09.716889709 +0100
-@@ -95,7 +95,7 @@
+diff -Naur backports-4.2.6-1.org/include/media/v4l2-device.h backports-4.2.6-1/include/media/v4l2-device.h
+--- backports-4.2.6-1.org/include/media/v4l2-device.h 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/include/media/v4l2-device.h 2016-01-27 12:26:31.219959057 +0100
+@@ -93,7 +93,7 @@
this function returns 0. If the name ends with a digit (e.g. cx18),
then the name will be set to cx18-0 since cx180 looks really odd. */
int v4l2_device_set_name(struct v4l2_device *v4l2_dev, const char *basename,
/* Set v4l2_dev->dev to NULL. Call when the USB parent disconnects.
Since the parent disappears this ensures that v4l2_dev doesn't have an
-diff -Naur backports-3.18.1-1.org/include/net/bluetooth/l2cap.h backports-3.18.1-1/include/net/bluetooth/l2cap.h
---- backports-3.18.1-1.org/include/net/bluetooth/l2cap.h 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/include/net/bluetooth/l2cap.h 2014-12-28 14:10:09.716889709 +0100
-@@ -608,7 +608,7 @@
- unsigned char *kdata,
+diff -Naur backports-4.2.6-1.org/include/net/bluetooth/l2cap.h backports-4.2.6-1/include/net/bluetooth/l2cap.h
+--- backports-4.2.6-1.org/include/net/bluetooth/l2cap.h 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/include/net/bluetooth/l2cap.h 2016-01-27 12:31:52.866600109 +0100
+@@ -615,7 +615,7 @@
struct iovec *iov,
int len);
+ #endif
-};
+} __do_const;
struct l2cap_conn {
struct hci_conn *hcon;
-diff -Naur backports-3.18.1-1.org/include/net/mac80211.h backports-3.18.1-1/include/net/mac80211.h
---- backports-3.18.1-1.org/include/net/mac80211.h 2014-12-21 22:37:13.000000000 +0100
-+++ backports-3.18.1-1/include/net/mac80211.h 2014-12-28 14:10:09.724889743 +0100
-@@ -4648,7 +4648,7 @@
+diff -Naur backports-4.2.6-1.org/include/net/mac80211.h backports-4.2.6-1/include/net/mac80211.h
+--- backports-4.2.6-1.org/include/net/mac80211.h 2015-11-15 22:19:38.000000000 +0100
++++ backports-4.2.6-1/include/net/mac80211.h 2016-01-27 12:26:31.223292389 +0100
+@@ -5106,7 +5106,7 @@
+ struct sk_buff *skb;
+ struct ieee80211_tx_rate reported_rate;
+ bool rts, short_preamble;
+- u8 max_rate_idx;
++ s8 max_rate_idx;
+ u32 rate_idx_mask;
+ u8 *rate_idx_mcs_mask;
+ bool bss;
+@@ -5143,7 +5143,7 @@
void (*remove_sta_debugfs)(void *priv, void *priv_sta);
u32 (*get_expected_throughput)(void *priv_sta);
static inline int rate_supported(struct ieee80211_sta *sta,
enum ieee80211_band band,
-diff -Naur backports-3.18.1-1.org/include/trace/events/fs.h backports-3.18.1-1/include/trace/events/fs.h
---- backports-3.18.1-1.org/include/trace/events/fs.h 1970-01-01 01:00:00.000000000 +0100
-+++ backports-3.18.1-1/include/trace/events/fs.h 2014-12-28 14:10:09.728889769 +0100
+diff -Naur backports-4.2.6-1.org/include/trace/events/fs.h backports-4.2.6-1/include/trace/events/fs.h
+--- backports-4.2.6-1.org/include/trace/events/fs.h 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/include/trace/events/fs.h 2016-01-27 12:26:31.226625722 +0100
@@ -0,0 +1,53 @@
+#undef TRACE_SYSTEM
+#define TRACE_SYSTEM fs
+
+/* This part must be outside protection */
+#include <trace/define_trace.h>
-diff -Naur backports-3.18.1-1.org/net/bluetooth/6lowpan.c backports-3.18.1-1/net/bluetooth/6lowpan.c
---- backports-3.18.1-1.org/net/bluetooth/6lowpan.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/bluetooth/6lowpan.c 2014-12-28 14:10:09.784890034 +0100
-@@ -367,7 +367,6 @@
-
- drop:
- dev->stats.rx_dropped++;
-- kfree_skb(skb);
- return NET_RX_DROP;
- }
-
-diff -Naur backports-3.18.1-1.org/net/bluetooth/bnep/core.c backports-3.18.1-1/net/bluetooth/bnep/core.c
---- backports-3.18.1-1.org/net/bluetooth/bnep/core.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/bluetooth/bnep/core.c 2014-12-28 14:10:09.784890034 +0100
-@@ -533,6 +533,9 @@
-
- BT_DBG("");
-
-+ if (!l2cap_is_socket(sock))
-+ return -EBADFD;
-+
- baswap((void *) dst, &l2cap_pi(sock->sk)->chan->dst);
- baswap((void *) src, &l2cap_pi(sock->sk)->chan->src);
-
-diff -Naur backports-3.18.1-1.org/net/bluetooth/cmtp/core.c backports-3.18.1-1/net/bluetooth/cmtp/core.c
---- backports-3.18.1-1.org/net/bluetooth/cmtp/core.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/bluetooth/cmtp/core.c 2014-12-28 14:10:09.784890034 +0100
-@@ -334,6 +334,9 @@
-
- BT_DBG("");
-
-+ if (!l2cap_is_socket(sock))
-+ return -EBADFD;
-+
- session = kzalloc(sizeof(struct cmtp_session), GFP_KERNEL);
- if (!session)
- return -ENOMEM;
-diff -Naur backports-3.18.1-1.org/net/bluetooth/hci_sock.c backports-3.18.1-1/net/bluetooth/hci_sock.c
---- backports-3.18.1-1.org/net/bluetooth/hci_sock.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/bluetooth/hci_sock.c 2014-12-28 14:10:09.784890034 +0100
-@@ -1067,7 +1067,7 @@
+diff -Naur backports-4.2.6-1.org/net/bluetooth/hci_sock.c backports-4.2.6-1/net/bluetooth/hci_sock.c
+--- backports-4.2.6-1.org/net/bluetooth/hci_sock.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/bluetooth/hci_sock.c 2016-01-27 12:26:36.269958751 +0100
+@@ -1266,7 +1266,7 @@
uf.event_mask[1] = *((u32 *) f->event_mask + 1);
}
if (copy_from_user(&uf, optval, len)) {
err = -EFAULT;
break;
-diff -Naur backports-3.18.1-1.org/net/bluetooth/hidp/core.c backports-3.18.1-1/net/bluetooth/hidp/core.c
---- backports-3.18.1-1.org/net/bluetooth/hidp/core.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/bluetooth/hidp/core.c 2014-12-28 14:10:09.784890034 +0100
-@@ -1322,13 +1322,14 @@
- {
- struct hidp_session *session;
- struct l2cap_conn *conn;
-- struct l2cap_chan *chan = l2cap_pi(ctrl_sock->sk)->chan;
-+ struct l2cap_chan *chan;
- int ret;
-
- ret = hidp_verify_sockets(ctrl_sock, intr_sock);
- if (ret)
- return ret;
-
-+ chan = l2cap_pi(ctrl_sock->sk)->chan;
- conn = NULL;
- l2cap_chan_lock(chan);
- if (chan->conn)
-diff -Naur backports-3.18.1-1.org/net/bluetooth/l2cap_core.c backports-3.18.1-1/net/bluetooth/l2cap_core.c
---- backports-3.18.1-1.org/net/bluetooth/l2cap_core.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/bluetooth/l2cap_core.c 2014-12-28 14:10:09.784890034 +0100
-@@ -3512,8 +3512,10 @@
+diff -Naur backports-4.2.6-1.org/net/bluetooth/l2cap_core.c backports-4.2.6-1/net/bluetooth/l2cap_core.c
+--- backports-4.2.6-1.org/net/bluetooth/l2cap_core.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/bluetooth/l2cap_core.c 2016-01-27 12:26:36.269958751 +0100
+@@ -3547,8 +3547,10 @@
break;
case L2CAP_CONF_RFC:
if (test_bit(CONF_STATE2_DEVICE, &chan->conf_state) &&
rfc.mode != chan->mode)
-diff -Naur backports-3.18.1-1.org/net/bluetooth/l2cap_sock.c backports-3.18.1-1/net/bluetooth/l2cap_sock.c
---- backports-3.18.1-1.org/net/bluetooth/l2cap_sock.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/bluetooth/l2cap_sock.c 2014-12-28 14:10:09.788890064 +0100
-@@ -628,7 +628,8 @@
+diff -Naur backports-4.2.6-1.org/net/bluetooth/l2cap_sock.c backports-4.2.6-1/net/bluetooth/l2cap_sock.c
+--- backports-4.2.6-1.org/net/bluetooth/l2cap_sock.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/bluetooth/l2cap_sock.c 2016-01-27 12:26:36.269958751 +0100
+@@ -633,7 +633,8 @@
struct sock *sk = sock->sk;
struct l2cap_chan *chan = l2cap_pi(sk)->chan;
struct l2cap_options opts;
u32 opt;
BT_DBG("sk %p", sk);
-@@ -655,7 +656,7 @@
+@@ -660,7 +661,7 @@
opts.max_tx = chan->max_tx;
opts.txwin_size = chan->tx_win;
if (copy_from_user((char *) &opts, optval, len)) {
err = -EFAULT;
break;
-@@ -742,7 +743,8 @@
+@@ -747,7 +748,8 @@
struct bt_security sec;
struct bt_power pwr;
struct l2cap_conn *conn;
u32 opt;
BT_DBG("sk %p", sk);
-@@ -766,7 +768,7 @@
+@@ -771,7 +773,7 @@
sec.level = BT_SECURITY_LOW;
if (copy_from_user((char *) &sec, optval, len)) {
err = -EFAULT;
break;
-@@ -862,7 +864,7 @@
+@@ -867,7 +869,7 @@
pwr.force_active = BT_POWER_FORCE_ACTIVE_ON;
if (copy_from_user((char *) &pwr, optval, len)) {
err = -EFAULT;
break;
-diff -Naur backports-3.18.1-1.org/net/bluetooth/rfcomm/sock.c backports-3.18.1-1/net/bluetooth/rfcomm/sock.c
---- backports-3.18.1-1.org/net/bluetooth/rfcomm/sock.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/bluetooth/rfcomm/sock.c 2014-12-28 14:10:09.788890064 +0100
-@@ -695,7 +695,7 @@
+diff -Naur backports-4.2.6-1.org/net/bluetooth/rfcomm/sock.c backports-4.2.6-1/net/bluetooth/rfcomm/sock.c
+--- backports-4.2.6-1.org/net/bluetooth/rfcomm/sock.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/bluetooth/rfcomm/sock.c 2016-01-27 12:26:36.269958751 +0100
+@@ -713,7 +713,7 @@
struct sock *sk = sock->sk;
struct bt_security sec;
int err = 0;
u32 opt;
BT_DBG("sk %p", sk);
-@@ -717,7 +717,7 @@
+@@ -735,7 +735,7 @@
sec.level = BT_SECURITY_LOW;
if (copy_from_user((char *) &sec, optval, len)) {
err = -EFAULT;
break;
-diff -Naur backports-3.18.1-1.org/net/bluetooth/rfcomm/tty.c backports-3.18.1-1/net/bluetooth/rfcomm/tty.c
---- backports-3.18.1-1.org/net/bluetooth/rfcomm/tty.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/bluetooth/rfcomm/tty.c 2014-12-28 14:10:09.788890064 +0100
+diff -Naur backports-4.2.6-1.org/net/bluetooth/rfcomm/tty.c backports-4.2.6-1/net/bluetooth/rfcomm/tty.c
+--- backports-4.2.6-1.org/net/bluetooth/rfcomm/tty.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/bluetooth/rfcomm/tty.c 2016-01-27 12:26:36.269958751 +0100
@@ -752,7 +752,7 @@
BT_DBG("tty %p id %d", tty, tty->index);
tty_port_close(&dev->port, tty, filp);
}
-diff -Naur backports-3.18.1-1.org/net/ieee802154/6lowpan_rtnl.c backports-3.18.1-1/net/ieee802154/6lowpan_rtnl.c
---- backports-3.18.1-1.org/net/ieee802154/6lowpan_rtnl.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/ieee802154/6lowpan_rtnl.c 2014-12-28 14:10:09.796890100 +0100
-@@ -639,7 +639,7 @@
+diff -Naur backports-4.2.6-1.org/net/ieee802154/6lowpan/core.c backports-4.2.6-1/net/ieee802154/6lowpan/core.c
+--- backports-4.2.6-1.org/net/ieee802154/6lowpan/core.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/ieee802154/6lowpan/core.c 2016-01-27 12:26:36.273292083 +0100
+@@ -191,7 +191,7 @@
dev_put(real_dev);
}
.kind = "lowpan",
.priv_size = sizeof(struct lowpan_dev_info),
.setup = lowpan_setup,
-diff -Naur backports-3.18.1-1.org/net/ieee802154/reassembly.c backports-3.18.1-1/net/ieee802154/reassembly.c
---- backports-3.18.1-1.org/net/ieee802154/reassembly.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/ieee802154/reassembly.c 2014-12-28 14:10:09.796890100 +0100
-@@ -460,14 +460,13 @@
+diff -Naur backports-4.2.6-1.org/net/ieee802154/6lowpan/reassembly.c backports-4.2.6-1/net/ieee802154/6lowpan/reassembly.c
+--- backports-4.2.6-1.org/net/ieee802154/6lowpan/reassembly.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/ieee802154/6lowpan/reassembly.c 2016-01-27 12:26:36.273292083 +0100
+@@ -435,14 +435,13 @@
static int __net_init lowpan_frags_ns_sysctl_register(struct net *net)
{
GFP_KERNEL);
if (table == NULL)
goto err_alloc;
-@@ -494,8 +493,7 @@
+@@ -457,9 +456,9 @@
+ /* Don't export sysctls to unprivileged users */
+ if (net->user_ns != &init_user_ns)
+ table[0].procname = NULL;
+- }
+-
+- hdr = register_net_sysctl(net, "net/ieee802154/6lowpan", table);
++ hdr = register_net_sysctl(net, "net/ieee802154/6lowpan", table);
++ } else
++ hdr = register_net_sysctl(net, "net/ieee802154/6lowpan", lowpan_frags_ns_ctl_table);
+ if (hdr == NULL)
+ goto err_reg;
+
+@@ -467,8 +466,7 @@
return 0;
err_reg:
err_alloc:
return -ENOMEM;
}
-diff -Naur backports-3.18.1-1.org/net/mac80211/cfg.c backports-3.18.1-1/net/mac80211/cfg.c
---- backports-3.18.1-1.org/net/mac80211/cfg.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/mac80211/cfg.c 2014-12-28 14:10:09.812890175 +0100
-@@ -541,7 +541,7 @@
+diff -Naur backports-4.2.6-1.org/net/mac80211/cfg.c backports-4.2.6-1/net/mac80211/cfg.c
+--- backports-4.2.6-1.org/net/mac80211/cfg.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/mac80211/cfg.c 2016-01-27 12:26:36.286625417 +0100
+@@ -580,7 +580,7 @@
ret = ieee80211_vif_use_channel(sdata, chandef,
IEEE80211_CHANCTX_EXCLUSIVE);
}
local->_oper_chandef = *chandef;
ieee80211_hw_config(local, 0);
}
-@@ -3326,7 +3326,7 @@
+@@ -3488,7 +3488,7 @@
else
local->probe_req_reg--;
break;
ieee80211_queue_work(&local->hw, &local->reconfig_filter);
-@@ -3460,8 +3460,8 @@
+@@ -3637,8 +3637,8 @@
if (chanctx_conf) {
*chandef = sdata->vif.bss_conf.chandef;
ret = 0;
sdata->vif.type == NL80211_IFTYPE_MONITOR) {
if (local->use_chanctx)
*chandef = local->monitor_chandef;
-diff -Naur backports-3.18.1-1.org/net/mac80211/ieee80211_i.h backports-3.18.1-1/net/mac80211/ieee80211_i.h
---- backports-3.18.1-1.org/net/mac80211/ieee80211_i.h 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/mac80211/ieee80211_i.h 2014-12-28 14:10:09.812890175 +0100
-@@ -29,6 +29,7 @@
+diff -Naur backports-4.2.6-1.org/net/mac80211/ieee80211_i.h backports-4.2.6-1/net/mac80211/ieee80211_i.h
+--- backports-4.2.6-1.org/net/mac80211/ieee80211_i.h 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/mac80211/ieee80211_i.h 2016-01-27 12:26:36.289958749 +0100
+@@ -30,6 +30,7 @@
#include <net/ieee80211_radiotap.h>
#include <net/cfg80211.h>
#include <net/mac80211.h>
#include "key.h"
#include "sta_info.h"
#include "debug.h"
-@@ -1057,7 +1058,7 @@
+@@ -1112,7 +1113,7 @@
/* also used to protect ampdu_ac_queue and amdpu_ac_stop_refcnt */
spinlock_t queue_stop_reason_lock;
int monitors, cooked_mntrs;
/* number of interfaces with corresponding FIF_ flags */
int fif_fcsfail, fif_plcpfail, fif_control, fif_other_bss, fif_pspoll,
-diff -Naur backports-3.18.1-1.org/net/mac80211/iface.c backports-3.18.1-1/net/mac80211/iface.c
---- backports-3.18.1-1.org/net/mac80211/iface.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/mac80211/iface.c 2014-12-28 14:10:09.812890175 +0100
-@@ -532,7 +532,7 @@
+diff -Naur backports-4.2.6-1.org/net/mac80211/iface.c backports-4.2.6-1/net/mac80211/iface.c
+--- backports-4.2.6-1.org/net/mac80211/iface.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/mac80211/iface.c 2016-01-27 12:26:36.289958749 +0100
+@@ -550,7 +550,7 @@
break;
}
res = drv_start(local);
if (res)
goto err_del_bss;
-@@ -579,7 +579,7 @@
+@@ -597,7 +597,7 @@
res = drv_add_interface(local, sdata);
if (res)
goto err_stop;
res = ieee80211_add_virtual_monitor(local);
if (res)
goto err_stop;
-@@ -688,7 +688,7 @@
- atomic_inc(&local->iff_promiscs);
+@@ -704,7 +704,7 @@
+ atomic_inc(&local->iff_allmultis);
if (coming_up)
- local->open_count++;
if (hw_reconf_flags)
ieee80211_hw_config(local, hw_reconf_flags);
-@@ -726,7 +726,7 @@
+@@ -742,7 +742,7 @@
err_del_interface:
drv_remove_interface(local, sdata);
err_stop:
drv_stop(local);
err_del_bss:
sdata->bss = NULL;
-@@ -892,7 +892,7 @@
+@@ -909,7 +909,7 @@
}
if (going_down)
switch (sdata->vif.type) {
case NL80211_IFTYPE_AP_VLAN:
-@@ -954,7 +954,7 @@
+@@ -978,7 +978,7 @@
+ atomic_set(&sdata->txqs_len[txqi->txq.ac], 0);
}
- spin_unlock_irqrestore(&local->queue_stop_reason_lock, flags);
- if (local->open_count == 0)
+ if (local_read(&local->open_count) == 0)
ieee80211_clear_tx_pending(local);
/*
-@@ -997,7 +997,7 @@
+@@ -1021,7 +1021,7 @@
if (cancel_scan)
flush_delayed_work(&local->scan_work);
ieee80211_stop_device(local);
/* no reconfiguring after stop! */
-@@ -1008,7 +1008,7 @@
+@@ -1032,7 +1032,7 @@
ieee80211_configure_filter(local);
ieee80211_hw_config(local, hw_reconf_flags);
ieee80211_add_virtual_monitor(local);
}
-diff -Naur backports-3.18.1-1.org/net/mac80211/main.c backports-3.18.1-1/net/mac80211/main.c
---- backports-3.18.1-1.org/net/mac80211/main.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/mac80211/main.c 2014-12-28 14:10:09.812890175 +0100
-@@ -175,7 +175,7 @@
+@@ -1905,8 +1905,8 @@
+ */
+ cfg80211_shutdown_all_interfaces(local->hw.wiphy);
+
+- WARN(local->open_count, "%s: open count remains %d\n",
+- wiphy_name(local->hw.wiphy), local->open_count);
++ WARN(local_read(&local->open_count), "%s: open count remains %ld\n",
++ wiphy_name(local->hw.wiphy), local_read(&local->open_count));
+
+ mutex_lock(&local->iflist_mtx);
+ list_for_each_entry_safe(sdata, tmp, &local->interfaces, list) {
+diff -Naur backports-4.2.6-1.org/net/mac80211/main.c backports-4.2.6-1/net/mac80211/main.c
+--- backports-4.2.6-1.org/net/mac80211/main.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/mac80211/main.c 2016-01-27 12:26:36.289958749 +0100
+@@ -172,7 +172,7 @@
changed &= ~(IEEE80211_CONF_CHANGE_CHANNEL |
IEEE80211_CONF_CHANGE_POWER);
ret = drv_config(local, changed);
/*
* Goal:
-diff -Naur backports-3.18.1-1.org/net/mac80211/pm.c backports-3.18.1-1/net/mac80211/pm.c
---- backports-3.18.1-1.org/net/mac80211/pm.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/mac80211/pm.c 2014-12-28 14:10:09.812890175 +0100
+diff -Naur backports-4.2.6-1.org/net/mac80211/pm.c backports-4.2.6-1/net/mac80211/pm.c
+--- backports-4.2.6-1.org/net/mac80211/pm.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/mac80211/pm.c 2016-01-27 12:26:36.289958749 +0100
@@ -12,7 +12,7 @@
struct ieee80211_sub_if_data *sdata;
struct sta_info *sta;
goto suspend;
ieee80211_scan_cancel(local);
-@@ -59,7 +59,7 @@
- cancel_work_sync(&local->dynamic_ps_enable_work);
- del_timer_sync(&local->dynamic_ps_timer);
-
-- local->wowlan = wowlan && local->open_count;
-+ local->wowlan = wowlan && local_read(&local->open_count);
- if (local->wowlan) {
- int err = drv_suspend(local, wowlan);
- if (err < 0) {
-@@ -125,7 +125,7 @@
+@@ -166,7 +166,7 @@
WARN_ON(!list_empty(&local->chanctx_list));
/* stop hardware - this must stop RX */
ieee80211_stop_device(local);
suspend:
-diff -Naur backports-3.18.1-1.org/net/mac80211/rate.c backports-3.18.1-1/net/mac80211/rate.c
---- backports-3.18.1-1.org/net/mac80211/rate.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/mac80211/rate.c 2014-12-28 14:10:09.812890175 +0100
-@@ -720,7 +720,7 @@
+diff -Naur backports-4.2.6-1.org/net/mac80211/rate.c backports-4.2.6-1/net/mac80211/rate.c
+--- backports-4.2.6-1.org/net/mac80211/rate.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/mac80211/rate.c 2016-01-27 12:26:36.289958749 +0100
+@@ -730,7 +730,7 @@
ASSERT_RTNL();
+ if (local_read(&local->open_count))
return -EBUSY;
- if (local->hw.flags & IEEE80211_HW_HAS_RATE_CONTROL) {
-diff -Naur backports-3.18.1-1.org/net/mac80211/util.c backports-3.18.1-1/net/mac80211/util.c
---- backports-3.18.1-1.org/net/mac80211/util.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/mac80211/util.c 2014-12-28 14:10:09.816890209 +0100
-@@ -1669,7 +1669,7 @@
- }
- #endif
- /* everything else happens only if HW was up & running */
+ if (ieee80211_hw_check(&local->hw, HAS_RATE_CONTROL)) {
+diff -Naur backports-4.2.6-1.org/net/mac80211/sta_info.c backports-4.2.6-1/net/mac80211/sta_info.c
+--- backports-4.2.6-1.org/net/mac80211/sta_info.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/mac80211/sta_info.c 2016-01-27 12:26:36.289958749 +0100
+@@ -341,7 +341,7 @@
+ int size = sizeof(struct txq_info) +
+ ALIGN(hw->txq_data_size, sizeof(void *));
+
+- txq_data = kcalloc(ARRAY_SIZE(sta->sta.txq), size, gfp);
++ txq_data = kcalloc(size, ARRAY_SIZE(sta->sta.txq), gfp);
+ if (!txq_data)
+ goto free;
+
+diff -Naur backports-4.2.6-1.org/net/mac80211/util.c backports-4.2.6-1/net/mac80211/util.c
+--- backports-4.2.6-1.org/net/mac80211/util.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/mac80211/util.c 2016-01-27 12:26:36.289958749 +0100
+@@ -1761,7 +1761,7 @@
+ bool sched_scan_stopped = false;
+
+ /* nothing to do if HW shouldn't run */
- if (!local->open_count)
+ if (!local_read(&local->open_count))
goto wake_up;
- /*
-@@ -1895,7 +1895,7 @@
+ #ifdef CONFIG_PM
+@@ -2033,7 +2033,7 @@
local->in_reconfig = false;
barrier();
ieee80211_add_virtual_monitor(local);
/*
-diff -Naur backports-3.18.1-1.org/net/wireless/wext-core.c backports-3.18.1-1/net/wireless/wext-core.c
---- backports-3.18.1-1.org/net/wireless/wext-core.c 2014-12-21 22:37:15.000000000 +0100
-+++ backports-3.18.1-1/net/wireless/wext-core.c 2014-12-28 14:10:09.832890290 +0100
+@@ -2088,7 +2088,7 @@
+ * If this is for hw restart things are still running.
+ * We may want to change that later, however.
+ */
+- if (local->open_count && (!local->suspended || reconfig_due_to_wowlan))
++ if (local_read(&local->open_count) && (!local->suspended || reconfig_due_to_wowlan))
+ drv_reconfig_complete(local, IEEE80211_RECONFIG_TYPE_RESTART);
+
+ if (!local->suspended)
+@@ -2112,7 +2112,7 @@
+ flush_delayed_work(&local->scan_work);
+ }
+
+- if (local->open_count && !reconfig_due_to_wowlan)
++ if (local_read(&local->open_count) && !reconfig_due_to_wowlan)
+ drv_reconfig_complete(local, IEEE80211_RECONFIG_TYPE_SUSPEND);
+
+ list_for_each_entry(sdata, &local->interfaces, list) {
+diff -Naur backports-4.2.6-1.org/net/wireless/wext-core.c backports-4.2.6-1/net/wireless/wext-core.c
+--- backports-4.2.6-1.org/net/wireless/wext-core.c 2015-11-15 22:19:40.000000000 +0100
++++ backports-4.2.6-1/net/wireless/wext-core.c 2016-01-27 12:26:36.303292082 +0100
@@ -748,8 +748,7 @@
*/
err = handler(dev, info, (union iwreq_data *) iwp, extra);
iwp->length += essid_compat;
+diff -Naur backports-4.2.6-1.org/scripts/gcc-plugin.sh backports-4.2.6-1/scripts/gcc-plugin.sh
+--- backports-4.2.6-1.org/scripts/gcc-plugin.sh 1970-01-01 01:00:00.000000000 +0100
++++ backports-4.2.6-1/scripts/gcc-plugin.sh 2016-01-27 12:26:36.303292082 +0100
+@@ -0,0 +1,51 @@
++#!/bin/sh
++srctree=$(dirname "$0")
++gccplugins_dir=$($3 -print-file-name=plugin)
++plugincc=$($1 -E -x c++ - -o /dev/null -I"${srctree}"/../tools/gcc -I"${gccplugins_dir}"/include 2>&1 <<EOF
++#include "gcc-common.h"
++#if BUILDING_GCC_VERSION >= 4008 || defined(ENABLE_BUILD_WITH_CXX)
++#warning $2 CXX
++#else
++#warning $1 CC
++#endif
++EOF
++)
++
++if [ $? -ne 0 ]
++then
++ exit 1
++fi
++
++case "$plugincc" in
++ *"$1 CC"*)
++ echo "$1"
++ exit 0
++ ;;
++
++ *"$2 CXX"*)
++ # the c++ compiler needs another test, see below
++ ;;
++
++ *)
++ exit 1
++ ;;
++esac
++
++# we need a c++ compiler that supports the designated initializer GNU extension
++plugincc=$($2 -c -x c++ -std=gnu++98 - -fsyntax-only -I"${srctree}"/../tools/gcc -I"${gccplugins_dir}"/include 2>&1 <<EOF
++#include "gcc-common.h"
++class test {
++public:
++ int test;
++} test = {
++ .test = 1
++};
++EOF
++)
++
++if [ $? -eq 0 ]
++then
++ echo "$2"
++ exit 0
++fi
++exit 1
--- /dev/null
+From bed429e1ae8b7ee207e01f3aa60dcc0d06a8ed4d Mon Sep 17 00:00:00 2001
+From: Jakub Kicinski <kubakici@wp.pl>
+Date: Fri, 31 Jul 2015 15:04:46 +0200
+Subject: mt7601u: fix dma from stack address
+
+DMA to variables located on the stack is a bad idea.
+For simplicity and to avoid frequent allocations create
+a buffer inside the device structure. Protect this
+buffer with vendor_req_mutex. Don't protect vendor
+requests which don't use this buffer.
+
+Signed-off-by: Jakub Kicinski <kubakici@wp.pl>
+Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
+---
+ drivers/net/wireless/mediatek/mt7601u/mt7601u.h | 4 +-
+ drivers/net/wireless/mediatek/mt7601u/usb.c | 63 ++++++++++++-------------
+ drivers/net/wireless/mediatek/mt7601u/usb.h | 2 +
+ 3 files changed, 34 insertions(+), 35 deletions(-)
+
+diff --git a/drivers/net/wireless/mediatek/mt7601u/mt7601u.h b/drivers/net/wireless/mediatek/mt7601u/mt7601u.h
+index 9102be6b..6bdfc11 100644
+--- a/drivers/net/wireless/mediatek/mt7601u/mt7601u.h
++++ b/drivers/net/wireless/mediatek/mt7601u/mt7601u.h
+@@ -146,7 +146,7 @@ enum {
+ * @rx_lock: protects @rx_q.
+ * @con_mon_lock: protects @ap_bssid, @bcn_*, @avg_rssi.
+ * @mutex: ensures exclusive access from mac80211 callbacks.
+- * @vendor_req_mutex: ensures atomicity of vendor requests.
++ * @vendor_req_mutex: protects @vend_buf, ensures atomicity of split writes.
+ * @reg_atomic_mutex: ensures atomicity of indirect register accesses
+ * (accesses to RF and BBP).
+ * @hw_atomic_mutex: ensures exclusive access to HW during critical
+@@ -184,6 +184,8 @@ struct mt7601u_dev {
+ struct mt7601u_eeprom_params *ee;
+
+ struct mutex vendor_req_mutex;
++ void *vend_buf;
++
+ struct mutex reg_atomic_mutex;
+ struct mutex hw_atomic_mutex;
+
+diff --git a/drivers/net/wireless/mediatek/mt7601u/usb.c b/drivers/net/wireless/mediatek/mt7601u/usb.c
+index 54dba40..416c604 100644
+--- a/drivers/net/wireless/mediatek/mt7601u/usb.c
++++ b/drivers/net/wireless/mediatek/mt7601u/usb.c
+@@ -92,10 +92,9 @@ void mt7601u_complete_urb(struct urb *urb)
+ complete(cmpl);
+ }
+
+-static int
+-__mt7601u_vendor_request(struct mt7601u_dev *dev, const u8 req,
+- const u8 direction, const u16 val, const u16 offset,
+- void *buf, const size_t buflen)
++int mt7601u_vendor_request(struct mt7601u_dev *dev, const u8 req,
++ const u8 direction, const u16 val, const u16 offset,
++ void *buf, const size_t buflen)
+ {
+ int i, ret;
+ struct usb_device *usb_dev = mt7601u_to_usb_dev(dev);
+@@ -110,6 +109,8 @@ __mt7601u_vendor_request(struct mt7601u_dev *dev, const u8 req,
+ trace_mt_vend_req(dev, pipe, req, req_type, val, offset,
+ buf, buflen, ret);
+
++ if (ret == -ENODEV)
++ set_bit(MT7601U_STATE_REMOVED, &dev->state);
+ if (ret >= 0 || ret == -ENODEV)
+ return ret;
+
+@@ -122,25 +123,6 @@ __mt7601u_vendor_request(struct mt7601u_dev *dev, const u8 req,
+ return ret;
+ }
+
+-int
+-mt7601u_vendor_request(struct mt7601u_dev *dev, const u8 req,
+- const u8 direction, const u16 val, const u16 offset,
+- void *buf, const size_t buflen)
+-{
+- int ret;
+-
+- mutex_lock(&dev->vendor_req_mutex);
+-
+- ret = __mt7601u_vendor_request(dev, req, direction, val, offset,
+- buf, buflen);
+- if (ret == -ENODEV)
+- set_bit(MT7601U_STATE_REMOVED, &dev->state);
+-
+- mutex_unlock(&dev->vendor_req_mutex);
+-
+- return ret;
+-}
+-
+ void mt7601u_vendor_reset(struct mt7601u_dev *dev)
+ {
+ mt7601u_vendor_request(dev, MT_VEND_DEV_MODE, USB_DIR_OUT,
+@@ -150,19 +132,21 @@ void mt7601u_vendor_reset(struct mt7601u_dev *dev)
+ u32 mt7601u_rr(struct mt7601u_dev *dev, u32 offset)
+ {
+ int ret;
+- __le32 reg;
+- u32 val;
++ u32 val = ~0;
+
+ WARN_ONCE(offset > USHRT_MAX, "read high off:%08x", offset);
+
++ mutex_lock(&dev->vendor_req_mutex);
++
+ ret = mt7601u_vendor_request(dev, MT_VEND_MULTI_READ, USB_DIR_IN,
+- 0, offset, ®, sizeof(reg));
+- val = le32_to_cpu(reg);
+- if (ret > 0 && ret != sizeof(reg)) {
++ 0, offset, dev->vend_buf, MT_VEND_BUF);
++ if (ret == MT_VEND_BUF)
++ val = get_unaligned_le32(dev->vend_buf);
++ else if (ret > 0)
+ dev_err(dev->dev, "Error: wrong size read:%d off:%08x\n",
+ ret, offset);
+- val = ~0;
+- }
++
++ mutex_unlock(&dev->vendor_req_mutex);
+
+ trace_reg_read(dev, offset, val);
+ return val;
+@@ -173,12 +157,17 @@ int mt7601u_vendor_single_wr(struct mt7601u_dev *dev, const u8 req,
+ {
+ int ret;
+
++ mutex_lock(&dev->vendor_req_mutex);
++
+ ret = mt7601u_vendor_request(dev, req, USB_DIR_OUT,
+ val & 0xffff, offset, NULL, 0);
+- if (ret)
+- return ret;
+- return mt7601u_vendor_request(dev, req, USB_DIR_OUT,
+- val >> 16, offset + 2, NULL, 0);
++ if (!ret)
++ ret = mt7601u_vendor_request(dev, req, USB_DIR_OUT,
++ val >> 16, offset + 2, NULL, 0);
++
++ mutex_unlock(&dev->vendor_req_mutex);
++
++ return ret;
+ }
+
+ void mt7601u_wr(struct mt7601u_dev *dev, u32 offset, u32 val)
+@@ -275,6 +264,12 @@ static int mt7601u_probe(struct usb_interface *usb_intf,
+
+ usb_set_intfdata(usb_intf, dev);
+
++ dev->vend_buf = devm_kmalloc(dev->dev, MT_VEND_BUF, GFP_KERNEL);
++ if (!dev->vend_buf) {
++ ret = -ENOMEM;
++ goto err;
++ }
++
+ ret = mt7601u_assign_pipes(usb_intf, dev);
+ if (ret)
+ goto err;
+diff --git a/drivers/net/wireless/mediatek/mt7601u/usb.h b/drivers/net/wireless/mediatek/mt7601u/usb.h
+index 49e188f..bc18202 100644
+--- a/drivers/net/wireless/mediatek/mt7601u/usb.h
++++ b/drivers/net/wireless/mediatek/mt7601u/usb.h
+@@ -23,6 +23,8 @@
+
+ #define MT_VEND_DEV_MODE_RESET 1
+
++#define MT_VEND_BUF sizeof(__le32)
++
+ enum mt_vendor_req {
+ MT_VEND_DEV_MODE = 1,
+ MT_VEND_WRITE = 2,
+--
+cgit v0.12
+
+From d9517c0a5d7468a7ea63086057604fcb0fff480e Mon Sep 17 00:00:00 2001
+From: Jakub Kicinski <kubakici@wp.pl>
+Date: Fri, 31 Jul 2015 15:04:47 +0200
+Subject: mt7601u: use correct ieee80211_rx variant
+
+Rx is run inside a tasklet so ieee80211_rx() should be used
+instead of ieee80211_rx_ni().
+
+Signed-off-by: Jakub Kicinski <kubakici@wp.pl>
+Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
+---
+ drivers/net/wireless/mediatek/mt7601u/dma.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/drivers/net/wireless/mediatek/mt7601u/dma.c b/drivers/net/wireless/mediatek/mt7601u/dma.c
+index 7217da4..fb183e3 100644
+--- a/drivers/net/wireless/mediatek/mt7601u/dma.c
++++ b/drivers/net/wireless/mediatek/mt7601u/dma.c
+@@ -112,7 +112,7 @@ static void mt7601u_rx_process_seg(struct mt7601u_dev *dev, u8 *data,
+ if (!skb)
+ return;
+
+- ieee80211_rx_ni(dev->hw, skb);
++ ieee80211_rx(dev->hw, skb);
+ }
+
+ static u16 mt7601u_rx_next_seg_len(u8 *data, u32 data_len)
+--
+cgit v0.12
+
+From 4513493d188d5e3052aee68eda85eaaa1a4e41c2 Mon Sep 17 00:00:00 2001
+From: Jakub Kicinski <kubakici@wp.pl>
+Date: Fri, 31 Jul 2015 15:04:48 +0200
+Subject: mt7601u: fix tx status reporting contexts
+
+mac80211 requires that rx path does not run concurrently with
+tx status reporting. Since rx path is run in driver tasklet,
+tx status cannot be reported directly from interrupt context
+(there would be no way to lock it out).
+
+Add tasklet for tx and move all possible code from irq handler
+there.
+
+Note: tx tasklet is needed because workqueue is queued very
+ rarely and that kills TCP performance.
+
+Signed-off-by: Jakub Kicinski <kubakici@wp.pl>
+Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
+---
+ drivers/net/wireless/mediatek/mt7601u/dma.c | 30 +++++++++++++++++++++----
+ drivers/net/wireless/mediatek/mt7601u/init.c | 1 +
+ drivers/net/wireless/mediatek/mt7601u/mac.c | 4 ++++
+ drivers/net/wireless/mediatek/mt7601u/mt7601u.h | 2 ++
+ 4 files changed, 33 insertions(+), 4 deletions(-)
+
+diff --git a/drivers/net/wireless/mediatek/mt7601u/dma.c b/drivers/net/wireless/mediatek/mt7601u/dma.c
+index fb183e3..63c4854 100644
+--- a/drivers/net/wireless/mediatek/mt7601u/dma.c
++++ b/drivers/net/wireless/mediatek/mt7601u/dma.c
+@@ -236,23 +236,42 @@ static void mt7601u_complete_tx(struct urb *urb)
+ skb = q->e[q->start].skb;
+ trace_mt_tx_dma_done(dev, skb);
+
+- mt7601u_tx_status(dev, skb);
++ __skb_queue_tail(&dev->tx_skb_done, skb);
++ tasklet_schedule(&dev->tx_tasklet);
+
+ if (q->used == q->entries - q->entries / 8)
+ ieee80211_wake_queue(dev->hw, skb_get_queue_mapping(skb));
+
+ q->start = (q->start + 1) % q->entries;
+ q->used--;
++out:
++ spin_unlock_irqrestore(&dev->tx_lock, flags);
++}
+
+- if (urb->status)
+- goto out;
++static void mt7601u_tx_tasklet(unsigned long data)
++{
++ struct mt7601u_dev *dev = (struct mt7601u_dev *) data;
++ struct sk_buff_head skbs;
++ unsigned long flags;
++
++ __skb_queue_head_init(&skbs);
++
++ spin_lock_irqsave(&dev->tx_lock, flags);
+
+ set_bit(MT7601U_STATE_MORE_STATS, &dev->state);
+ if (!test_and_set_bit(MT7601U_STATE_READING_STATS, &dev->state))
+ queue_delayed_work(dev->stat_wq, &dev->stat_work,
+ msecs_to_jiffies(10));
+-out:
++
++ skb_queue_splice_init(&dev->tx_skb_done, &skbs);
++
+ spin_unlock_irqrestore(&dev->tx_lock, flags);
++
++ while (!skb_queue_empty(&skbs)) {
++ struct sk_buff *skb = __skb_dequeue(&skbs);
++
++ mt7601u_tx_status(dev, skb);
++ }
+ }
+
+ static int mt7601u_dma_submit_tx(struct mt7601u_dev *dev,
+@@ -475,6 +494,7 @@ int mt7601u_dma_init(struct mt7601u_dev *dev)
+ {
+ int ret = -ENOMEM;
+
++ tasklet_init(&dev->tx_tasklet, mt7601u_tx_tasklet, (unsigned long) dev);
+ tasklet_init(&dev->rx_tasklet, mt7601u_rx_tasklet, (unsigned long) dev);
+
+ ret = mt7601u_alloc_tx(dev);
+@@ -502,4 +522,6 @@ void mt7601u_dma_cleanup(struct mt7601u_dev *dev)
+
+ mt7601u_free_rx(dev);
+ mt7601u_free_tx(dev);
++
++ tasklet_kill(&dev->tx_tasklet);
+ }
+diff --git a/drivers/net/wireless/mediatek/mt7601u/init.c b/drivers/net/wireless/mediatek/mt7601u/init.c
+index df3dd56..38eb20b 100644
+--- a/drivers/net/wireless/mediatek/mt7601u/init.c
++++ b/drivers/net/wireless/mediatek/mt7601u/init.c
+@@ -456,6 +456,7 @@ struct mt7601u_dev *mt7601u_alloc_device(struct device *pdev)
+ spin_lock_init(&dev->lock);
+ spin_lock_init(&dev->con_mon_lock);
+ atomic_set(&dev->avg_ampdu_len, 1);
++ skb_queue_head_init(&dev->tx_skb_done);
+
+ dev->stat_wq = alloc_workqueue("mt7601u", WQ_UNBOUND, 0);
+ if (!dev->stat_wq) {
+diff --git a/drivers/net/wireless/mediatek/mt7601u/mac.c b/drivers/net/wireless/mediatek/mt7601u/mac.c
+index 7514bce..e3928cf 100644
+--- a/drivers/net/wireless/mediatek/mt7601u/mac.c
++++ b/drivers/net/wireless/mediatek/mt7601u/mac.c
+@@ -181,7 +181,11 @@ void mt76_send_tx_status(struct mt7601u_dev *dev, struct mt76_tx_status *stat)
+ }
+
+ mt76_mac_fill_tx_status(dev, &info, stat);
++
++ local_bh_disable();
+ ieee80211_tx_status_noskb(dev->hw, sta, &info);
++ local_bh_enable();
++
+ rcu_read_unlock();
+ }
+
+diff --git a/drivers/net/wireless/mediatek/mt7601u/mt7601u.h b/drivers/net/wireless/mediatek/mt7601u/mt7601u.h
+index 6bdfc11..bc5e294 100644
+--- a/drivers/net/wireless/mediatek/mt7601u/mt7601u.h
++++ b/drivers/net/wireless/mediatek/mt7601u/mt7601u.h
+@@ -199,7 +199,9 @@ struct mt7601u_dev {
+
+ /* TX */
+ spinlock_t tx_lock;
++ struct tasklet_struct tx_tasklet;
+ struct mt7601u_tx_queue *tx_q;
++ struct sk_buff_head tx_skb_done;
+
+ atomic_t avg_ampdu_len;
+
+--
+cgit v0.12
+
+From 78623bfb6f4cbdba3183621e8e0e781611217022 Mon Sep 17 00:00:00 2001
+From: Jakub Kicinski <kubakici@wp.pl>
+Date: Fri, 31 Jul 2015 15:04:49 +0200
+Subject: mt7601u: lock out rx path and tx status reporting
+
+mac80211 requires that rx path does not run concurrently with
+tx status reporting. Add a spinlock which will ensure that.
+
+Signed-off-by: Jakub Kicinski <kubakici@wp.pl>
+Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
+---
+ drivers/net/wireless/mediatek/mt7601u/dma.c | 2 ++
+ drivers/net/wireless/mediatek/mt7601u/init.c | 1 +
+ drivers/net/wireless/mediatek/mt7601u/mac.c | 4 ++--
+ drivers/net/wireless/mediatek/mt7601u/mt7601u.h | 4 +++-
+ drivers/net/wireless/mediatek/mt7601u/tx.c | 3 +++
+ 5 files changed, 11 insertions(+), 3 deletions(-)
+
+diff --git a/drivers/net/wireless/mediatek/mt7601u/dma.c b/drivers/net/wireless/mediatek/mt7601u/dma.c
+index 63c4854..57a80cf 100644
+--- a/drivers/net/wireless/mediatek/mt7601u/dma.c
++++ b/drivers/net/wireless/mediatek/mt7601u/dma.c
+@@ -112,7 +112,9 @@ static void mt7601u_rx_process_seg(struct mt7601u_dev *dev, u8 *data,
+ if (!skb)
+ return;
+
++ spin_lock(&dev->mac_lock);
+ ieee80211_rx(dev->hw, skb);
++ spin_unlock(&dev->mac_lock);
+ }
+
+ static u16 mt7601u_rx_next_seg_len(u8 *data, u32 data_len)
+diff --git a/drivers/net/wireless/mediatek/mt7601u/init.c b/drivers/net/wireless/mediatek/mt7601u/init.c
+index 38eb20b..26190fd 100644
+--- a/drivers/net/wireless/mediatek/mt7601u/init.c
++++ b/drivers/net/wireless/mediatek/mt7601u/init.c
+@@ -454,6 +454,7 @@ struct mt7601u_dev *mt7601u_alloc_device(struct device *pdev)
+ spin_lock_init(&dev->tx_lock);
+ spin_lock_init(&dev->rx_lock);
+ spin_lock_init(&dev->lock);
++ spin_lock_init(&dev->mac_lock);
+ spin_lock_init(&dev->con_mon_lock);
+ atomic_set(&dev->avg_ampdu_len, 1);
+ skb_queue_head_init(&dev->tx_skb_done);
+diff --git a/drivers/net/wireless/mediatek/mt7601u/mac.c b/drivers/net/wireless/mediatek/mt7601u/mac.c
+index e3928cf..e21c53e 100644
+--- a/drivers/net/wireless/mediatek/mt7601u/mac.c
++++ b/drivers/net/wireless/mediatek/mt7601u/mac.c
+@@ -182,9 +182,9 @@ void mt76_send_tx_status(struct mt7601u_dev *dev, struct mt76_tx_status *stat)
+
+ mt76_mac_fill_tx_status(dev, &info, stat);
+
+- local_bh_disable();
++ spin_lock_bh(&dev->mac_lock);
+ ieee80211_tx_status_noskb(dev->hw, sta, &info);
+- local_bh_enable();
++ spin_unlock_bh(&dev->mac_lock);
+
+ rcu_read_unlock();
+ }
+diff --git a/drivers/net/wireless/mediatek/mt7601u/mt7601u.h b/drivers/net/wireless/mediatek/mt7601u/mt7601u.h
+index bc5e294..428bd2f 100644
+--- a/drivers/net/wireless/mediatek/mt7601u/mt7601u.h
++++ b/drivers/net/wireless/mediatek/mt7601u/mt7601u.h
+@@ -141,8 +141,9 @@ enum {
+ /**
+ * struct mt7601u_dev - adapter structure
+ * @lock: protects @wcid->tx_rate.
++ * @mac_lock: locks out mac80211's tx status and rx paths.
+ * @tx_lock: protects @tx_q and changes of MT7601U_STATE_*_STATS
+- flags in @state.
++ * flags in @state.
+ * @rx_lock: protects @rx_q.
+ * @con_mon_lock: protects @ap_bssid, @bcn_*, @avg_rssi.
+ * @mutex: ensures exclusive access from mac80211 callbacks.
+@@ -177,6 +178,7 @@ struct mt7601u_dev {
+ struct mt76_wcid __rcu *wcid[N_WCIDS];
+
+ spinlock_t lock;
++ spinlock_t mac_lock;
+
+ const u16 *beacon_offsets;
+
+diff --git a/drivers/net/wireless/mediatek/mt7601u/tx.c b/drivers/net/wireless/mediatek/mt7601u/tx.c
+index 0be2080..a0a33dc 100644
+--- a/drivers/net/wireless/mediatek/mt7601u/tx.c
++++ b/drivers/net/wireless/mediatek/mt7601u/tx.c
+@@ -116,7 +116,10 @@ void mt7601u_tx_status(struct mt7601u_dev *dev, struct sk_buff *skb)
+ ieee80211_tx_info_clear_status(info);
+ info->status.rates[0].idx = -1;
+ info->flags |= IEEE80211_TX_STAT_ACK;
++
++ spin_lock(&dev->mac_lock);
+ ieee80211_tx_status(dev->hw, skb);
++ spin_unlock(&dev->mac_lock);
+ }
+
+ static int mt7601u_skb_rooms(struct mt7601u_dev *dev, struct sk_buff *skb)
+--
+cgit v0.12
+
+++ /dev/null
---- binutils-2.22/bfd/elf-bfd.h
-+++ binutils-2.22/bfd/elf-bfd.h
-@@ -1577,6 +1577,9 @@ struct elf_obj_tdata
- /* Segment flags for the PT_GNU_STACK segment. */
- unsigned int stack_flags;
-
-+ /* Segment flags for the PT_PAX_FLAGS segment. */
-+ unsigned int pax_flags;
-+
- /* Symbol version definitions in external objects. */
- Elf_Internal_Verdef *verdef;
-
---- binutils-2.22/bfd/elf.c
-+++ binutils-2.22/bfd/elf.c
-@@ -1158,6 +1158,7 @@ get_segment_type (unsigned int p_type)
- case PT_GNU_EH_FRAME: pt = "EH_FRAME"; break;
- case PT_GNU_STACK: pt = "STACK"; break;
- case PT_GNU_RELRO: pt = "RELRO"; break;
-+ case PT_PAX_FLAGS: pt = "PAX_FLAGS"; break;
- default: pt = NULL; break;
- }
- return pt;
-@@ -2477,6 +2478,9 @@ bfd_section_from_phdr (bfd *abfd, Elf_Internal_Phdr *hdr, int hdr_index)
- case PT_GNU_RELRO:
- return _bfd_elf_make_section_from_phdr (abfd, hdr, hdr_index, "relro");
-
-+ case PT_PAX_FLAGS:
-+ return _bfd_elf_make_section_from_phdr (abfd, hdr, hdr_index, "pax_flags");
-+
- default:
- /* Check for any processor-specific program segment types. */
- bed = get_elf_backend_data (abfd);
-@@ -3551,6 +3555,11 @@ get_program_header_size (bfd *abfd, struct bfd_link_info *info)
- ++segs;
- }
-
-+ {
-+ /* We need a PT_PAX_FLAGS segment. */
-+ ++segs;
-+ }
-+
- for (s = abfd->sections; s != NULL; s = s->next)
- {
- if ((s->flags & SEC_LOAD) != 0
-@@ -4153,6 +4162,20 @@ _bfd_elf_map_sections_to_segments (bfd *abfd, struct bfd_link_info *info)
- }
- }
-
-+ {
-+ amt = sizeof (struct elf_segment_map);
-+ m = bfd_zalloc (abfd, amt);
-+ if (m == NULL)
-+ goto error_return;
-+ m->next = NULL;
-+ m->p_type = PT_PAX_FLAGS;
-+ m->p_flags = elf_tdata (abfd)->pax_flags;
-+ m->p_flags_valid = 1;
-+
-+ *pm = m;
-+ pm = &m->next;
-+ }
-+
- free (sections);
- elf_tdata (abfd)->segment_map = mfirst;
- }
-@@ -5417,7 +5440,8 @@ rewrite_elf_program_header (bfd *ibfd, bfd *obfd)
- 6. PT_TLS segment includes only SHF_TLS sections.
- 7. SHF_TLS sections are only in PT_TLS or PT_LOAD segments.
- 8. PT_DYNAMIC should not contain empty sections at the beginning
-- (with the possible exception of .dynamic). */
-+ (with the possible exception of .dynamic).
-+ 9. PT_PAX_FLAGS segments do not include any sections. */
- #define IS_SECTION_IN_INPUT_SEGMENT(section, segment, bed) \
- ((((segment->p_paddr \
- ? IS_CONTAINED_BY_LMA (section, segment, segment->p_paddr) \
-@@ -5425,6 +5449,7 @@ rewrite_elf_program_header (bfd *ibfd, bfd *obfd)
- && (section->flags & SEC_ALLOC) != 0) \
- || IS_NOTE (segment, section)) \
- && segment->p_type != PT_GNU_STACK \
-+ && segment->p_type != PT_PAX_FLAGS \
- && (segment->p_type != PT_TLS \
- || (section->flags & SEC_THREAD_LOCAL)) \
- && (segment->p_type == PT_LOAD \
---- binutils-2.22/bfd/elflink.c
-+++ binutils-2.22/bfd/elflink.c
-@@ -5545,16 +5545,30 @@ bfd_elf_size_dynamic_sections (bfd *output_bfd,
- return TRUE;
-
- bed = get_elf_backend_data (output_bfd);
-+
-+ elf_tdata (output_bfd)->pax_flags = PF_NORANDEXEC;
-+ if (info->execheap)
-+ elf_tdata (output_bfd)->pax_flags |= PF_NOMPROTECT;
-+ else if (info->noexecheap)
-+ elf_tdata (output_bfd)->pax_flags |= PF_MPROTECT;
-+
- if (info->execstack)
-- elf_tdata (output_bfd)->stack_flags = PF_R | PF_W | PF_X;
-+ {
-+ elf_tdata (output_bfd)->stack_flags = PF_R | PF_W | PF_X;
-+ elf_tdata (output_bfd)->pax_flags |= PF_EMUTRAMP;
-+ }
- else if (info->noexecstack)
-- elf_tdata (output_bfd)->stack_flags = PF_R | PF_W;
-+ {
-+ elf_tdata (output_bfd)->stack_flags = PF_R | PF_W;
-+ elf_tdata (output_bfd)->pax_flags |= PF_NOEMUTRAMP;
-+ }
- else
- {
- bfd *inputobj;
- asection *notesec = NULL;
- int exec = 0;
-
-+ elf_tdata (output_bfd)->pax_flags |= PF_NOEMUTRAMP;
- for (inputobj = info->input_bfds;
- inputobj;
- inputobj = inputobj->link_next)
-@@ -5567,7 +5581,11 @@ bfd_elf_size_dynamic_sections (bfd *output_bfd,
- if (s)
- {
- if (s->flags & SEC_CODE)
-- exec = PF_X;
-+ {
-+ elf_tdata (output_bfd)->pax_flags &= ~PF_NOEMUTRAMP;
-+ elf_tdata (output_bfd)->pax_flags |= PF_EMUTRAMP;
-+ exec = PF_X;
-+ }
- notesec = s;
- }
- else if (bed->default_execstack)
---- binutils-2.22/binutils/readelf.c
-+++ binutils-2.22/binutils/readelf.c
-@@ -2740,6 +2740,7 @@ get_segment_type (unsigned long p_type)
- return "GNU_EH_FRAME";
- case PT_GNU_STACK: return "GNU_STACK";
- case PT_GNU_RELRO: return "GNU_RELRO";
-+ case PT_PAX_FLAGS: return "PAX_FLAGS";
-
- default:
- if ((p_type >= PT_LOPROC) && (p_type <= PT_HIPROC))
---- binutils-2.22/include/bfdlink.h
-+++ binutils-2.22/include/bfdlink.h
-@@ -322,6 +322,14 @@ struct bfd_link_info
- /* TRUE if PT_GNU_RELRO segment should be created. */
- unsigned int relro: 1;
-
-+ /* TRUE if PT_PAX_FLAGS segment should be created with PF_NOMPROTECT
-+ flags. */
-+ unsigned int execheap: 1;
-+
-+ /* TRUE if PT_PAX_FLAGS segment should be created with PF_MPROTECT
-+ flags. */
-+ unsigned int noexecheap: 1;
-+
- /* TRUE if .eh_frame_hdr section and PT_GNU_EH_FRAME ELF segment
- should be created. */
- unsigned int eh_frame_hdr: 1;
---- binutils-2.22/include/elf/common.h
-+++ binutils-2.22/include/elf/common.h
-@@ -429,6 +429,7 @@
- #define PT_SUNW_EH_FRAME PT_GNU_EH_FRAME /* Solaris uses the same value */
- #define PT_GNU_STACK (PT_LOOS + 0x474e551) /* Stack flags */
- #define PT_GNU_RELRO (PT_LOOS + 0x474e552) /* Read-only after relocation */
-+#define PT_PAX_FLAGS (PT_LOOS + 0x5041580) /* PaX flags */
-
- /* Program segment permissions, in program header p_flags field. */
-
-@@ -439,6 +440,21 @@
- #define PF_MASKOS 0x0FF00000 /* New value, Oct 4, 1999 Draft */
- #define PF_MASKPROC 0xF0000000 /* Processor-specific reserved bits */
-
-+/* Flags to control PaX behavior. */
-+
-+#define PF_PAGEEXEC (1 << 4) /* Enable PAGEEXEC */
-+#define PF_NOPAGEEXEC (1 << 5) /* Disable PAGEEXEC */
-+#define PF_SEGMEXEC (1 << 6) /* Enable SEGMEXEC */
-+#define PF_NOSEGMEXEC (1 << 7) /* Disable SEGMEXEC */
-+#define PF_MPROTECT (1 << 8) /* Enable MPROTECT */
-+#define PF_NOMPROTECT (1 << 9) /* Disable MPROTECT */
-+#define PF_RANDEXEC (1 << 10) /* Enable RANDEXEC */
-+#define PF_NORANDEXEC (1 << 11) /* Disable RANDEXEC */
-+#define PF_EMUTRAMP (1 << 12) /* Enable EMUTRAMP */
-+#define PF_NOEMUTRAMP (1 << 13) /* Disable EMUTRAMP */
-+#define PF_RANDMMAP (1 << 14) /* Enable RANDMMAP */
-+#define PF_NORANDMMAP (1 << 15) /* Disable RANDMMAP */
-+
- /* Values for section header, sh_type field. */
-
- #define SHT_NULL 0 /* Section header table entry unused */
---- binutils-2.22/ld/emultempl/elf32.em
-+++ binutils-2.22/ld/emultempl/elf32.em
-@@ -2285,6 +2285,16 @@ fragment <<EOF
- link_info.noexecstack = TRUE;
- link_info.execstack = FALSE;
- }
-+ else if (strcmp (optarg, "execheap") == 0)
-+ {
-+ link_info.execheap = TRUE;
-+ link_info.noexecheap = FALSE;
-+ }
-+ else if (strcmp (optarg, "noexecheap") == 0)
-+ {
-+ link_info.noexecheap = TRUE;
-+ link_info.execheap = FALSE;
-+ }
- EOF
- if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
- fragment <<EOF
-@@ -2368,6 +2378,8 @@ fragment <<EOF
- -z defs Report unresolved symbols in object files.\n"));
- fprintf (file, _("\
- -z execstack Mark executable as requiring executable stack\n"));
-+ fprintf (file, _("\
-+ -z execheap Mark executable as requiring executable heap\n"));
- EOF
-
- if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
-@@ -2391,6 +2403,8 @@ fragment <<EOF
- fragment <<EOF
- fprintf (file, _("\
- -z noexecstack Mark executable as not requiring executable stack\n"));
-+ fprintf (file, _("\
-+ -z noexecheap Mark executable as not requiring executable heap\n"));
- EOF
- if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
- fragment <<EOF
---- binutils-2.22/ld/ldgram.y
-+++ binutils-2.22/ld/ldgram.y
-@@ -1119,6 +1119,8 @@ phdr_type:
- $$ = exp_intop (0x6474e550);
- else if (strcmp (s, "PT_GNU_STACK") == 0)
- $$ = exp_intop (0x6474e551);
-+ else if (strcmp (s, "PT_PAX_FLAGS") == 0)
-+ $$ = exp_intop (0x65041580);
- else
- {
- einfo (_("\
---- binutils-2.22/ld/testsuite/ld-alpha/tlsbin.rd
-+++ binutils-2.22/ld/testsuite/ld-alpha/tlsbin.rd
-@@ -35,13 +35,14 @@ There are [0-9]+ program headers, starting at offset [0-9]+
-
- Program Headers:
- Type +Offset +VirtAddr +PhysAddr +FileSiz +MemSiz +Flg Align
-- PHDR +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+150 R E 0x8
-+ PHDR +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+188 R E 0x8
- INTERP +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ R +0x1
- .*Requesting program interpreter.*
- LOAD +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ R E 0x10000
- LOAD +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ RWE 0x10000
- DYNAMIC +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ RW +0x8
- TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ R +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- #...
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 3 entries:
---- binutils-2.22/ld/testsuite/ld-alpha/tlsbinr.rd
-+++ binutils-2.22/ld/testsuite/ld-alpha/tlsbinr.rd
-@@ -42,6 +42,7 @@ Program Headers:
- +LOAD +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ RWE 0x10000
- +DYNAMIC +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ RW +0x8
- +TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ R +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- #...
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 2 entries:
---- binutils-2.22/ld/testsuite/ld-alpha/tlspic.rd
-+++ binutils-2.22/ld/testsuite/ld-alpha/tlspic.rd
-@@ -38,6 +38,7 @@ Program Headers:
- +LOAD +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ RWE 0x10000
- +DYNAMIC +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ RW +0x8
- +TLS +0x0+10e0 0x0+110e0 0x0+110e0 0x0+60 0x0+80 R +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- #...
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 7 entries:
---- binutils-2.22/ld/testsuite/ld-elf/eh1.d
-+++ binutils-2.22/ld/testsuite/ld-elf/eh1.d
-@@ -22,11 +22,11 @@ Contents of the .eh_frame section:
- DW_CFA_nop
- DW_CFA_nop
-
--00000018 0000001c 0000001c FDE cie=00000000 pc=00400078..00400078
-- DW_CFA_advance_loc: 0 to 00400078
-+00000018 0000001c 0000001c FDE cie=00000000 pc=([0-9a-f]+)..\1
-+ DW_CFA_advance_loc: 0 to [0-9a-f]+
- DW_CFA_def_cfa_offset: 16
- DW_CFA_offset: r6 \(rbp\) at cfa-16
-- DW_CFA_advance_loc: 0 to 00400078
-+ DW_CFA_advance_loc: 0 to [0-9a-f]+
- DW_CFA_def_cfa_register: r6 \(rbp\)
-
- 00000038 ZERO terminator
---- binutils-2.22/ld/testsuite/ld-elf/eh2.d
-+++ binutils-2.22/ld/testsuite/ld-elf/eh2.d
-@@ -22,11 +22,11 @@ Contents of the .eh_frame section:
- DW_CFA_nop
- DW_CFA_nop
-
--00000018 0000001c 0000001c FDE cie=00000000 pc=00400078..00400078
-- DW_CFA_advance_loc: 0 to 00400078
-+00000018 0000001c 0000001c FDE cie=00000000 pc=([0-9a-f]+)..\1
-+ DW_CFA_advance_loc: 0 to [0-9a-f]+
- DW_CFA_def_cfa_offset: 16
- DW_CFA_offset: r6 \(rbp\) at cfa-16
-- DW_CFA_advance_loc: 0 to 00400078
-+ DW_CFA_advance_loc: 0 to [0-9a-f]+
- DW_CFA_def_cfa_register: r6 \(rbp\)
-
- 00000038 ZERO terminator
---- binutils-2.22/ld/testsuite/ld-elf/eh3.d
-+++ binutils-2.22/ld/testsuite/ld-elf/eh3.d
-@@ -22,11 +22,11 @@ Contents of the .eh_frame section:
- DW_CFA_nop
- DW_CFA_nop
-
--00000018 0000001c 0000001c FDE cie=00000000 pc=00400078..00400078
-- DW_CFA_advance_loc: 0 to 00400078
-+00000018 0000001c 0000001c FDE cie=00000000 pc=([0-9a-f]+)..\1
-+ DW_CFA_advance_loc: 0 to [0-9a-f]+
- DW_CFA_def_cfa_offset: 16
- DW_CFA_offset: r6 \(rbp\) at cfa-16
-- DW_CFA_advance_loc: 0 to 00400078
-+ DW_CFA_advance_loc: 0 to [0-9a-f]+
- DW_CFA_def_cfa_register: r6 \(rbp\)
-
- 00000038 ZERO terminator
---- binutils-2.22/ld/testsuite/ld-elf/orphan-region.d
-+++ binutils-2.22/ld/testsuite/ld-elf/orphan-region.d
-@@ -15,7 +15,9 @@
- Program Headers:
- Type.*
- LOAD[ \t]+0x[0-9a-f]+ 0x0*40000000 0x0*40000000 0x[0-9a-f]+ 0x[0-9a-f]+ RWE 0x[0-9a-f]+
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- Segment Sections...
- 00 .text .rodata .moredata *
-+ 01 +
---- binutils-2.22/ld/testsuite/ld-i386/tlsbin.rd
-+++ binutils-2.22/ld/testsuite/ld-i386/tlsbin.rd
-@@ -44,6 +44,7 @@ Program Headers:
- +LOAD.*
- +DYNAMIC.*
- +TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+60 0x0+a0 R +0x1000
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- +Segment Sections...
-@@ -53,6 +54,7 @@ Program Headers:
- +03 +.tdata .dynamic .got .got.plt *
- +04 +.dynamic *
- +05 +.tdata .tbss *
-+ +06 +
-
- Relocation section '.rel.dyn' at offset 0x[0-9a-f]+ contains 9 entries:
- Offset +Info +Type +Sym.Value +Sym. Name
---- binutils-2.22/ld/testsuite/ld-i386/tlsbindesc.rd
-+++ binutils-2.22/ld/testsuite/ld-i386/tlsbindesc.rd
-@@ -42,6 +42,7 @@ Program Headers:
- +LOAD.*
- +DYNAMIC.*
- +TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+60 0x0+a0 R +0x1000
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- +Segment Sections...
-@@ -51,6 +52,7 @@ Program Headers:
- +03 +.tdata .dynamic .got .got.plt *
- +04 +.dynamic *
- +05 +.tdata .tbss *
-+ +06 +
-
- Relocation section '.rel.dyn' at offset 0x[0-9a-f]+ contains 9 entries:
- Offset +Info +Type +Sym.Value +Sym. Name
---- binutils-2.22/ld/testsuite/ld-i386/tlsdesc.rd
-+++ binutils-2.22/ld/testsuite/ld-i386/tlsdesc.rd
-@@ -39,6 +39,7 @@ Program Headers:
- +LOAD.*
- +DYNAMIC.*
- +TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+60 0x0+80 R +0x1
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- +Segment Sections...
-@@ -46,6 +47,7 @@ Program Headers:
- +01 +.tdata .dynamic .got .got.plt *
- +02 +.dynamic *
- +03 +.tdata .tbss *
-+ +04 +
-
- Relocation section '.rel.dyn' at offset 0x[0-9a-f]+ contains 20 entries:
- Offset +Info +Type +Sym.Value +Sym. Name
---- binutils-2.22/ld/testsuite/ld-i386/tlsdesc.sd
-+++ binutils-2.22/ld/testsuite/ld-i386/tlsdesc.sd
-@@ -14,7 +14,7 @@ Contents of section \.got:
- [0-9a-f]+ 6c000000 b4ffffff 4c000000 68000000 .*
- [0-9a-f]+ 50000000 70000000 00000000 bcffffff .*
- Contents of section \.got\.plt:
-- [0-9a-f]+ b0150000 00000000 00000000 00000000 .*
-+ [0-9a-f]+ [a-f]0150000 00000000 00000000 00000000 .*
- [0-9a-f]+ 20000000 00000000 60000000 00000000 .*
- [0-9a-f]+ 00000000 00000000 00000000 00000000 .*
- [0-9a-f]+ 40000000 +.*
---- binutils-2.22/ld/testsuite/ld-i386/tlsgdesc.rd
-+++ binutils-2.22/ld/testsuite/ld-i386/tlsgdesc.rd
-@@ -36,12 +36,14 @@ Program Headers:
- +LOAD.*
- +LOAD.*
- +DYNAMIC.*
-+ +PAX_FLAGS.*
-
- Section to Segment mapping:
- +Segment Sections...
- +00 +.hash .dynsym .dynstr .rel.dyn .rel.plt .plt .text *
- +01 +.dynamic .got .got.plt *
- +02 +.dynamic *
-+ +03 +
-
- Relocation section '.rel.dyn' at offset 0x[0-9a-f]+ contains 8 entries:
- Offset +Info +Type +Sym.Value +Sym. Name
---- binutils-2.22/ld/testsuite/ld-i386/tlsnopic.rd
-+++ binutils-2.22/ld/testsuite/ld-i386/tlsnopic.rd
-@@ -37,6 +37,7 @@ Program Headers:
- +LOAD.*
- +DYNAMIC.*
- +TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+ 0x0+24 R +0x1
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- +Segment Sections...
-@@ -44,6 +45,7 @@ Program Headers:
- +01 +.dynamic .got .got.plt *
- +02 +.dynamic *
- +03 +.tbss *
-+ +04 +
-
- Relocation section '.rel.dyn' at offset 0x[0-9a-f]+ contains 20 entries:
- Offset +Info +Type +Sym.Value +Sym. Name
---- binutils-2.22/ld/testsuite/ld-i386/tlspic.rd
-+++ binutils-2.22/ld/testsuite/ld-i386/tlspic.rd
-@@ -40,6 +40,7 @@ Program Headers:
- +LOAD.*
- +DYNAMIC.*
- +TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+60 0x0+80 R +0x1
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- +Segment Sections...
-@@ -47,6 +48,7 @@ Program Headers:
- +01 +.tdata .dynamic .got .got.plt *
- +02 +.dynamic *
- +03 +.tdata .tbss *
-+ +04 +
-
- Relocation section '.rel.dyn' at offset 0x[0-9a-f]+ contains 26 entries:
- Offset +Info +Type +Sym.Value +Sym. Name
---- binutils-2.22/ld/testsuite/ld-ia64/merge1.d
-+++ binutils-2.22/ld/testsuite/ld-ia64/merge1.d
-@@ -4,7 +4,7 @@
- #objdump: -d
-
- #...
--0+1e0 <.text>:
-+[a-f0-9]+ <.text>:
- [ ]*[a-f0-9]+: 0b 60 80 02 00 24 \[MMI\] addl r12=32,r1;;
- [ ]*[a-f0-9]+: c0 c0 04 00 48 00 addl r12=24,r1
- [ ]*[a-f0-9]+: 00 00 04 00 nop.i 0x0;;
---- binutils-2.22/ld/testsuite/ld-ia64/merge2.d
-+++ binutils-2.22/ld/testsuite/ld-ia64/merge2.d
-@@ -4,7 +4,7 @@
- #objdump: -d
-
- #...
--0+1e0 <.text>:
-+[a-f0-9]+ <.text>:
- [ ]*[a-f0-9]+: 0b 60 80 02 00 24 \[MMI\] addl r12=32,r1;;
- [ ]*[a-f0-9]+: c0 c0 04 00 48 00 addl r12=24,r1
- [ ]*[a-f0-9]+: 00 00 04 00 nop.i 0x0;;
---- binutils-2.22/ld/testsuite/ld-ia64/merge3.d
-+++ binutils-2.22/ld/testsuite/ld-ia64/merge3.d
-@@ -4,7 +4,7 @@
- #objdump: -d
-
- #...
--0+210 <.text>:
-+[a-f0-9]+ <.text>:
- [ ]*[a-f0-9]+: 0b 60 80 02 00 24 \[MMI\] addl r12=32,r1;;
- [ ]*[a-f0-9]+: c0 40 05 00 48 00 addl r12=40,r1
- [ ]*[a-f0-9]+: 00 00 04 00 nop.i 0x0;;
---- binutils-2.22/ld/testsuite/ld-ia64/merge4.d
-+++ binutils-2.22/ld/testsuite/ld-ia64/merge4.d
-@@ -4,7 +4,7 @@
- #objdump: -d
-
- #...
--0+240 <.text>:
-+[a-f0-9]+ <.text>:
- [ ]*[a-f0-9]+: 0b 60 80 02 00 24 \[MMI\] addl r12=32,r1;;
- [ ]*[a-f0-9]+: c0 40 05 00 48 00 addl r12=40,r1
- [ ]*[a-f0-9]+: 00 00 04 00 nop.i 0x0;;
---- binutils-2.22/ld/testsuite/ld-ia64/merge5.d
-+++ binutils-2.22/ld/testsuite/ld-ia64/merge5.d
-@@ -4,7 +4,7 @@
- #objdump: -d
-
- #...
--0+270 <.text>:
-+[a-f0-9]+ <.text>:
- [ ]*[a-f0-9]+: 0b 60 80 02 00 24 \[MMI\] addl r12=32,r1;;
- [ ]*[a-f0-9]+: c0 40 05 00 48 00 addl r12=40,r1
- [ ]*[a-f0-9]+: 00 00 04 00 nop.i 0x0;;
---- binutils-2.22/ld/testsuite/ld-ia64/tlsbin.rd
-+++ binutils-2.22/ld/testsuite/ld-ia64/tlsbin.rd
-@@ -36,13 +36,14 @@ There are [0-9]+ program headers, starting at offset [0-9]+
-
- Program Headers:
- +Type +Offset +VirtAddr +PhysAddr +FileSiz +MemSiz +Flg Align
-- +PHDR +0x0+40 0x40+40 0x40+40 0x0+188 0x0+188 R E 0x8
-- +INTERP +0x0+1c8 0x40+1c8 0x40+1c8 0x[0-9a-f]+ 0x[0-9a-f]+ R +0x1
-+ +PHDR +0x0+40 0x40+40 0x40+40 (0x[0-9a-f]+) \1 R E 0x8
-+ +INTERP +0x0+([0-9a-f]+) (0x40+\1) \2 0x[0-9a-f]+ 0x[0-9a-f]+ R +0x1
- .*Requesting program interpreter.*
- +LOAD +0x0+ 0x40+ 0x40+ 0x0+1[0-9a-f]+ 0x0+1[0-9a-f]+ R E 0x10000
- +LOAD +0x0+1[0-9a-f]+ 0x60+1[0-9a-f]+ 0x60+1[0-9a-f]+ 0x0+0[0-9a-f]+ 0x0+0[0-9a-f]+ RW +0x10000
- +DYNAMIC +0x0+1[0-9a-f]+ 0x60+1[0-9a-f]+ 0x60+1[0-9a-f]+ 0x0+150 0x0+150 RW +0x8
- +TLS +0x0+1[0-9a-f]+ 0x60+1[0-9a-f]+ 0x60+1[0-9a-f]+ 0x0+60 0x0+a0 R +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- +IA_64_UNWIND .* R +0x8
- #...
-
---- binutils-2.22/ld/testsuite/ld-ia64/tlspic.rd
-+++ binutils-2.22/ld/testsuite/ld-ia64/tlspic.rd
-@@ -40,6 +40,7 @@ Program Headers:
- +LOAD +0x0+1[0-9a-f]+ 0x0+11[0-9a-f]+ 0x0+11[0-9a-f]+ 0x0+0[0-9a-f]+ 0x0+0[0-9a-f]+ RW +0x10000
- +DYNAMIC +0x0+1[0-9a-f]+ 0x0+11[0-9a-f]+ 0x0+11[0-9a-f]+ 0x0+140 0x0+140 RW +0x8
- +TLS +0x0+1[0-9a-f]+ 0x0+11[0-9a-f]+ 0x0+11[0-9a-f]+ 0x0+60 0x0+80 R +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- +IA_64_UNWIND +0x0+1[0-9a-f]+ 0x0+1[0-9a-f]+ 0x0+1[0-9a-f]+ 0x0+18 0x0+18 R +0x8
- #...
-
---- binutils-2.22/ld/testsuite/ld-mips-elf/multi-got-no-shared.d
-+++ binutils-2.22/ld/testsuite/ld-mips-elf/multi-got-no-shared.d
-@@ -8,9 +8,9 @@
- .*: +file format.*
-
- Disassembly of section \.text:
--004000b0 <[^>]*> 3c1c0043 lui gp,0x43
--004000b4 <[^>]*> 279c9ff0 addiu gp,gp,-24592
--004000b8 <[^>]*> afbc0008 sw gp,8\(sp\)
-+004000d0 <[^>]*> 3c1c0043 lui gp,0x43
-+004000d4 <[^>]*> 279c9ff0 addiu gp,gp,-24592
-+004000d8 <[^>]*> afbc0008 sw gp,8\(sp\)
- #...
- 00408d60 <[^>]*> 3c1c0043 lui gp,0x43
- 00408d64 <[^>]*> 279c2c98 addiu gp,gp,11416
---- binutils-2.22/ld/testsuite/ld-mips-elf/pic-and-nonpic-3a.sd
-+++ binutils-2.22/ld/testsuite/ld-mips-elf/pic-and-nonpic-3a.sd
-@@ -1,7 +1,7 @@
-
- Elf file type is DYN \(Shared object file\)
- Entry point .*
--There are 5 program headers, starting at offset .*
-+There are [0-9] program headers, starting at offset .*
-
- Program Headers:
- * Type * Offset * VirtAddr * PhysAddr * FileSiz * MemSiz * Flg * Align
-@@ -9,6 +9,7 @@ Program Headers:
- * LOAD * [^ ]+ * 0x0+00000 * 0x0+00000 [^ ]+ * [^ ]+ * R E * 0x.*
- * LOAD * [^ ]+ * 0x0+10000 * 0x0+10000 [^ ]+ * [^ ]+ * RW * 0x.*
- * DYNAMIC * [^ ]+ * 0x0+00400 * 0x0+00400 .*
-+ * PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- * NULL * .*
-
- *Section to Segment mapping:
-@@ -18,3 +19,4 @@ Program Headers:
- *0*2 * \.data \.got *
- *0*3 * \.dynamic *
- *0*4 *
-+ *0*5 *
---- binutils-2.22/ld/testsuite/ld-mips-elf/pic-and-nonpic-3b.sd
-+++ binutils-2.22/ld/testsuite/ld-mips-elf/pic-and-nonpic-3b.sd
-@@ -1,7 +1,7 @@
-
- Elf file type is EXEC \(Executable file\)
- Entry point 0x44000
--There are 8 program headers, starting at offset .*
-+There are [0-9] program headers, starting at offset .*
-
- Program Headers:
- * Type * Offset * VirtAddr * PhysAddr * FileSiz * MemSiz * Flg * Align
-@@ -13,6 +13,7 @@ Program Headers:
- * LOAD * [^ ]+ * 0x0+80000 * 0x0+80000 [^ ]+ * [^ ]+ * RW * 0x.*
- * LOAD * [^ ]+ * 0x0+a0000 * 0x0+a0000 [^ ]+ * [^ ]+ * RW * 0x.*
- * DYNAMIC * [^ ]+ * 0x0+42000 * 0x0+42000 .*
-+ * PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- * NULL * .*
-
- *Section to Segment mapping:
-@@ -25,3 +26,4 @@ Program Headers:
- *0*5 *\.got \.data *
- *0*6 *\.dynamic *
- *0*7 *
-+ *0*8 *
---- binutils-2.22/ld/testsuite/ld-mips-elf/pic-and-nonpic-4b.sd
-+++ binutils-2.22/ld/testsuite/ld-mips-elf/pic-and-nonpic-4b.sd
-@@ -1,7 +1,7 @@
-
- Elf file type is EXEC \(Executable file\)
- Entry point 0x44000
--There are 8 program headers, starting at offset .*
-+There are [0-9] program headers, starting at offset .*
-
- Program Headers:
- * Type * Offset * VirtAddr * PhysAddr * FileSiz * MemSiz * Flg * Align
-@@ -13,6 +13,7 @@ Program Headers:
- * LOAD * [^ ]+ * 0x0+80000 * 0x0+80000 [^ ]+ * [^ ]+ * RW * 0x.*
- * LOAD * [^ ]+ * 0x0+a0000 * 0x0+a0000 [^ ]+ * [^ ]+ * RW * 0x.*
- * DYNAMIC * [^ ]+ * 0x0+42000 * 0x0+42000 .*
-+ * PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- * NULL * .*
-
- *Section to Segment mapping:
-@@ -25,3 +26,4 @@ Program Headers:
- *0*5 * \.got \.data \.bss *
- *0*6 * \.dynamic *
- *0*7 *
-+ *0*8 *
---- binutils-2.22/ld/testsuite/ld-mips-elf/pic-and-nonpic-5b.sd
-+++ binutils-2.22/ld/testsuite/ld-mips-elf/pic-and-nonpic-5b.sd
-@@ -1,7 +1,7 @@
-
- Elf file type is EXEC \(Executable file\)
- Entry point 0x44000
--There are 8 program headers, starting at offset .*
-+There are [0-9] program headers, starting at offset .*
-
- Program Headers:
- * Type * Offset * VirtAddr * PhysAddr * FileSiz * MemSiz * Flg * Align
-@@ -13,6 +13,7 @@ Program Headers:
- * LOAD * [^ ]+ * 0x0+80000 * 0x0+80000 [^ ]+ * [^ ]+ * RW * 0x.*
- * LOAD * [^ ]+ * 0x0+a0000 * 0x0+a0000 [^ ]+ * [^ ]+ * RW * 0x.*
- * DYNAMIC * [^ ]+ * 0x0+42000 * 0x0+42000 .*
-+ * PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- * NULL * .*
-
- *Section to Segment mapping:
-@@ -25,3 +26,4 @@ Program Headers:
- *0*5 * \.got \.data \.bss *
- *0*6 * \.dynamic *
- *0*7 *
-+ *0*8 *
---- binutils-2.22/ld/testsuite/ld-mips-elf/pic-and-nonpic-6-n32.sd
-+++ binutils-2.22/ld/testsuite/ld-mips-elf/pic-and-nonpic-6-n32.sd
-@@ -1,7 +1,7 @@
-
- Elf file type is EXEC \(Executable file\)
- Entry point 0x44000
--There are 8 program headers, starting at offset .*
-+There are [0-9] program headers, starting at offset .*
-
- Program Headers:
- * Type * Offset * VirtAddr * PhysAddr * FileSiz * MemSiz * Flg * Align
-@@ -13,6 +13,7 @@ Program Headers:
- * LOAD * [^ ]+ * 0x0+80000 * 0x0+80000 [^ ]+ * [^ ]+ * RW * 0x.*
- * LOAD * [^ ]+ * 0x0+a0000 * 0x0+a0000 [^ ]+ * [^ ]+ * RW * 0x.*
- * DYNAMIC * [^ ]+ * 0x0+42000 * 0x0+42000 .*
-+ * PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- * NULL * .*
-
- *Section to Segment mapping:
-@@ -25,3 +26,4 @@ Program Headers:
- *0*5 * \.got \.data \.bss *
- *0*6 * \.dynamic *
- *0*7 *
-+ *0*8 *
---- binutils-2.22/ld/testsuite/ld-mips-elf/pic-and-nonpic-6-n64.sd
-+++ binutils-2.22/ld/testsuite/ld-mips-elf/pic-and-nonpic-6-n64.sd
-@@ -1,7 +1,7 @@
-
- Elf file type is EXEC \(Executable file\)
- Entry point 0x44000
--There are 7 program headers, starting at offset .*
-+There are [0-9] program headers, starting at offset .*
-
- Program Headers:
- * Type * Offset * VirtAddr * PhysAddr * FileSiz * MemSiz * Flg * Align
-@@ -12,6 +12,7 @@ Program Headers:
- * LOAD * [^ ]+ * 0x0+80000 * 0x0+80000 [^ ]+ * [^ ]+ * RW * 0x.*
- * LOAD * [^ ]+ * 0x0+a0000 * 0x0+a0000 [^ ]+ * [^ ]+ * RW * 0x.*
- * DYNAMIC * [^ ]+ * 0x0+42000 * 0x0+42000 .*
-+ * PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- * NULL * .*
-
- *Section to Segment mapping:
-@@ -23,3 +24,4 @@ Program Headers:
- *0*4 * \.got \.data \.bss *
- *0*5 * \.dynamic *
- *0*6 *
-+ *0*7 *
---- binutils-2.22/ld/testsuite/ld-mips-elf/pic-and-nonpic-6-o32.sd
-+++ binutils-2.22/ld/testsuite/ld-mips-elf/pic-and-nonpic-6-o32.sd
-@@ -1,7 +1,7 @@
-
- Elf file type is EXEC \(Executable file\)
- Entry point 0x44000
--There are 8 program headers, starting at offset .*
-+There are [0-9] program headers, starting at offset .*
-
- Program Headers:
- * Type * Offset * VirtAddr * PhysAddr * FileSiz * MemSiz * Flg * Align
-@@ -13,6 +13,7 @@ Program Headers:
- * LOAD * [^ ]+ * 0x0+80000 * 0x0+80000 [^ ]+ * [^ ]+ * RW * 0x.*
- * LOAD * [^ ]+ * 0x0+a0000 * 0x0+a0000 [^ ]+ * [^ ]+ * RW * 0x.*
- * DYNAMIC * [^ ]+ * 0x0+42000 * 0x0+42000 .*
-+ * PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- * NULL * .*
-
- *Section to Segment mapping:
-@@ -25,3 +26,4 @@ Program Headers:
- *0*5 * \.got \.data \.bss *
- *0*6 * \.dynamic *
- *0*7 *
-+ *0*8 *
---- binutils-2.22/ld/testsuite/ld-mips-elf/rel32-n32.d
-+++ binutils-2.22/ld/testsuite/ld-mips-elf/rel32-n32.d
-@@ -10,6 +10,6 @@ Relocation section '.rel.dyn' at offset .* contains 2 entries:
- [0-9a-f ]+R_MIPS_REL32
-
- Hex dump of section '.text':
-- 0x000002e0 00000000 00000000 00000000 00000000 ................
-- 0x000002f0 000002f0 00000000 00000000 00000000 ................
- 0x00000300 00000000 00000000 00000000 00000000 ................
-+ 0x00000310 00000310 00000000 00000000 00000000 ................
-+ 0x00000320 00000000 00000000 00000000 00000000 ................
---- binutils-2.22/ld/testsuite/ld-mips-elf/rel32-o32.d
-+++ binutils-2.22/ld/testsuite/ld-mips-elf/rel32-o32.d
-@@ -10,6 +10,6 @@ Relocation section '.rel.dyn' at offset .* contains 2 entries:
- [0-9a-f ]+R_MIPS_REL32
-
- Hex dump of section '.text':
-- 0x000002e0 00000000 00000000 00000000 00000000 ................
-- 0x000002f0 000002f0 00000000 00000000 00000000 ................
- 0x00000300 00000000 00000000 00000000 00000000 ................
-+ 0x00000310 00000310 00000000 00000000 00000000 ................
-+ 0x00000320 00000000 00000000 00000000 00000000 ................
---- binutils-2.22/ld/testsuite/ld-mips-elf/rel64.d
-+++ binutils-2.22/ld/testsuite/ld-mips-elf/rel64.d
-@@ -14,6 +14,6 @@ Relocation section '.rel.dyn' at offset .* contains 2 entries:
- +Type3: R_MIPS_NONE
-
- Hex dump of section '.text':
-- 0x00000450 00000000 00000000 00000000 00000000 ................
-- 0x00000460 00000000 00000460 00000000 00000000 ................
-- 0x00000470 00000000 00000000 00000000 00000000 ................
-+ 0x00000490 00000000 00000000 00000000 00000000 ................
-+ 0x000004a0 00000000 000004a0 00000000 00000000 ................
-+ 0x000004b0 00000000 00000000 00000000 00000000 ................
---- binutils-2.22/ld/testsuite/ld-mips-elf/tlsbin-o32.d
-+++ binutils-2.22/ld/testsuite/ld-mips-elf/tlsbin-o32.d
-@@ -2,42 +2,42 @@
-
- Disassembly of section .text:
-
--004000d0 <__start>:
-- 4000d0: 3c1c0fc0 lui gp,0xfc0
-- 4000d4: 279c7f30 addiu gp,gp,32560
-- 4000d8: 0399e021 addu gp,gp,t9
-- 4000dc: 27bdfff0 addiu sp,sp,-16
-- 4000e0: afbe0008 sw s8,8\(sp\)
-- 4000e4: 03a0f021 move s8,sp
-- 4000e8: afbc0000 sw gp,0\(sp\)
-- 4000ec: 8f998018 lw t9,-32744\(gp\)
-- 4000f0: 27848028 addiu a0,gp,-32728
-- 4000f4: 0320f809 jalr t9
-- 4000f8: 00000000 nop
-- 4000fc: 8fdc0000 lw gp,0\(s8\)
-- 400100: 00000000 nop
-- 400104: 8f998018 lw t9,-32744\(gp\)
-- 400108: 27848020 addiu a0,gp,-32736
-- 40010c: 0320f809 jalr t9
-- 400110: 00000000 nop
-- 400114: 8fdc0000 lw gp,0\(s8\)
-- 400118: 00401021 move v0,v0
-- 40011c: 3c030000 lui v1,0x0
-- 400120: 24638000 addiu v1,v1,-32768
-- 400124: 00621821 addu v1,v1,v0
-- 400128: 7c02283b rdhwr v0,\$5
-- 40012c: 8f83801c lw v1,-32740\(gp\)
-- 400130: 00000000 nop
-- 400134: 00621821 addu v1,v1,v0
-- 400138: 7c02283b rdhwr v0,\$5
-- 40013c: 3c030000 lui v1,0x0
-- 400140: 24639004 addiu v1,v1,-28668
-- 400144: 00621821 addu v1,v1,v0
-- 400148: 03c0e821 move sp,s8
-- 40014c: 8fbe0008 lw s8,8\(sp\)
-- 400150: 03e00008 jr ra
-- 400154: 27bd0010 addiu sp,sp,16
-+00400[0-9a-f]{3} <__start>:
-+ 400[0-9a-f]{3}: 3c1c0fc0 lui gp,0xfc0
-+ 400[0-9a-f]{3}: 279c7f30 addiu gp,gp,32560
-+ 400[0-9a-f]{3}: 0399e021 addu gp,gp,t9
-+ 400[0-9a-f]{3}: 27bdfff0 addiu sp,sp,-16
-+ 400[0-9a-f]{3}: afbe0008 sw s8,8\(sp\)
-+ 400[0-9a-f]{3}: 03a0f021 move s8,sp
-+ 400[0-9a-f]{3}: afbc0000 sw gp,0\(sp\)
-+ 400[0-9a-f]{3}: 8f998018 lw t9,-32744\(gp\)
-+ 400[0-9a-f]{3}: 27848028 addiu a0,gp,-32728
-+ 400[0-9a-f]{3}: 0320f809 jalr t9
-+ 400[0-9a-f]{3}: 00000000 nop
-+ 400[0-9a-f]{3}: 8fdc0000 lw gp,0\(s8\)
-+ 400[0-9a-f]{3}: 00000000 nop
-+ 400[0-9a-f]{3}: 8f998018 lw t9,-32744\(gp\)
-+ 400[0-9a-f]{3}: 27848020 addiu a0,gp,-32736
-+ 400[0-9a-f]{3}: 0320f809 jalr t9
-+ 400[0-9a-f]{3}: 00000000 nop
-+ 400[0-9a-f]{3}: 8fdc0000 lw gp,0\(s8\)
-+ 400[0-9a-f]{3}: 00401021 move v0,v0
-+ 400[0-9a-f]{3}: 3c030000 lui v1,0x0
-+ 400[0-9a-f]{3}: 24638000 addiu v1,v1,-32768
-+ 400[0-9a-f]{3}: 00621821 addu v1,v1,v0
-+ 400[0-9a-f]{3}: 7c02283b rdhwr v0,\$5
-+ 400[0-9a-f]{3}: 8f83801c lw v1,-32740\(gp\)
-+ 400[0-9a-f]{3}: 00000000 nop
-+ 400[0-9a-f]{3}: 00621821 addu v1,v1,v0
-+ 400[0-9a-f]{3}: 7c02283b rdhwr v0,\$5
-+ 400[0-9a-f]{3}: 3c030000 lui v1,0x0
-+ 400[0-9a-f]{3}: 24639004 addiu v1,v1,-28668
-+ 400[0-9a-f]{3}: 00621821 addu v1,v1,v0
-+ 400[0-9a-f]{3}: 03c0e821 move sp,s8
-+ 400[0-9a-f]{3}: 8fbe0008 lw s8,8\(sp\)
-+ 400[0-9a-f]{3}: 03e00008 jr ra
-+ 400[0-9a-f]{3}: 27bd0010 addiu sp,sp,16
-
--00400158 <__tls_get_addr>:
-- 400158: 03e00008 jr ra
-- 40015c: 00000000 nop
-+00400[0-9a-f]{3} <__tls_get_addr>:
-+ 400[0-9a-f]{3}: 03e00008 jr ra
-+ 400[0-9a-f]{3}: 00000000 nop
---- binutils-2.22/ld/testsuite/ld-powerpc/tls.d
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tls.d
-@@ -9,45 +9,45 @@
-
- Disassembly of section \.text:
-
--0+100000e8 <_start>:
-- 100000e8: 3c 6d 00 00 addis r3,r13,0
-- 100000ec: 60 00 00 00 nop
-- 100000f0: 38 63 90 78 addi r3,r3,-28552
-- 100000f4: 3c 6d 00 00 addis r3,r13,0
-- 100000f8: 60 00 00 00 nop
-- 100000fc: 38 63 10 00 addi r3,r3,4096
-- 10000100: 3c 6d 00 00 addis r3,r13,0
-- 10000104: 60 00 00 00 nop
-- 10000108: 38 63 90 40 addi r3,r3,-28608
-- 1000010c: 3c 6d 00 00 addis r3,r13,0
-- 10000110: 60 00 00 00 nop
-- 10000114: 38 63 10 00 addi r3,r3,4096
-- 10000118: 39 23 80 48 addi r9,r3,-32696
-- 1000011c: 3d 23 00 00 addis r9,r3,0
-- 10000120: 81 49 80 50 lwz r10,-32688\(r9\)
-- 10000124: e9 22 80 10 ld r9,-32752\(r2\)
-- 10000128: 7d 49 18 2a ldx r10,r9,r3
-- 1000012c: 3d 2d 00 00 addis r9,r13,0
-- 10000130: a1 49 90 60 lhz r10,-28576\(r9\)
-- 10000134: 89 4d 90 68 lbz r10,-28568\(r13\)
-- 10000138: 3d 2d 00 00 addis r9,r13,0
-- 1000013c: 99 49 90 70 stb r10,-28560\(r9\)
-- 10000140: 3c 6d 00 00 addis r3,r13,0
-- 10000144: 60 00 00 00 nop
-- 10000148: 38 63 90 00 addi r3,r3,-28672
-- 1000014c: 3c 6d 00 00 addis r3,r13,0
-- 10000150: 60 00 00 00 nop
-- 10000154: 38 63 10 00 addi r3,r3,4096
-- 10000158: f9 43 80 08 std r10,-32760\(r3\)
-- 1000015c: 3d 23 00 00 addis r9,r3,0
-- 10000160: 91 49 80 10 stw r10,-32752\(r9\)
-- 10000164: e9 22 80 08 ld r9,-32760\(r2\)
-- 10000168: 7d 49 19 2a stdx r10,r9,r3
-- 1000016c: 3d 2d 00 00 addis r9,r13,0
-- 10000170: b1 49 90 60 sth r10,-28576\(r9\)
-- 10000174: e9 4d 90 2a lwa r10,-28632\(r13\)
-- 10000178: 3d 2d 00 00 addis r9,r13,0
-- 1000017c: a9 49 90 30 lha r10,-28624\(r9\)
-+0+10000[0-9a-f]{3} <_start>:
-+ 10000[0-9a-f]{3}: 3c 6d 00 00 addis r3,r13,0
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 38 63 90 78 addi r3,r3,-28552
-+ 10000[0-9a-f]{3}: 3c 6d 00 00 addis r3,r13,0
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 38 63 10 00 addi r3,r3,4096
-+ 10000[0-9a-f]{3}: 3c 6d 00 00 addis r3,r13,0
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 38 63 90 40 addi r3,r3,-28608
-+ 10000[0-9a-f]{3}: 3c 6d 00 00 addis r3,r13,0
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 38 63 10 00 addi r3,r3,4096
-+ 10000[0-9a-f]{3}: 39 23 80 48 addi r9,r3,-32696
-+ 10000[0-9a-f]{3}: 3d 23 00 00 addis r9,r3,0
-+ 10000[0-9a-f]{3}: 81 49 80 50 lwz r10,-32688\(r9\)
-+ 10000[0-9a-f]{3}: e9 22 80 10 ld r9,-32752\(r2\)
-+ 10000[0-9a-f]{3}: 7d 49 18 2a ldx r10,r9,r3
-+ 10000[0-9a-f]{3}: 3d 2d 00 00 addis r9,r13,0
-+ 10000[0-9a-f]{3}: a1 49 90 60 lhz r10,-28576\(r9\)
-+ 10000[0-9a-f]{3}: 89 4d 90 68 lbz r10,-28568\(r13\)
-+ 10000[0-9a-f]{3}: 3d 2d 00 00 addis r9,r13,0
-+ 10000[0-9a-f]{3}: 99 49 90 70 stb r10,-28560\(r9\)
-+ 10000[0-9a-f]{3}: 3c 6d 00 00 addis r3,r13,0
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 38 63 90 00 addi r3,r3,-28672
-+ 10000[0-9a-f]{3}: 3c 6d 00 00 addis r3,r13,0
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 38 63 10 00 addi r3,r3,4096
-+ 10000[0-9a-f]{3}: f9 43 80 08 std r10,-32760\(r3\)
-+ 10000[0-9a-f]{3}: 3d 23 00 00 addis r9,r3,0
-+ 10000[0-9a-f]{3}: 91 49 80 10 stw r10,-32752\(r9\)
-+ 10000[0-9a-f]{3}: e9 22 80 08 ld r9,-32760\(r2\)
-+ 10000[0-9a-f]{3}: 7d 49 19 2a stdx r10,r9,r3
-+ 10000[0-9a-f]{3}: 3d 2d 00 00 addis r9,r13,0
-+ 10000[0-9a-f]{3}: b1 49 90 60 sth r10,-28576\(r9\)
-+ 10000[0-9a-f]{3}: e9 4d 90 2a lwa r10,-28632\(r13\)
-+ 10000[0-9a-f]{3}: 3d 2d 00 00 addis r9,r13,0
-+ 10000[0-9a-f]{3}: a9 49 90 30 lha r10,-28624\(r9\)
-
--0+10000180 <\.__tls_get_addr>:
-- 10000180: 4e 80 00 20 blr
-+0+10000[0-9a-f]{3} <\.__tls_get_addr>:
-+ 10000[0-9a-f]{3}: 4e 80 00 20 blr
---- binutils-2.22/ld/testsuite/ld-powerpc/tls.g
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tls.g
-@@ -8,5 +8,5 @@
- .*: +file format elf64-powerpc
-
- Contents of section \.got:
-- 100101e0 00000000 100181e0 ffffffff ffff8018 .*
-- 100101f0 ffffffff ffff8058 .*
-+ 10010([0-9a-f]{3}) 00000000 10018\1 ffffffff ffff8018 .*
-+ 10010[0-9a-f]{3} ffffffff ffff8058 .*
---- binutils-2.22/ld/testsuite/ld-powerpc/tls32.d
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tls32.d
-@@ -9,42 +9,42 @@
-
- Disassembly of section \.text:
-
--0+1800094 <_start>:
-- 1800094: 3c 62 00 00 addis r3,r2,0
-- 1800098: 38 63 90 3c addi r3,r3,-28612
-- 180009c: 3c 62 00 00 addis r3,r2,0
-- 18000a0: 38 63 10 00 addi r3,r3,4096
-- 18000a4: 3c 62 00 00 addis r3,r2,0
-- 18000a8: 38 63 90 20 addi r3,r3,-28640
-- 18000ac: 3c 62 00 00 addis r3,r2,0
-- 18000b0: 38 63 10 00 addi r3,r3,4096
-- 18000b4: 39 23 80 24 addi r9,r3,-32732
-- 18000b8: 3d 23 00 00 addis r9,r3,0
-- 18000bc: 81 49 80 28 lwz r10,-32728\(r9\)
-- 18000c0: 3d 22 00 00 addis r9,r2,0
-- 18000c4: a1 49 90 30 lhz r10,-28624\(r9\)
-- 18000c8: 89 42 90 34 lbz r10,-28620\(r2\)
-- 18000cc: 3d 22 00 00 addis r9,r2,0
-- 18000d0: 99 49 90 38 stb r10,-28616\(r9\)
-- 18000d4: 3c 62 00 00 addis r3,r2,0
-- 18000d8: 38 63 90 00 addi r3,r3,-28672
-- 18000dc: 3c 62 00 00 addis r3,r2,0
-- 18000e0: 38 63 10 00 addi r3,r3,4096
-- 18000e4: 91 43 80 04 stw r10,-32764\(r3\)
-- 18000e8: 3d 23 00 00 addis r9,r3,0
-- 18000ec: 91 49 80 08 stw r10,-32760\(r9\)
-- 18000f0: 3d 22 00 00 addis r9,r2,0
-- 18000f4: b1 49 90 30 sth r10,-28624\(r9\)
-- 18000f8: a1 42 90 14 lhz r10,-28652\(r2\)
-- 18000fc: 3d 22 00 00 addis r9,r2,0
-- 1800100: a9 49 90 18 lha r10,-28648\(r9\)
-+0+1800[0-9a-f]{3} <_start>:
-+ 1800[0-9a-f]{3}: 3c 62 00 00 addis r3,r2,0
-+ 1800[0-9a-f]{3}: 38 63 90 3c addi r3,r3,-28612
-+ 1800[0-9a-f]{3}: 3c 62 00 00 addis r3,r2,0
-+ 1800[0-9a-f]{3}: 38 63 10 00 addi r3,r3,4096
-+ 1800[0-9a-f]{3}: 3c 62 00 00 addis r3,r2,0
-+ 1800[0-9a-f]{3}: 38 63 90 20 addi r3,r3,-28640
-+ 1800[0-9a-f]{3}: 3c 62 00 00 addis r3,r2,0
-+ 1800[0-9a-f]{3}: 38 63 10 00 addi r3,r3,4096
-+ 1800[0-9a-f]{3}: 39 23 80 24 addi r9,r3,-32732
-+ 1800[0-9a-f]{3}: 3d 23 00 00 addis r9,r3,0
-+ 1800[0-9a-f]{3}: 81 49 80 28 lwz r10,-32728\(r9\)
-+ 1800[0-9a-f]{3}: 3d 22 00 00 addis r9,r2,0
-+ 1800[0-9a-f]{3}: a1 49 90 30 lhz r10,-28624\(r9\)
-+ 1800[0-9a-f]{3}: 89 42 90 34 lbz r10,-28620\(r2\)
-+ 1800[0-9a-f]{3}: 3d 22 00 00 addis r9,r2,0
-+ 1800[0-9a-f]{3}: 99 49 90 38 stb r10,-28616\(r9\)
-+ 1800[0-9a-f]{3}: 3c 62 00 00 addis r3,r2,0
-+ 1800[0-9a-f]{3}: 38 63 90 00 addi r3,r3,-28672
-+ 1800[0-9a-f]{3}: 3c 62 00 00 addis r3,r2,0
-+ 1800[0-9a-f]{3}: 38 63 10 00 addi r3,r3,4096
-+ 1800[0-9a-f]{3}: 91 43 80 04 stw r10,-32764\(r3\)
-+ 1800[0-9a-f]{3}: 3d 23 00 00 addis r9,r3,0
-+ 1800[0-9a-f]{3}: 91 49 80 08 stw r10,-32760\(r9\)
-+ 1800[0-9a-f]{3}: 3d 22 00 00 addis r9,r2,0
-+ 1800[0-9a-f]{3}: b1 49 90 30 sth r10,-28624\(r9\)
-+ 1800[0-9a-f]{3}: a1 42 90 14 lhz r10,-28652\(r2\)
-+ 1800[0-9a-f]{3}: 3d 22 00 00 addis r9,r2,0
-+ 1800[0-9a-f]{3}: a9 49 90 18 lha r10,-28648\(r9\)
-
--0+1800104 <__tls_get_addr>:
-- 1800104: 4e 80 00 20 blr
-+0+1800[0-9a-f]{3} <__tls_get_addr>:
-+ 1800[0-9a-f]{3}: 4e 80 00 20 blr
- Disassembly of section \.got:
-
--0+1810128 <_GLOBAL_OFFSET_TABLE_-0x4>:
-- 1810128: 4e 80 00 21 blrl
-+0+1810[0-9a-f]{3} <_GLOBAL_OFFSET_TABLE_-0x4>:
-+ 1810[0-9a-f]{3}: 4e 80 00 21 blrl
-
--0+181012c <_GLOBAL_OFFSET_TABLE_>:
-+0+1810[0-9a-f]{3} <_GLOBAL_OFFSET_TABLE_>:
- \.\.\.
---- binutils-2.22/ld/testsuite/ld-powerpc/tls32.g
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tls32.g
-@@ -8,4 +8,4 @@
- .*: +file format elf32-powerpc
-
- Contents of section \.got:
-- 1810128 4e800021 00000000 00000000 00000000 .*
-+ 18101[0-9a-f]{2} 4e800021 00000000 00000000 00000000 .*
---- binutils-2.22/ld/testsuite/ld-powerpc/tls32.t
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tls32.t
-@@ -8,5 +8,5 @@
- .*: +file format elf32-powerpc
-
- Contents of section \.tdata:
-- 1810108 12345678 23456789 3456789a 456789ab .*
-- 1810118 56789abc 6789abcd 789abcde 00c0ffee .*
-+ 18101[0-9a-f]{2} 12345678 23456789 3456789a 456789ab .*
-+ 18101[0-9a-f]{2} 56789abc 6789abcd 789abcde 00c0ffee .*
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsexe32.d
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsexe32.d
-@@ -44,4 +44,4 @@ Disassembly of section \.got:
- .*: 4e 80 00 21 blrl
-
- .* <_GLOBAL_OFFSET_TABLE_>:
--.*: 01 81 02 b8 00 00 00 00 00 00 00 00 .*
-+.*: 01 81 02 [bd]8 00 00 00 00 00 00 00 00 .*
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsexe32.g
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsexe32.g
-@@ -8,4 +8,4 @@
-
- Contents of section \.got:
- .* 00000000 00000000 00000000 4e800021 .*
--.* 018102b8 00000000 00000000 .*
-+.* 018102[bd]8 00000000 00000000 .*
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsexe32.r
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsexe32.r
-@@ -33,13 +33,14 @@ There are [0-9]+ program headers, starting at offset [0-9]+
-
- Program Headers:
- +Type +Offset +VirtAddr +PhysAddr +FileSiz MemSiz +Flg Align
-- +PHDR +0x000034 0x01800034 0x01800034 0x000c0 0x000c0 R E 0x4
-- +INTERP +0x0000f4 0x018000f4 0x018000f4 0x00011 0x00011 R +0x1
-+ +PHDR +0x000034 0x01800034 0x01800034 (0x000[0-9a-f]{2}) \1 R E 0x4
-+ +INTERP +0x000([0-9a-f]{3}) 0x01800\1 0x01800\1 0x00011 0x00011 R +0x1
- +\[Requesting program interpreter: .*\]
- +LOAD .* R E 0x10000
- +LOAD .* RWE 0x10000
- +DYNAMIC .* RW +0x4
- +TLS .* 0x0001c 0x00038 R +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- +Segment Sections\.\.\.
-@@ -49,6 +50,7 @@ Program Headers:
- +03 +\.tdata \.dynamic \.got \.plt
- +04 +\.dynamic
- +05 +\.tdata \.tbss
-+ +06 +
-
- Relocation section '\.rela\.dyn' at offset .* contains 2 entries:
- Offset +Info +Type +Sym\. Value +Symbol's Name \+ Addend
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsmark.d
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsmark.d
-@@ -9,29 +9,29 @@
-
- Disassembly of section \.text:
-
--0+100000e8 <_start>:
-- 100000e8: 48 00 00 18 b 10000100 <_start\+0x18>
-- 100000ec: 60 00 00 00 nop
-- 100000f0: 38 63 90 00 addi r3,r3,-28672
-- 100000f4: e8 83 00 00 ld r4,0\(r3\)
-- 100000f8: 3c 6d 00 00 addis r3,r13,0
-- 100000fc: 48 00 00 0c b 10000108 <_start\+0x20>
-- 10000100: 3c 6d 00 00 addis r3,r13,0
-- 10000104: 4b ff ff e8 b 100000ec <_start\+0x4>
-- 10000108: 60 00 00 00 nop
-- 1000010c: 38 63 10 00 addi r3,r3,4096
-- 10000110: e8 83 80 00 ld r4,-32768\(r3\)
-- 10000114: 3c 6d 00 00 addis r3,r13,0
-- 10000118: 48 00 00 0c b 10000124 <_start\+0x3c>
-- 1000011c: 3c 6d 00 00 addis r3,r13,0
-- 10000120: 48 00 00 14 b 10000134 <_start\+0x4c>
-- 10000124: 60 00 00 00 nop
-- 10000128: 38 63 90 04 addi r3,r3,-28668
-- 1000012c: e8 a3 00 00 ld r5,0\(r3\)
-- 10000130: 4b ff ff ec b 1000011c <_start\+0x34>
-- 10000134: 60 00 00 00 nop
-- 10000138: 38 63 10 00 addi r3,r3,4096
-- 1000013c: e8 a3 80 04 ld r5,-32764\(r3\)
-+0+10000[0-9a-f]{3} <_start>:
-+ 10000[0-9a-f]{3}: 48 00 00 18 b 10000[0-9a-f]{3} <_start\+0x18>
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 38 63 90 00 addi r3,r3,-28672
-+ 10000[0-9a-f]{3}: e8 83 00 00 ld r4,0\(r3\)
-+ 10000[0-9a-f]{3}: 3c 6d 00 00 addis r3,r13,0
-+ 10000[0-9a-f]{3}: 48 00 00 0c b 10000[0-9a-f]{3} <_start\+0x20>
-+ 10000[0-9a-f]{3}: 3c 6d 00 00 addis r3,r13,0
-+ 10000[0-9a-f]{3}: 4b ff ff e8 b 10000[0-9a-f]{3} <_start\+0x4>
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 38 63 10 00 addi r3,r3,4096
-+ 10000[0-9a-f]{3}: e8 83 80 00 ld r4,-32768\(r3\)
-+ 10000[0-9a-f]{3}: 3c 6d 00 00 addis r3,r13,0
-+ 10000[0-9a-f]{3}: 48 00 00 0c b 10000[0-9a-f]{3} <_start\+0x3c>
-+ 10000[0-9a-f]{3}: 3c 6d 00 00 addis r3,r13,0
-+ 10000[0-9a-f]{3}: 48 00 00 14 b 10000[0-9a-f]{3} <_start\+0x4c>
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 38 63 90 04 addi r3,r3,-28668
-+ 10000[0-9a-f]{3}: e8 a3 00 00 ld r5,0\(r3\)
-+ 10000[0-9a-f]{3}: 4b ff ff ec b 10000[0-9a-f]{3} <_start\+0x34>
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 38 63 10 00 addi r3,r3,4096
-+ 10000[0-9a-f]{3}: e8 a3 80 04 ld r5,-32764\(r3\)
-
--0+10000140 <\.__tls_get_addr>:
-- 10000140: 4e 80 00 20 blr
-+0+10000[0-9a-f]{3} <\.__tls_get_addr>:
-+ 10000[0-9a-f]{3}: 4e 80 00 20 blr
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsmark32.d
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsmark32.d
-@@ -9,17 +9,17 @@
-
- Disassembly of section \.text:
-
--0+1800094 <_start>:
-- 1800094: 48 00 00 14 b 18000a8 <_start\+0x14>
-- 1800098: 38 63 90 00 addi r3,r3,-28672
-- 180009c: 80 83 00 00 lwz r4,0\(r3\)
-- 18000a0: 3c 62 00 00 addis r3,r2,0
-- 18000a4: 48 00 00 0c b 18000b0 <_start\+0x1c>
-- 18000a8: 3c 62 00 00 addis r3,r2,0
-- 18000ac: 4b ff ff ec b 1800098 <_start\+0x4>
-- 18000b0: 38 63 10 00 addi r3,r3,4096
-- 18000b4: 80 83 80 00 lwz r4,-32768\(r3\)
-+0+18000[0-9a-f]{2} <_start>:
-+ 18000[0-9a-f]{2}: 48 00 00 14 b 18000[0-9a-f]{2} <_start\+0x14>
-+ 18000[0-9a-f]{2}: 38 63 90 00 addi r3,r3,-28672
-+ 18000[0-9a-f]{2}: 80 83 00 00 lwz r4,0\(r3\)
-+ 18000[0-9a-f]{2}: 3c 62 00 00 addis r3,r2,0
-+ 18000[0-9a-f]{2}: 48 00 00 0c b 18000[0-9a-f]{2} <_start\+0x1c>
-+ 18000[0-9a-f]{2}: 3c 62 00 00 addis r3,r2,0
-+ 18000[0-9a-f]{2}: 4b ff ff ec b 18000[0-9a-f]{2} <_start\+0x4>
-+ 18000[0-9a-f]{2}: 38 63 10 00 addi r3,r3,4096
-+ 18000[0-9a-f]{2}: 80 83 80 00 lwz r4,-32768\(r3\)
-
--0+18000b8 <__tls_get_addr>:
-- 18000b8: 4e 80 00 20 blr
--#pass
-\ No newline at end of file
-+0+18000[0-9a-f]{2} <__tls_get_addr>:
-+ 18000[0-9a-f]{2}: 4e 80 00 20 blr
-+#pass
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsopt1.d
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsopt1.d
-@@ -9,17 +9,17 @@
-
- Disassembly of section \.text:
-
--0+100000e8 <\.__tls_get_addr>:
-- 100000e8: 4e 80 00 20 blr
-+0+10000[0-9a-f]{3} <\.__tls_get_addr>:
-+ 10000[0-9a-f]{3}: 4e 80 00 20 blr
-
- Disassembly of section \.no_opt1:
-
--0+100000ec <\.no_opt1>:
-- 100000ec: 38 62 80 08 addi r3,r2,-32760
-- 100000f0: 2c 24 00 00 cmpdi r4,0
-- 100000f4: 41 82 00 10 beq- .*
-- 100000f8: 4b ff ff f1 bl 100000e8 <\.__tls_get_addr>
-- 100000fc: 60 00 00 00 nop
-- 10000100: 48 00 00 0c b .*
-- 10000104: 4b ff ff e5 bl 100000e8 <\.__tls_get_addr>
-- 10000108: 60 00 00 00 nop
-+0+10000[0-9a-f]{3} <\.no_opt1>:
-+ 10000[0-9a-f]{3}: 38 62 80 08 addi r3,r2,-32760
-+ 10000[0-9a-f]{3}: 2c 24 00 00 cmpdi r4,0
-+ 10000[0-9a-f]{3}: 41 82 00 10 beq- .*
-+ 10000[0-9a-f]{3}: 4b ff ff f1 bl 10000[0-9a-f]{3} <\.__tls_get_addr>
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 48 00 00 0c b .*
-+ 10000[0-9a-f]{3}: 4b ff ff e5 bl 10000[0-9a-f]{3} <\.__tls_get_addr>
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsopt1_32.d
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsopt1_32.d
-@@ -9,16 +9,16 @@
-
- Disassembly of section \.text:
-
--0+1800094 <__tls_get_addr>:
-- 1800094: 4e 80 00 20 blr
-+0+18000[0-9a-f]{2} <__tls_get_addr>:
-+ 18000[0-9a-f]{2}: 4e 80 00 20 blr
-
- Disassembly of section \.no_opt1:
-
--0+1800098 <\.no_opt1>:
-- 1800098: 38 6d ff f4 addi r3,r13,-12
-- 180009c: 2c 04 00 00 cmpwi r4,0
-- 18000a0: 41 82 00 0c beq- .*
-- 18000a4: 4b ff ff f1 bl 1800094 <__tls_get_addr>
-- 18000a8: 48 00 00 08 b .*
-- 18000ac: 4b ff ff e9 bl 1800094 <__tls_get_addr>
-+0+18000[0-9a-f]{2} <\.no_opt1>:
-+ 18000[0-9a-f]{2}: 38 6d ff f4 addi r3,r13,-12
-+ 18000[0-9a-f]{2}: 2c 04 00 00 cmpwi r4,0
-+ 18000[0-9a-f]{2}: 41 82 00 0c beq- .*
-+ 18000[0-9a-f]{2}: 4b ff ff f1 bl 18000[0-9a-f]{2} <__tls_get_addr>
-+ 18000[0-9a-f]{2}: 48 00 00 08 b .*
-+ 18000[0-9a-f]{2}: 4b ff ff e9 bl 18000[0-9a-f]{2} <__tls_get_addr>
- #pass
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsopt2.d
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsopt2.d
-@@ -9,15 +9,15 @@
-
- Disassembly of section \.text:
-
--0+100000e8 <\.__tls_get_addr>:
-- 100000e8: 4e 80 00 20 blr
-+0+10000[0-9a-f]{3} <\.__tls_get_addr>:
-+ 10000[0-9a-f]{3}: 4e 80 00 20 blr
-
- Disassembly of section \.no_opt2:
-
--0+100000ec <\.no_opt2>:
-- 100000ec: 38 62 80 08 addi r3,r2,-32760
-- 100000f0: 2c 24 00 00 cmpdi r4,0
-- 100000f4: 41 82 00 08 beq- .*
-- 100000f8: 38 62 80 08 addi r3,r2,-32760
-- 100000fc: 4b ff ff ed bl 100000e8 <\.__tls_get_addr>
-- 10000100: 60 00 00 00 nop
-+0+10000[0-9a-f]{3} <\.no_opt2>:
-+ 10000[0-9a-f]{3}: 38 62 80 08 addi r3,r2,-32760
-+ 10000[0-9a-f]{3}: 2c 24 00 00 cmpdi r4,0
-+ 10000[0-9a-f]{3}: 41 82 00 08 beq- .*
-+ 10000[0-9a-f]{3}: 38 62 80 08 addi r3,r2,-32760
-+ 10000[0-9a-f]{3}: 4b ff ff ed bl 10000[0-9a-f]{3} <\.__tls_get_addr>
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsopt2_32.d
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsopt2_32.d
-@@ -9,15 +9,15 @@
-
- Disassembly of section \.text:
-
--0+1800094 <__tls_get_addr>:
-- 1800094: 4e 80 00 20 blr
-+0+18000[0-9a-f]{2} <__tls_get_addr>:
-+ 18000[0-9a-f]{2}: 4e 80 00 20 blr
-
- Disassembly of section \.no_opt2:
-
--0+1800098 <\.no_opt2>:
-- 1800098: 38 6d ff f4 addi r3,r13,-12
-- 180009c: 2c 04 00 00 cmpwi r4,0
-- 18000a0: 41 82 00 08 beq- .*
-- 18000a4: 38 6d ff f4 addi r3,r13,-12
-- 18000a8: 4b ff ff ed bl 1800094 <__tls_get_addr>
-+0+18000[0-9a-f]{2} <\.no_opt2>:
-+ 18000[0-9a-f]{2}: 38 6d ff f4 addi r3,r13,-12
-+ 18000[0-9a-f]{2}: 2c 04 00 00 cmpwi r4,0
-+ 18000[0-9a-f]{2}: 41 82 00 08 beq- .*
-+ 18000[0-9a-f]{2}: 38 6d ff f4 addi r3,r13,-12
-+ 18000[0-9a-f]{2}: 4b ff ff ed bl 18000[0-9a-f]{2} <__tls_get_addr>
- #pass
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsopt3.d
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsopt3.d
-@@ -9,18 +9,18 @@
-
- Disassembly of section \.text:
-
--00000000100000e8 <\.__tls_get_addr>:
-- 100000e8: 4e 80 00 20 blr
-+0000000010000[0-9a-f]{3} <\.__tls_get_addr>:
-+ 10000[0-9a-f]{3}: 4e 80 00 20 blr
-
- Disassembly of section \.no_opt3:
-
--00000000100000ec <\.no_opt3>:
-- 100000ec: 38 62 80 08 addi r3,r2,-32760
-- 100000f0: 48 00 00 0c b .*
-- 100000f4: 38 62 80 18 addi r3,r2,-32744
-- 100000f8: 48 00 00 10 b .*
-- 100000fc: 4b ff ff ed bl 100000e8 <\.__tls_get_addr>
-- 10000100: 60 00 00 00 nop
-- 10000104: 48 00 00 0c b .*
-- 10000108: 4b ff ff e1 bl 100000e8 <\.__tls_get_addr>
-- 1000010c: 60 00 00 00 nop
-+0000000010000[0-9a-f]{3} <\.no_opt3>:
-+ 10000[0-9a-f]{3}: 38 62 80 08 addi r3,r2,-32760
-+ 10000[0-9a-f]{3}: 48 00 00 0c b .*
-+ 10000[0-9a-f]{3}: 38 62 80 18 addi r3,r2,-32744
-+ 10000[0-9a-f]{3}: 48 00 00 10 b .*
-+ 10000[0-9a-f]{3}: 4b ff ff ed bl 10000[0-9a-f]{3} <\.__tls_get_addr>
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 48 00 00 0c b .*
-+ 10000[0-9a-f]{3}: 4b ff ff e1 bl 10000[0-9a-f]{3} <\.__tls_get_addr>
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsopt3_32.d
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsopt3_32.d
-@@ -9,17 +9,17 @@
-
- Disassembly of section \.text:
-
--0+1800094 <__tls_get_addr>:
-- 1800094: 4e 80 00 20 blr
-+0+18000[0-9a-f]{2} <__tls_get_addr>:
-+ 18000[0-9a-f]{2}: 4e 80 00 20 blr
-
- Disassembly of section \.no_opt3:
-
--0+1800098 <\.no_opt3>:
-- 1800098: 38 6d ff ec addi r3,r13,-20
-- 180009c: 48 00 00 0c b .*
-- 18000a0: 38 6d ff f4 addi r3,r13,-12
-- 18000a4: 48 00 00 0c b .*
-- 18000a8: 4b ff ff ed bl 1800094 <__tls_get_addr>
-- 18000ac: 48 00 00 08 b .*
-- 18000b0: 4b ff ff e5 bl 1800094 <__tls_get_addr>
-+0+18000[0-9a-f]{2} <\.no_opt3>:
-+ 18000[0-9a-f]{2}: 38 6d ff ec addi r3,r13,-20
-+ 18000[0-9a-f]{2}: 48 00 00 0c b .*
-+ 18000[0-9a-f]{2}: 38 6d ff f4 addi r3,r13,-12
-+ 18000[0-9a-f]{2}: 48 00 00 0c b .*
-+ 18000[0-9a-f]{2}: 4b ff ff ed bl 18000[0-9a-f]{2} <__tls_get_addr>
-+ 18000[0-9a-f]{2}: 48 00 00 08 b .*
-+ 18000[0-9a-f]{2}: 4b ff ff e5 bl 18000[0-9a-f]{2} <__tls_get_addr>
- #pass
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsopt4.d
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsopt4.d
-@@ -9,40 +9,40 @@
-
- Disassembly of section \.text:
-
--0+100000e8 <\.__tls_get_addr>:
-- 100000e8: 4e 80 00 20 blr
-+0+10000[0-9a-f]{3} <\.__tls_get_addr>:
-+ 10000[0-9a-f]{3}: 4e 80 00 20 blr
-
- Disassembly of section \.opt1:
-
--0+100000ec <\.opt1>:
-- 100000ec: 3c 6d 00 00 addis r3,r13,0
-- 100000f0: 2c 24 00 00 cmpdi r4,0
-- 100000f4: 41 82 00 10 beq- .*
-- 100000f8: 60 00 00 00 nop
-- 100000fc: 38 63 90 10 addi r3,r3,-28656
-- 10000100: 48 00 00 0c b .*
-- 10000104: 60 00 00 00 nop
-- 10000108: 38 63 90 10 addi r3,r3,-28656
-+0+10000[0-9a-f]{3} <\.opt1>:
-+ 10000[0-9a-f]{3}: 3c 6d 00 00 addis r3,r13,0
-+ 10000[0-9a-f]{3}: 2c 24 00 00 cmpdi r4,0
-+ 10000[0-9a-f]{3}: 41 82 00 10 beq- .*
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 38 63 90 10 addi r3,r3,-28656
-+ 10000[0-9a-f]{3}: 48 00 00 0c b .*
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 38 63 90 10 addi r3,r3,-28656
-
- Disassembly of section \.opt2:
-
--0+1000010c <\.opt2>:
-- 1000010c: 3c 6d 00 00 addis r3,r13,0
-- 10000110: 2c 24 00 00 cmpdi r4,0
-- 10000114: 41 82 00 08 beq- .*
-- 10000118: 3c 6d 00 00 addis r3,r13,0
-- 1000011c: 60 00 00 00 nop
-- 10000120: 38 63 90 10 addi r3,r3,-28656
-+0+10000[0-9a-f]{3} <\.opt2>:
-+ 10000[0-9a-f]{3}: 3c 6d 00 00 addis r3,r13,0
-+ 10000[0-9a-f]{3}: 2c 24 00 00 cmpdi r4,0
-+ 10000[0-9a-f]{3}: 41 82 00 08 beq- .*
-+ 10000[0-9a-f]{3}: 3c 6d 00 00 addis r3,r13,0
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 38 63 90 10 addi r3,r3,-28656
-
- Disassembly of section \.opt3:
-
--0+10000124 <\.opt3>:
-- 10000124: 3c 6d 00 00 addis r3,r13,0
-- 10000128: 48 00 00 0c b .*
-- 1000012c: 3c 6d 00 00 addis r3,r13,0
-- 10000130: 48 00 00 10 b .*
-- 10000134: 60 00 00 00 nop
-- 10000138: 38 63 90 10 addi r3,r3,-28656
-- 1000013c: 48 00 00 0c b .*
-- 10000140: 60 00 00 00 nop
-- 10000144: 38 63 90 08 addi r3,r3,-28664
-+0+10000[0-9a-f]{3} <\.opt3>:
-+ 10000[0-9a-f]{3}: 3c 6d 00 00 addis r3,r13,0
-+ 10000[0-9a-f]{3}: 48 00 00 0c b .*
-+ 10000[0-9a-f]{3}: 3c 6d 00 00 addis r3,r13,0
-+ 10000[0-9a-f]{3}: 48 00 00 10 b .*
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 38 63 90 10 addi r3,r3,-28656
-+ 10000[0-9a-f]{3}: 48 00 00 0c b .*
-+ 10000[0-9a-f]{3}: 60 00 00 00 nop
-+ 10000[0-9a-f]{3}: 38 63 90 08 addi r3,r3,-28664
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsopt4_32.d
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsopt4_32.d
-@@ -9,36 +9,36 @@
-
- Disassembly of section \.text:
-
--0+1800094 <__tls_get_addr>:
-- 1800094: 4e 80 00 20 blr
-+0+18000[0-9a-f]{2} <__tls_get_addr>:
-+ 18000[0-9a-f]{2}: 4e 80 00 20 blr
-
- Disassembly of section \.opt1:
-
--0+1800098 <\.opt1>:
-- 1800098: 3c 62 00 00 addis r3,r2,0
-- 180009c: 2c 04 00 00 cmpwi r4,0
-- 18000a0: 41 82 00 0c beq- .*
-- 18000a4: 38 63 90 10 addi r3,r3,-28656
-- 18000a8: 48 00 00 08 b .*
-- 18000ac: 38 63 90 10 addi r3,r3,-28656
-+0+18000[0-9a-f]{2} <\.opt1>:
-+ 18000[0-9a-f]{2}: 3c 62 00 00 addis r3,r2,0
-+ 18000[0-9a-f]{2}: 2c 04 00 00 cmpwi r4,0
-+ 18000[0-9a-f]{2}: 41 82 00 0c beq- .*
-+ 18000[0-9a-f]{2}: 38 63 90 10 addi r3,r3,-28656
-+ 18000[0-9a-f]{2}: 48 00 00 08 b .*
-+ 18000[0-9a-f]{2}: 38 63 90 10 addi r3,r3,-28656
-
- Disassembly of section \.opt2:
-
--0+18000b0 <\.opt2>:
-- 18000b0: 3c 62 00 00 addis r3,r2,0
-- 18000b4: 2c 04 00 00 cmpwi r4,0
-- 18000b8: 41 82 00 08 beq- .*
-- 18000bc: 3c 62 00 00 addis r3,r2,0
-- 18000c0: 38 63 90 10 addi r3,r3,-28656
-+0+18000[0-9a-f]{2} <\.opt2>:
-+ 18000[0-9a-f]{2}: 3c 62 00 00 addis r3,r2,0
-+ 18000[0-9a-f]{2}: 2c 04 00 00 cmpwi r4,0
-+ 18000[0-9a-f]{2}: 41 82 00 08 beq- .*
-+ 18000[0-9a-f]{2}: 3c 62 00 00 addis r3,r2,0
-+ 18000[0-9a-f]{2}: 38 63 90 10 addi r3,r3,-28656
-
- Disassembly of section \.opt3:
-
--0+18000c4 <\.opt3>:
-- 18000c4: 3c 62 00 00 addis r3,r2,0
-- 18000c8: 48 00 00 0c b .*
-- 18000cc: 3c 62 00 00 addis r3,r2,0
-- 18000d0: 48 00 00 0c b .*
-- 18000d4: 38 63 90 10 addi r3,r3,-28656
-- 18000d8: 48 00 00 08 b .*
-- 18000dc: 38 63 90 08 addi r3,r3,-28664
-+0+18000[0-9a-f]{2} <\.opt3>:
-+ 18000[0-9a-f]{2}: 3c 62 00 00 addis r3,r2,0
-+ 18000[0-9a-f]{2}: 48 00 00 0c b .*
-+ 18000[0-9a-f]{2}: 3c 62 00 00 addis r3,r2,0
-+ 18000[0-9a-f]{2}: 48 00 00 0c b .*
-+ 18000[0-9a-f]{2}: 38 63 90 10 addi r3,r3,-28656
-+ 18000[0-9a-f]{2}: 48 00 00 08 b .*
-+ 18000[0-9a-f]{2}: 38 63 90 08 addi r3,r3,-28664
- #pass
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsso32.d
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsso32.d
-@@ -42,5 +42,5 @@ Disassembly of section \.got:
- .* <\.got>:
- \.\.\.
- .*: 4e 80 00 21 blrl
--.*: 00 01 03 ec .*
-+.*: 00 01 [0-9a-f]{2} [0-9a-f]{2} .*
- \.\.\.
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsso32.g
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsso32.g
-@@ -9,5 +9,5 @@
- Contents of section \.got:
- .* 00000000 00000000 00000000 00000000 .*
- .* 00000000 00000000 00000000 00000000 .*
--.* 00000000 4e800021 000103ec 00000000 .*
-+.* 00000000 4e800021 00010[0-9a-f]{3} 00000000 .*
- .* 00000000 .*
---- binutils-2.22/ld/testsuite/ld-powerpc/tlsso32.r
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlsso32.r
-@@ -35,6 +35,7 @@ Program Headers:
- +LOAD .* RWE 0x10000
- +DYNAMIC .* RW +0x4
- +TLS .* 0x0+1c 0x0+38 R +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- +Segment Sections\.\.\.
-@@ -42,6 +43,7 @@ Program Headers:
- +01 +\.tdata \.dynamic \.got \.plt
- +02 +\.dynamic
- +03 +\.tdata \.tbss
-+ +04 +
-
- Relocation section '\.rela\.dyn' at offset 0x[0-9a-f]+ contains 18 entries:
- Offset +Info +Type +Sym\. Value +Symbol's Name \+ Addend
-@@ -52,9 +54,9 @@ Relocation section '\.rela\.dyn' at offset 0x[0-9a-f]+ contains 18 entries:
- [0-9a-f ]+R_PPC_TPREL16 +0+30 +le0 \+ 0
- [0-9a-f ]+R_PPC_TPREL16_HA +0+34 +le1 \+ 0
- [0-9a-f ]+R_PPC_TPREL16_LO +0+34 +le1 \+ 0
--[0-9a-f ]+R_PPC_TPREL16 +0+103d0 +\.tdata \+ 103e4
--[0-9a-f ]+R_PPC_TPREL16_HA +0+103d0 +\.tdata \+ 103e8
--[0-9a-f ]+R_PPC_TPREL16_LO +0+103d0 +\.tdata \+ 103e8
-+[0-9a-f ]+R_PPC_TPREL16 +0+103[df]0 +\.tdata \+ 10[0-9a-f]{3}
-+[0-9a-f ]+R_PPC_TPREL16_HA +0+103[df]0 +\.tdata \+ 10[0-9a-f]{3}
-+[0-9a-f ]+R_PPC_TPREL16_LO +0+103[df]0 +\.tdata \+ 10[0-9a-f]{3}
- [0-9a-f ]+R_PPC_DTPMOD32 +0+
- [0-9a-f ]+R_PPC_DTPREL32 +0+
- [0-9a-f ]+R_PPC_DTPMOD32 +0+
---- binutils-2.22/ld/testsuite/ld-powerpc/tlstoc.g
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlstoc.g
-@@ -8,8 +8,8 @@
- .*: +file format elf64-powerpc
-
- Contents of section \.got:
-- 100101a0 00000000 00000001 00000000 00000000 .*
-- 100101b0 00000000 00000001 00000000 00000000 .*
-- 100101c0 00000000 00000001 00000000 00000000 .*
-- 100101d0 00000000 00000001 00000000 00000000 .*
-- 100101e0 ffffffff ffff8060 00000000 00000000 .*
-+ 10010[0-9a-f]{3} 00000000 00000001 00000000 00000000 .*
-+ 10010[0-9a-f]{3} 00000000 00000001 00000000 00000000 .*
-+ 10010[0-9a-f]{3} 00000000 00000001 00000000 00000000 .*
-+ 10010[0-9a-f]{3} 00000000 00000001 00000000 00000000 .*
-+ 10010[0-9a-f]{3} ffffffff ffff8060 00000000 00000000 .*
---- binutils-2.22/ld/testsuite/ld-powerpc/tlstoc.t
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlstoc.t
-@@ -8,7 +8,7 @@
- .*: +file format elf64-powerpc
-
- Contents of section \.tdata:
-- 10010148 00c0ffee 00000000 12345678 9abcdef0 .*
-- 10010158 23456789 abcdef01 3456789a bcdef012 .*
-- 10010168 456789ab cdef0123 56789abc def01234 .*
-- 10010178 6789abcd ef012345 789abcde f0123456 .*
-+ 10010180 00c0ffee 00000000 12345678 9abcdef0 .*
-+ 10010190 23456789 abcdef01 3456789a bcdef012 .*
-+ 100101a0 456789ab cdef0123 56789abc def01234 .*
-+ 100101b0 6789abcd ef012345 789abcde f0123456 .*
---- binutils-2.22/ld/testsuite/ld-powerpc/tlstocso.g
-+++ binutils-2.22/ld/testsuite/ld-powerpc/tlstocso.g
-@@ -7,7 +7,7 @@
- .*: +file format elf64-powerpc
-
- Contents of section \.got:
--.* 00000000 000186c0 00000000 00000000 .*
-+.* 00000000 000186f8 00000000 00000000 .*
- .* 00000000 00000000 00000000 00000000 .*
- .* 00000000 00000000 00000000 00000000 .*
- .* 00000000 00000000 00000000 00000000 .*
---- binutils-2.22/ld/testsuite/ld-s390/tlsbin.rd
-+++ binutils-2.22/ld/testsuite/ld-s390/tlsbin.rd
-@@ -36,13 +36,14 @@ There are [0-9]+ program headers, starting at offset [0-9]+
-
- Program Headers:
- +Type +Offset +VirtAddr +PhysAddr +FileSiz +MemSiz +Flg Align
-- +PHDR +0x0+34 0x0+400034 0x0+400034 0x0+c0 0x0+c0 R E 0x4
-- +INTERP +0x0+f4 0x0+4000f4 0x0+4000f4 0x0+11 0x0+11 R +0x1
-+ +PHDR +0x0+34 0x0+400034 0x0+400034 0x0+e0 0x0+e0 R E 0x4
-+ +INTERP +0x0+114 0x0+400114 0x0+400114 0x0+11 0x0+11 R +0x1
- .*Requesting program interpreter.*
- +LOAD .* R E 0x1000
- +LOAD .* RW +0x1000
- +DYNAMIC .* RW +0x4
- +TLS .* 0x0+60 0x0+a0 R +0x20
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- +Segment Sections...
-@@ -52,6 +53,7 @@ Program Headers:
- +03 +.tdata .dynamic .got *
- +04 +.dynamic *
- +05 +.tdata .tbss *
-+ +06 +
-
- Relocation section '.rela.dyn' at offset .* contains 4 entries:
- Offset +Info +Type +Sym.Value +Sym. Name \+ Addend
---- binutils-2.22/ld/testsuite/ld-s390/tlsbin_64.rd
-+++ binutils-2.22/ld/testsuite/ld-s390/tlsbin_64.rd
-@@ -36,13 +36,14 @@ There are [0-9]+ program headers, starting at offset [0-9]+
-
- Program Headers:
- +Type +Offset +VirtAddr +PhysAddr +FileSiz +MemSiz +Flg Align
-- +PHDR +0x0+40 0x0+80000040 0x0+80000040 0x0+150 0x0+150 R E 0x8
-- +INTERP +0x0+190 0x0+80000190 0x0+80000190 0x0+11 0x0+11 R +0x1
-+ +PHDR +0x0+40 0x0+80000040 0x0+80000040 0x0+188 0x0+188 R E 0x8
-+ +INTERP +0x0+1c8 0x0+800001c8 0x0+800001c8 0x0+11 0x0+11 R +0x1
- .*Requesting program interpreter.*
- +LOAD .* R E 0x1000
- +LOAD .* RW +0x1000
- +DYNAMIC .* RW +0x8
- +TLS .* 0x0+60 0x0+a0 R +0x20
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- +Segment Sections...
-@@ -52,6 +53,7 @@ Program Headers:
- +03 +.tdata .dynamic .got *
- +04 +.dynamic *
- +05 +.tdata .tbss *
-+ +06 +
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 4 entries:
- +Offset +Info +Type +Symbol's Value +Symbol's Name \+ Addend
---- binutils-2.22/ld/testsuite/ld-s390/tlspic.rd
-+++ binutils-2.22/ld/testsuite/ld-s390/tlspic.rd
-@@ -39,6 +39,7 @@ Program Headers:
- +LOAD .* RW +0x1000
- +DYNAMIC .* RW +0x4
- +TLS .* 0x0+60 0x0+80 R +0x20
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- +Segment Sections...
-@@ -46,6 +47,7 @@ Program Headers:
- +01 +.tdata .dynamic .got
- +02 +.dynamic
- +03 +.tdata .tbss
-+ +04 +
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 14 entries:
- Offset +Info +Type +Sym.Value +Sym. Name \+ Addend
---- binutils-2.22/ld/testsuite/ld-s390/tlspic_64.rd
-+++ binutils-2.22/ld/testsuite/ld-s390/tlspic_64.rd
-@@ -39,6 +39,7 @@ Program Headers:
- +LOAD .* RW +0x1000
- +DYNAMIC .* RW +0x8
- +TLS .* 0x0+60 0x0+80 R +0x20
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- +Segment Sections...
-@@ -46,6 +47,7 @@ Program Headers:
- +01 +.tdata .dynamic .got *
- +02 +.dynamic *
- +03 +.tdata .tbss *
-+ +04 +
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 14 entries:
- +Offset +Info +Type +Symbol's Value +Symbol's Name \+ Addend
---- binutils-2.22/ld/testsuite/ld-scripts/empty-aligned.d
-+++ binutils-2.22/ld/testsuite/ld-scripts/empty-aligned.d
-@@ -8,7 +8,9 @@
- Program Headers:
- +Type +Offset +VirtAddr +PhysAddr +FileSiz +MemSiz +Flg +Align
- +LOAD +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ [RWE ]+ +0x[0-9a-f]+
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- +Segment Sections\.\.\.
- +00 +.text
-+ +01 +
---- binutils-2.22/ld/testsuite/ld-sh/tlsbin-2.d
-+++ binutils-2.22/ld/testsuite/ld-sh/tlsbin-2.d
-@@ -44,6 +44,7 @@ Program Headers:
- +LOAD.*
- +DYNAMIC.*
- +TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+18 0x0+28 R +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- +Segment Sections\.\.\.
-@@ -53,6 +54,7 @@ Program Headers:
- +03 +\.tdata \.dynamic \.got *
- +04 +\.dynamic *
- +05 +\.tdata \.tbss *
-+ +06 +
-
- Relocation section '\.rela\.dyn' at offset 0x[0-9a-f]+ contains 4 entries:
- Offset +Info +Type +Sym\.Value +Sym\. Name \+ Addend
---- binutils-2.22/ld/testsuite/ld-sh/tlspic-2.d
-+++ binutils-2.22/ld/testsuite/ld-sh/tlspic-2.d
-@@ -32,7 +32,7 @@ Key to Flags:
-
- Elf file type is DYN \(Shared object file\)
- Entry point 0x[0-9a-f]+
--There are 4 program headers, starting at offset [0-9]+
-+There are [0-9] program headers, starting at offset [0-9]+
-
- Program Headers:
- +Type +Offset +VirtAddr +PhysAddr +FileSiz +MemSiz +Flg Align
-@@ -40,6 +40,7 @@ Program Headers:
- +LOAD.*
- +DYNAMIC.*
- +TLS .* 0x0+18 0x0+20 R +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- +Segment Sections\.\.\.
-@@ -47,6 +48,7 @@ Program Headers:
- +01 +\.tdata \.dynamic \.got *
- +02 +\.dynamic *
- +03 +\.tdata \.tbss *
-+ +04 +
-
- Relocation section '\.rela\.dyn' at offset 0x[0-9a-f]+ contains 10 entries:
- Offset +Info +Type +Sym\.Value +Sym\. Name \+ Addend
---- binutils-2.22/ld/testsuite/ld-sparc/gotop32.rd
-+++ binutils-2.22/ld/testsuite/ld-sparc/gotop32.rd
-@@ -31,6 +31,7 @@ Program Headers:
- +LOAD +0x0+ 0x0+ 0x0+ 0x0+2000 0x0+2000 R E 0x10000
- +LOAD +0x0+2000 0x0+12000 0x0+12000 0x0+2000 0x0+2000 RW +0x10000
- +DYNAMIC +0x0+2000 0x0+12000 0x0+12000 0x0+70 0x0+70 RW +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- #...
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 1 entries:
---- binutils-2.22/ld/testsuite/ld-sparc/gotop64.rd
-+++ binutils-2.22/ld/testsuite/ld-sparc/gotop64.rd
-@@ -31,6 +31,7 @@ Program Headers:
- +LOAD +0x0+ 0x0+ 0x0+ 0x0+2000 0x0+2000 R E 0x100000
- +LOAD +0x0+2000 0x0+102000 0x0+102000 0x0+2000 0x0+2000 RW +0x100000
- +DYNAMIC +0x0+2000 0x0+102000 0x0+102000 0x0+e0 0x0+e0 RW +0x8
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- #...
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 1 entries:
---- binutils-2.22/ld/testsuite/ld-sparc/tlssunbin32.rd
-+++ binutils-2.22/ld/testsuite/ld-sparc/tlssunbin32.rd
-@@ -30,13 +30,14 @@ There are [0-9]+ program headers, starting at offset [0-9]+
-
- Program Headers:
- +Type +Offset +VirtAddr +PhysAddr +FileSiz MemSiz +Flg Align
-- +PHDR +0x0+34 0x0+10034 0x0+10034 0x0+c0 0x0+c0 R E 0x4
-- +INTERP +0x0+f4 0x0+100f4 0x0+100f4 0x0+11 0x0+11 R +0x1
-+ +PHDR +0x0+34 0x0+10034 0x0+10034 (0x[0-9a-f]+) \1 R E 0x4
-+ +INTERP +(0x[0-9a-f]+ ){3}0x0+11 0x0+11 R +0x1
- .*Requesting program interpreter.*
- +LOAD .* R E 0x10000
- +LOAD .* RW +0x10000
- +DYNAMIC .* RW +0x4
- +TLS .* 0x0+1060 0x0+10a0 R +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- #...
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 4 entries:
---- binutils-2.22/ld/testsuite/ld-sparc/tlssunbin64.rd
-+++ binutils-2.22/ld/testsuite/ld-sparc/tlssunbin64.rd
-@@ -30,13 +30,14 @@ There are [0-9]+ program headers, starting at offset [0-9]+
-
- Program Headers:
- +Type +Offset +VirtAddr +PhysAddr +FileSiz +MemSiz +Flg Align
-- +PHDR +0x0+40 0x0+100040 0x0+100040 0x0+150 0x0+150 R E 0x8
-- +INTERP +0x0+190 0x0+100190 0x0+100190 0x0+19 0x0+19 R +0x1
-+ +PHDR +0x0+40 0x0+100040 0x0+100040 (0x[0-9a-f]+) \1 R E 0x8
-+ +INTERP +0x0+([0-9a-f]+) (0x0+10+\1) \2 0x0+19 0x0+19 R +0x1
- .*Requesting program interpreter.*
- +LOAD .* R E 0x100000
- +LOAD .* RW +0x100000
- +DYNAMIC .* RW +0x8
- +TLS .* 0x0+60 0x0+a0 R +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- #...
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 4 entries:
---- binutils-2.22/ld/testsuite/ld-sparc/tlssunnopic32.rd
-+++ binutils-2.22/ld/testsuite/ld-sparc/tlssunnopic32.rd
-@@ -32,6 +32,7 @@ Program Headers:
- +LOAD .* RW +0x10000
- +DYNAMIC .* RW +0x4
- +TLS .* 0x0+ 0x0+24 R +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- #...
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 12 entries:
---- binutils-2.22/ld/testsuite/ld-sparc/tlssunnopic64.rd
-+++ binutils-2.22/ld/testsuite/ld-sparc/tlssunnopic64.rd
-@@ -32,6 +32,7 @@ Program Headers:
- +LOAD .* RW +0x100000
- +DYNAMIC .* RW +0x8
- +TLS .* 0x0+ 0x0+24 R +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- #...
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 14 entries:
---- binutils-2.22/ld/testsuite/ld-sparc/tlssunpic32.rd
-+++ binutils-2.22/ld/testsuite/ld-sparc/tlssunpic32.rd
-@@ -36,6 +36,7 @@ Program Headers:
- +LOAD +0x0+2000 0x0+12000 0x0+12000 0x0+184 0x0+184 RWE 0x10000
- +DYNAMIC +0x0+2060 0x0+12060 0x0+12060 0x0+98 0x0+98 RW +0x4
- +TLS +0x0+2000 0x0+12000 0x0+12000 0x0+60 0x0+80 R +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- #...
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 14 entries:
---- binutils-2.22/ld/testsuite/ld-sparc/tlssunpic64.rd
-+++ binutils-2.22/ld/testsuite/ld-sparc/tlssunpic64.rd
-@@ -36,6 +36,7 @@ Program Headers:
- +LOAD +0x0+2000 0x0+102000 0x0+102000 0x0+3a0 0x0+3a0 RWE 0x100000
- +DYNAMIC +0x0+2060 0x0+102060 0x0+102060 0x0+130 0x0+130 RW +0x8
- +TLS +0x0+2000 0x0+102000 0x0+102000 0x0+60 0x0+80 R +0x4
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
- #...
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 14 entries:
---- binutils-2.22/ld/testsuite/ld-x86-64/protected3.d
-+++ binutils-2.22/ld/testsuite/ld-x86-64/protected3.d
-@@ -8,6 +8,6 @@
- Disassembly of section .text:
-
- 0+[a-f0-9]+ <bar>:
--[ ]*[a-f0-9]+: 8b 05 [a-f0-9][a-f0-9] 00 [a-f0-9][a-f0-9] 00 mov 0x[a-f0-9]+\(%rip\),%eax # [a-f0-9]+ <foo>
-+[ ]*[a-f0-9]+: 8b 05 [a-f0-9][a-f0-9] [a-f0-9][a-f0-9] [a-f0-9][a-f0-9] 00 mov 0x[a-f0-9]+\(%rip\),%eax # [a-f0-9]+ <foo>
- [ ]*[a-f0-9]+: c3 retq
- #pass
---- binutils-2.22/ld/testsuite/ld-x86-64/tlsgdesc.rd
-+++ binutils-2.22/ld/testsuite/ld-x86-64/tlsgdesc.rd
-@@ -36,12 +36,14 @@ Program Headers:
- +LOAD.*
- +LOAD.*
- +DYNAMIC.*
-+ +PAX_FLAGS.*
-
- Section to Segment mapping:
- +Segment Sections...
- +00 +.hash .dynsym .dynstr .rela.dyn .rela.plt .plt .text *
- +01 +.dynamic .got .got.plt *
- +02 +.dynamic *
-+ +03 +
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 8 entries:
- +Offset +Info +Type +Symbol's Value +Symbol's Name \+ Addend
---- binutils-2.22/ld/testsuite/ld-x86-64/tlspic.rd
-+++ binutils-2.22/ld/testsuite/ld-x86-64/tlspic.rd
-@@ -40,6 +40,7 @@ Program Headers:
- +LOAD +0x0+11ac 0x0+2011ac 0x0+2011ac 0x0+244 0x0+244 RW +0x200000
- +DYNAMIC +0x0+1210 0x0+201210 0x0+201210 0x0+130 0x0+130 RW +0x8
- +TLS +0x0+11ac 0x0+2011ac 0x0+2011ac 0x0+60 0x0+80 R +0x1
-+ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
-
- Section to Segment mapping:
- +Segment Sections...
-@@ -47,6 +48,7 @@ Program Headers:
- +01 +.tdata .dynamic .got .got.plt *
- +02 +.dynamic *
- +03 +.tdata .tbss *
-+ +04 +
-
- Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 14 entries:
- +Offset +Info +Type +Symbol's Value +Symbol's Name \+ Addend
--- /dev/null
+--- binutils-2.24/bfd/elf-bfd.h
++++ binutils-2.24/bfd/elf-bfd.h
+@@ -1577,6 +1577,9 @@ struct elf_obj_tdata
+ /* Segment flags for the PT_GNU_STACK segment. */
+ unsigned int stack_flags;
+
++ /* Segment flags for the PT_PAX_FLAGS segment. */
++ unsigned int pax_flags;
++
+ /* This is set to TRUE if the object was created by the backend
+ linker. */
+ bfd_boolean linker;
+@@ -1707,6 +1707,7 @@
+ #define elf_eh_frame_hdr(bfd) (elf_tdata(bfd) -> o->eh_frame_hdr)
+ #define elf_linker(bfd) (elf_tdata(bfd) -> o->linker)
+ #define elf_stack_flags(bfd) (elf_tdata(bfd) -> o->stack_flags)
++#define elf_pax_flags(bfd) (elf_tdata(bfd) -> o->pax_flags)
+ #define elf_shstrtab(bfd) (elf_tdata(bfd) -> o->strtab_ptr)
+ #define elf_onesymtab(bfd) (elf_tdata(bfd) -> symtab_section)
+ #define elf_symtab_shndx(bfd) (elf_tdata(bfd) -> symtab_shndx_section)
+--- binutils-2.24/bfd/elf.c
++++ binutils-2.24/bfd/elf.c
+@@ -1158,6 +1158,7 @@ get_segment_type (unsigned int p_type)
+ case PT_GNU_EH_FRAME: pt = "EH_FRAME"; break;
+ case PT_GNU_STACK: pt = "STACK"; break;
+ case PT_GNU_RELRO: pt = "RELRO"; break;
++ case PT_PAX_FLAGS: pt = "PAX_FLAGS"; break;
+ default: pt = NULL; break;
+ }
+ return pt;
+@@ -2477,6 +2478,9 @@ bfd_section_from_phdr (bfd *abfd, Elf_Internal_Phdr *hdr, int hdr_index)
+ case PT_GNU_RELRO:
+ return _bfd_elf_make_section_from_phdr (abfd, hdr, hdr_index, "relro");
+
++ case PT_PAX_FLAGS:
++ return _bfd_elf_make_section_from_phdr (abfd, hdr, hdr_index, "pax_flags");
++
+ default:
+ /* Check for any processor-specific program segment types. */
+ bed = get_elf_backend_data (abfd);
+@@ -3551,6 +3555,11 @@ get_program_header_size (bfd *abfd, struct bfd_link_info *info)
+ ++segs;
+ }
+
++ {
++ /* We need a PT_PAX_FLAGS segment. */
++ ++segs;
++ }
++
+ for (s = abfd->sections; s != NULL; s = s->next)
+ {
+ if ((s->flags & SEC_LOAD) != 0
+@@ -4153,6 +4162,20 @@ _bfd_elf_map_sections_to_segments (bfd *abfd, struct bfd_link_info *info)
+ }
+ }
+
++ {
++ amt = sizeof (struct elf_segment_map);
++ m = bfd_zalloc (abfd, amt);
++ if (m == NULL)
++ goto error_return;
++ m->next = NULL;
++ m->p_type = PT_PAX_FLAGS;
++ m->p_flags = elf_pax_flags (abfd);
++ m->p_flags_valid = 1;
++
++ *pm = m;
++ pm = &m->next;
++ }
++
+ free (sections);
+ elf_tdata (abfd)->segment_map = mfirst;
+ }
+@@ -5417,7 +5440,8 @@ rewrite_elf_program_header (bfd *ibfd, bfd *obfd)
+ 6. PT_TLS segment includes only SHF_TLS sections.
+ 7. SHF_TLS sections are only in PT_TLS or PT_LOAD segments.
+ 8. PT_DYNAMIC should not contain empty sections at the beginning
+- (with the possible exception of .dynamic). */
++ (with the possible exception of .dynamic).
++ 9. PT_PAX_FLAGS segments do not include any sections. */
+ #define IS_SECTION_IN_INPUT_SEGMENT(section, segment, bed) \
+ ((((segment->p_paddr \
+ ? IS_CONTAINED_BY_LMA (section, segment, segment->p_paddr) \
+@@ -5425,6 +5449,7 @@ rewrite_elf_program_header (bfd *ibfd, bfd *obfd)
+ && (section->flags & SEC_ALLOC) != 0) \
+ || IS_NOTE (segment, section)) \
+ && segment->p_type != PT_GNU_STACK \
++ && segment->p_type != PT_PAX_FLAGS \
+ && (segment->p_type != PT_TLS \
+ || (section->flags & SEC_THREAD_LOCAL)) \
+ && (segment->p_type == PT_LOAD \
+--- binutils-2.24/bfd/elflink.c
++++ binutils-2.24/bfd/elflink.c
+@@ -5545,17 +5545,30 @@ bfd_elf_size_dynamic_sections (bfd *output_bfd,
+ && ! (*bed->elf_backend_always_size_sections) (output_bfd, info))
+ return FALSE;
+
++ elf_pax_flags (output_bfd) = PF_NORANDEXEC;
++ if (info->execheap)
++ elf_pax_flags (output_bfd) |= PF_NOMPROTECT;
++ else if (info->noexecheap)
++ elf_pax_flags (output_bfd) |= PF_MPROTECT;
++
+ /* Determine any GNU_STACK segment requirements, after the backend
+ has had a chance to set a default segment size. */
+ if (info->execstack)
+- elf_stack_flags (output_bfd) = PF_R | PF_W | PF_X;
++ {
++ elf_stack_flags (output_bfd) = PF_R | PF_W | PF_X;
++ elf_pax_flags (output_bfd) |= PF_EMUTRAMP;
++ }
+ else if (info->noexecstack)
+- elf_stack_flags (output_bfd) = PF_R | PF_W;
++ {
++ elf_stack_flags (output_bfd) = PF_R | PF_W;
++ elf_pax_flags (output_bfd) |= PF_NOEMUTRAMP;
++ }
+ else
+ {
+ bfd *inputobj;
+ asection *notesec = NULL;
+ int exec = 0;
+
++ elf_pax_flags (output_bfd) |= PF_NOEMUTRAMP;
+ for (inputobj = info->input_bfds;
+ inputobj;
+ inputobj = inputobj->link_next)
+@@ -5567,7 +5581,11 @@ bfd_elf_size_dynamic_sections (bfd *output_bfd,
+ if (s)
+ {
+ if (s->flags & SEC_CODE)
+- exec = PF_X;
++ {
++ elf_pax_flags (output_bfd) &= ~PF_NOEMUTRAMP;
++ elf_pax_flags (output_bfd) |= PF_EMUTRAMP;
++ exec = PF_X;
++ }
+ notesec = s;
+ }
+ else if (bed->default_execstack)
+--- binutils-2.24/binutils/readelf.c
++++ binutils-2.24/binutils/readelf.c
+@@ -2740,6 +2740,7 @@ get_segment_type (unsigned long p_type)
+ return "GNU_EH_FRAME";
+ case PT_GNU_STACK: return "GNU_STACK";
+ case PT_GNU_RELRO: return "GNU_RELRO";
++ case PT_PAX_FLAGS: return "PAX_FLAGS";
+
+ default:
+ if ((p_type >= PT_LOPROC) && (p_type <= PT_HIPROC))
+--- binutils-2.24/include/bfdlink.h
++++ binutils-2.24/include/bfdlink.h
+@@ -322,6 +322,14 @@ struct bfd_link_info
+ /* TRUE if PT_GNU_RELRO segment should be created. */
+ unsigned int relro: 1;
+
++ /* TRUE if PT_PAX_FLAGS segment should be created with PF_NOMPROTECT
++ flags. */
++ unsigned int execheap: 1;
++
++ /* TRUE if PT_PAX_FLAGS segment should be created with PF_MPROTECT
++ flags. */
++ unsigned int noexecheap: 1;
++
+ /* TRUE if .eh_frame_hdr section and PT_GNU_EH_FRAME ELF segment
+ should be created. */
+ unsigned int eh_frame_hdr: 1;
+--- binutils-2.24/include/elf/common.h
++++ binutils-2.24/include/elf/common.h
+@@ -429,6 +429,7 @@
+ #define PT_SUNW_EH_FRAME PT_GNU_EH_FRAME /* Solaris uses the same value */
+ #define PT_GNU_STACK (PT_LOOS + 0x474e551) /* Stack flags */
+ #define PT_GNU_RELRO (PT_LOOS + 0x474e552) /* Read-only after relocation */
++#define PT_PAX_FLAGS (PT_LOOS + 0x5041580) /* PaX flags */
+
+ /* Program segment permissions, in program header p_flags field. */
+
+@@ -439,6 +440,21 @@
+ #define PF_MASKOS 0x0FF00000 /* New value, Oct 4, 1999 Draft */
+ #define PF_MASKPROC 0xF0000000 /* Processor-specific reserved bits */
+
++/* Flags to control PaX behavior. */
++
++#define PF_PAGEEXEC (1 << 4) /* Enable PAGEEXEC */
++#define PF_NOPAGEEXEC (1 << 5) /* Disable PAGEEXEC */
++#define PF_SEGMEXEC (1 << 6) /* Enable SEGMEXEC */
++#define PF_NOSEGMEXEC (1 << 7) /* Disable SEGMEXEC */
++#define PF_MPROTECT (1 << 8) /* Enable MPROTECT */
++#define PF_NOMPROTECT (1 << 9) /* Disable MPROTECT */
++#define PF_RANDEXEC (1 << 10) /* Enable RANDEXEC */
++#define PF_NORANDEXEC (1 << 11) /* Disable RANDEXEC */
++#define PF_EMUTRAMP (1 << 12) /* Enable EMUTRAMP */
++#define PF_NOEMUTRAMP (1 << 13) /* Disable EMUTRAMP */
++#define PF_RANDMMAP (1 << 14) /* Enable RANDMMAP */
++#define PF_NORANDMMAP (1 << 15) /* Disable RANDMMAP */
++
+ /* Values for section header, sh_type field. */
+
+ #define SHT_NULL 0 /* Section header table entry unused */
+--- binutils-2.24/ld/emultempl/elf32.em
++++ binutils-2.24/ld/emultempl/elf32.em
+@@ -2285,6 +2285,16 @@ fragment <<EOF
+ link_info.noexecstack = TRUE;
+ link_info.execstack = FALSE;
+ }
++ else if (strcmp (optarg, "execheap") == 0)
++ {
++ link_info.execheap = TRUE;
++ link_info.noexecheap = FALSE;
++ }
++ else if (strcmp (optarg, "noexecheap") == 0)
++ {
++ link_info.noexecheap = TRUE;
++ link_info.execheap = FALSE;
++ }
+ EOF
+ if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
+ fragment <<EOF
+@@ -2368,6 +2378,8 @@ fragment <<EOF
+ -z defs Report unresolved symbols in object files.\n"));
+ fprintf (file, _("\
+ -z execstack Mark executable as requiring executable stack\n"));
++ fprintf (file, _("\
++ -z execheap Mark executable as requiring executable heap\n"));
+ EOF
+
+ if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
+@@ -2391,6 +2403,8 @@ fragment <<EOF
+ fragment <<EOF
+ fprintf (file, _("\
+ -z noexecstack Mark executable as not requiring executable stack\n"));
++ fprintf (file, _("\
++ -z noexecheap Mark executable as not requiring executable heap\n"));
+ EOF
+ if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
+ fragment <<EOF
+--- binutils-2.24/ld/ldgram.y
++++ binutils-2.24/ld/ldgram.y
+@@ -1119,6 +1119,8 @@ phdr_type:
+ $$ = exp_intop (0x6474e550);
+ else if (strcmp (s, "PT_GNU_STACK") == 0)
+ $$ = exp_intop (0x6474e551);
++ else if (strcmp (s, "PT_PAX_FLAGS") == 0)
++ $$ = exp_intop (0x65041580);
+ else
+ {
+ einfo (_("\
+--- binutils-2.24/ld/testsuite/ld-alpha/tlsbin.rd
++++ binutils-2.24/ld/testsuite/ld-alpha/tlsbin.rd
+@@ -35,13 +35,14 @@ There are [0-9]+ program headers, starting at offset [0-9]+
+
+ Program Headers:
+ Type +Offset +VirtAddr +PhysAddr +FileSiz +MemSiz +Flg Align
+- PHDR +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+150 R E 0x8
++ PHDR +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+188 R E 0x8
+ INTERP +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ R +0x1
+ .*Requesting program interpreter.*
+ LOAD +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ R E 0x10000
+ LOAD +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ RWE 0x10000
+ DYNAMIC +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ RW +0x8
+ TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ R +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ #...
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 3 entries:
+--- binutils-2.24/ld/testsuite/ld-alpha/tlsbinr.rd
++++ binutils-2.24/ld/testsuite/ld-alpha/tlsbinr.rd
+@@ -42,6 +42,7 @@ Program Headers:
+ +LOAD +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ RWE 0x10000
+ +DYNAMIC +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ RW +0x8
+ +TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ R +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ #...
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 2 entries:
+--- binutils-2.24/ld/testsuite/ld-alpha/tlspic.rd
++++ binutils-2.24/ld/testsuite/ld-alpha/tlspic.rd
+@@ -38,6 +38,7 @@ Program Headers:
+ +LOAD +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ RWE 0x10000
+ +DYNAMIC +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ RW +0x8
+ +TLS +0x0+10e0 0x0+110e0 0x0+110e0 0x0+60 0x0+80 R +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ #...
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 7 entries:
+--- binutils-2.24/ld/testsuite/ld-elf/eh1.d
++++ binutils-2.24/ld/testsuite/ld-elf/eh1.d
+@@ -22,11 +22,11 @@ Contents of the .eh_frame section:
+ DW_CFA_nop
+ DW_CFA_nop
+
+-0+0018 0+001c 0+001c FDE cie=0+0000 pc=0+400078..0+400078
+- DW_CFA_advance_loc: 0 to 0+400078
++0+0018 0+001c 0+001c FDE cie=0+0000 pc=([0-9a-f]+)..\1
++ DW_CFA_advance_loc: 0 to [0-9a-f]+
+ DW_CFA_def_cfa_offset: 16
+ DW_CFA_offset: r6 \(rbp\) at cfa-16
+- DW_CFA_advance_loc: 0 to 0+400078
++ DW_CFA_advance_loc: 0 to [0-9a-f]+
+ DW_CFA_def_cfa_register: r6 \(rbp\)
+
+ 0+0038 ZERO terminator
+--- binutils-2.24/ld/testsuite/ld-elf/eh2.d
++++ binutils-2.24/ld/testsuite/ld-elf/eh2.d
+@@ -22,11 +22,11 @@ Contents of the .eh_frame section:
+ DW_CFA_nop
+ DW_CFA_nop
+
+-0+0018 0+001c 0+001c FDE cie=0+0000 pc=0+400078..0+400078
+- DW_CFA_advance_loc: 0 to 0+400078
++0+0018 0+001c 0+001c FDE cie=0+0000 pc=([0-9a-f]+)..\1
++ DW_CFA_advance_loc: 0 to [0-9a-f]+
+ DW_CFA_def_cfa_offset: 16
+ DW_CFA_offset: r6 \(rbp\) at cfa-16
+- DW_CFA_advance_loc: 0 to 0+400078
++ DW_CFA_advance_loc: 0 to [0-9a-f]+
+ DW_CFA_def_cfa_register: r6 \(rbp\)
+
+ 0+0038 ZERO terminator
+--- binutils-2.24/ld/testsuite/ld-elf/eh3.d
++++ binutils-2.24/ld/testsuite/ld-elf/eh3.d
+@@ -22,11 +22,11 @@ Contents of the .eh_frame section:
+ DW_CFA_nop
+ DW_CFA_nop
+
+-0+0018 0+001c 0+001c FDE cie=0+0000 pc=0+400078..0+400078
+- DW_CFA_advance_loc: 0 to 0+400078
++0+0018 0+001c 0+001c FDE cie=0+0000 pc=([0-9a-f]+)..\1
++ DW_CFA_advance_loc: 0 to [0-9a-f]+
+ DW_CFA_def_cfa_offset: 16
+ DW_CFA_offset: r6 \(rbp\) at cfa-16
+- DW_CFA_advance_loc: 0 to 0+400078
++ DW_CFA_advance_loc: 0 to [0-9a-f]+
+ DW_CFA_def_cfa_register: r6 \(rbp\)
+
+ 0+0038 ZERO terminator
+--- binutils-2.24/ld/testsuite/ld-elf/orphan-region.d
++++ binutils-2.24/ld/testsuite/ld-elf/orphan-region.d
+@@ -15,7 +15,9 @@
+ Program Headers:
+ Type.*
+ LOAD[ \t]+0x[0-9a-f]+ 0x0*40000000 0x0*40000000 0x[0-9a-f]+ 0x[0-9a-f]+ RWE 0x[0-9a-f]+
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+
+ Section to Segment mapping:
+ Segment Sections...
+ 00 .text .rodata .moredata *
++ 01 +
+--- binutils-2.24/ld/testsuite/ld-i386/tlsbin.rd
++++ binutils-2.24/ld/testsuite/ld-i386/tlsbin.rd
+@@ -44,6 +44,7 @@ Program Headers:
+ +LOAD.*
+ +DYNAMIC.*
+ +TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+60 0x0+a0 R +0x1000
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+
+ Section to Segment mapping:
+ +Segment Sections...
+@@ -53,6 +54,7 @@ Program Headers:
+ +03 +.tdata .dynamic .got .got.plt *
+ +04 +.dynamic *
+ +05 +.tdata .tbss *
++ +06 +
+
+ Relocation section '.rel.dyn' at offset 0x[0-9a-f]+ contains 9 entries:
+ Offset +Info +Type +Sym.Value +Sym. Name
+--- binutils-2.24/ld/testsuite/ld-i386/tlsbindesc.rd
++++ binutils-2.24/ld/testsuite/ld-i386/tlsbindesc.rd
+@@ -42,6 +42,7 @@ Program Headers:
+ +LOAD.*
+ +DYNAMIC.*
+ +TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+60 0x0+a0 R +0x1000
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+
+ Section to Segment mapping:
+ +Segment Sections...
+@@ -51,6 +52,7 @@ Program Headers:
+ +03 +.tdata .dynamic .got .got.plt *
+ +04 +.dynamic *
+ +05 +.tdata .tbss *
++ +06 +
+
+ Relocation section '.rel.dyn' at offset 0x[0-9a-f]+ contains 9 entries:
+ Offset +Info +Type +Sym.Value +Sym. Name
+--- binutils-2.24/ld/testsuite/ld-i386/tlsdesc.rd
++++ binutils-2.24/ld/testsuite/ld-i386/tlsdesc.rd
+@@ -39,6 +39,7 @@ Program Headers:
+ +LOAD.*
+ +DYNAMIC.*
+ +TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+60 0x0+80 R +0x1
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+
+ Section to Segment mapping:
+ +Segment Sections...
+@@ -46,6 +47,7 @@ Program Headers:
+ +01 +.tdata .dynamic .got .got.plt *
+ +02 +.dynamic *
+ +03 +.tdata .tbss *
++ +04 +
+
+ Relocation section '.rel.dyn' at offset 0x[0-9a-f]+ contains 20 entries:
+ Offset +Info +Type +Sym.Value +Sym. Name
+--- binutils-2.24/ld/testsuite/ld-i386/tlsgdesc.rd
++++ binutils-2.24/ld/testsuite/ld-i386/tlsgdesc.rd
+@@ -36,12 +36,14 @@ Program Headers:
+ +LOAD.*
+ +LOAD.*
+ +DYNAMIC.*
++ +PAX_FLAGS.*
+
+ Section to Segment mapping:
+ +Segment Sections...
+ +00 +.hash .dynsym .dynstr .rel.dyn .rel.plt .plt .text *
+ +01 +.dynamic .got .got.plt *
+ +02 +.dynamic *
++ +03 +
+
+ Relocation section '.rel.dyn' at offset 0x[0-9a-f]+ contains 8 entries:
+ Offset +Info +Type +Sym.Value +Sym. Name
+--- binutils-2.24/ld/testsuite/ld-i386/tlsnopic.rd
++++ binutils-2.24/ld/testsuite/ld-i386/tlsnopic.rd
+@@ -37,6 +37,7 @@ Program Headers:
+ +LOAD.*
+ +DYNAMIC.*
+ +TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+ 0x0+24 R +0x1
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+
+ Section to Segment mapping:
+ +Segment Sections...
+@@ -44,6 +45,7 @@ Program Headers:
+ +01 +.dynamic .got .got.plt *
+ +02 +.dynamic *
+ +03 +.tbss *
++ +04 +
+
+ Relocation section '.rel.dyn' at offset 0x[0-9a-f]+ contains 20 entries:
+ Offset +Info +Type +Sym.Value +Sym. Name
+--- binutils-2.24/ld/testsuite/ld-i386/tlspic.rd
++++ binutils-2.24/ld/testsuite/ld-i386/tlspic.rd
+@@ -40,6 +40,7 @@ Program Headers:
+ +LOAD.*
+ +DYNAMIC.*
+ +TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+60 0x0+80 R +0x1
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+
+ Section to Segment mapping:
+ +Segment Sections...
+@@ -47,6 +48,7 @@ Program Headers:
+ +01 +.tdata .dynamic .got .got.plt *
+ +02 +.dynamic *
+ +03 +.tdata .tbss *
++ +04 +
+
+ Relocation section '.rel.dyn' at offset 0x[0-9a-f]+ contains 26 entries:
+ Offset +Info +Type +Sym.Value +Sym. Name
+--- binutils-2.24/ld/testsuite/ld-ia64/merge1.d
++++ binutils-2.24/ld/testsuite/ld-ia64/merge1.d
+@@ -4,7 +4,7 @@
+ #objdump: -d
+
+ #...
+-0+1e0 <.text>:
++[a-f0-9]+ <.text>:
+ [ ]*[a-f0-9]+: 0b 60 80 02 00 24 \[MMI\] addl r12=32,r1;;
+ [ ]*[a-f0-9]+: c0 c0 04 00 48 00 addl r12=24,r1
+ [ ]*[a-f0-9]+: 00 00 04 00 nop.i 0x0;;
+--- binutils-2.24/ld/testsuite/ld-ia64/merge2.d
++++ binutils-2.24/ld/testsuite/ld-ia64/merge2.d
+@@ -4,7 +4,7 @@
+ #objdump: -d
+
+ #...
+-0+1e0 <.text>:
++[a-f0-9]+ <.text>:
+ [ ]*[a-f0-9]+: 0b 60 80 02 00 24 \[MMI\] addl r12=32,r1;;
+ [ ]*[a-f0-9]+: c0 c0 04 00 48 00 addl r12=24,r1
+ [ ]*[a-f0-9]+: 00 00 04 00 nop.i 0x0;;
+--- binutils-2.24/ld/testsuite/ld-ia64/merge3.d
++++ binutils-2.24/ld/testsuite/ld-ia64/merge3.d
+@@ -4,7 +4,7 @@
+ #objdump: -d
+
+ #...
+-0+210 <.text>:
++[a-f0-9]+ <.text>:
+ [ ]*[a-f0-9]+: 0b 60 80 02 00 24 \[MMI\] addl r12=32,r1;;
+ [ ]*[a-f0-9]+: c0 40 05 00 48 00 addl r12=40,r1
+ [ ]*[a-f0-9]+: 00 00 04 00 nop.i 0x0;;
+--- binutils-2.24/ld/testsuite/ld-ia64/merge4.d
++++ binutils-2.24/ld/testsuite/ld-ia64/merge4.d
+@@ -4,7 +4,7 @@
+ #objdump: -d
+
+ #...
+-0+240 <.text>:
++[a-f0-9]+ <.text>:
+ [ ]*[a-f0-9]+: 0b 60 80 02 00 24 \[MMI\] addl r12=32,r1;;
+ [ ]*[a-f0-9]+: c0 40 05 00 48 00 addl r12=40,r1
+ [ ]*[a-f0-9]+: 00 00 04 00 nop.i 0x0;;
+--- binutils-2.24/ld/testsuite/ld-ia64/merge5.d
++++ binutils-2.24/ld/testsuite/ld-ia64/merge5.d
+@@ -4,7 +4,7 @@
+ #objdump: -d
+
+ #...
+-0+270 <.text>:
++[a-f0-9]+ <.text>:
+ [ ]*[a-f0-9]+: 0b 60 80 02 00 24 \[MMI\] addl r12=32,r1;;
+ [ ]*[a-f0-9]+: c0 40 05 00 48 00 addl r12=40,r1
+ [ ]*[a-f0-9]+: 00 00 04 00 nop.i 0x0;;
+--- binutils-2.24/ld/testsuite/ld-ia64/tlsbin.rd
++++ binutils-2.24/ld/testsuite/ld-ia64/tlsbin.rd
+@@ -36,13 +36,14 @@ There are [0-9]+ program headers, starting at offset [0-9]+
+
+ Program Headers:
+ +Type +Offset +VirtAddr +PhysAddr +FileSiz +MemSiz +Flg Align
+- +PHDR +0x0+40 0x40+40 0x40+40 0x0+188 0x0+188 R E 0x8
+- +INTERP +0x0+1c8 0x40+1c8 0x40+1c8 0x[0-9a-f]+ 0x[0-9a-f]+ R +0x1
++ +PHDR +0x0+40 0x40+40 0x40+40 (0x[0-9a-f]+) \1 R E 0x8
++ +INTERP +0x0+([0-9a-f]+) (0x40+\1) \2 0x[0-9a-f]+ 0x[0-9a-f]+ R +0x1
+ .*Requesting program interpreter.*
+ +LOAD +0x0+ 0x40+ 0x40+ 0x0+1[0-9a-f]+ 0x0+1[0-9a-f]+ R E 0x10000
+ +LOAD +0x0+1[0-9a-f]+ 0x60+1[0-9a-f]+ 0x60+1[0-9a-f]+ 0x0+0[0-9a-f]+ 0x0+0[0-9a-f]+ RW +0x10000
+ +DYNAMIC +0x0+1[0-9a-f]+ 0x60+1[0-9a-f]+ 0x60+1[0-9a-f]+ 0x0+150 0x0+150 RW +0x8
+ +TLS +0x0+1[0-9a-f]+ 0x60+1[0-9a-f]+ 0x60+1[0-9a-f]+ 0x0+60 0x0+a0 R +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ +IA_64_UNWIND .* R +0x8
+ #...
+
+--- binutils-2.24/ld/testsuite/ld-ia64/tlspic.rd
++++ binutils-2.24/ld/testsuite/ld-ia64/tlspic.rd
+@@ -40,6 +40,7 @@ Program Headers:
+ +LOAD +0x0+1[0-9a-f]+ 0x0+11[0-9a-f]+ 0x0+11[0-9a-f]+ 0x0+0[0-9a-f]+ 0x0+0[0-9a-f]+ RW +0x10000
+ +DYNAMIC +0x0+1[0-9a-f]+ 0x0+11[0-9a-f]+ 0x0+11[0-9a-f]+ 0x0+140 0x0+140 RW +0x8
+ +TLS +0x0+1[0-9a-f]+ 0x0+11[0-9a-f]+ 0x0+11[0-9a-f]+ 0x0+60 0x0+80 R +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ +IA_64_UNWIND +0x0+1[0-9a-f]+ 0x0+1[0-9a-f]+ 0x0+1[0-9a-f]+ 0x0+18 0x0+18 R +0x8
+ #...
+
+--- binutils-2.24/ld/testsuite/ld-mips-elf/multi-got-no-shared.d
++++ binutils-2.24/ld/testsuite/ld-mips-elf/multi-got-no-shared.d
+@@ -8,9 +8,9 @@
+ .*: +file format.*
+
+ Disassembly of section \.text:
+-004000b0 <[^>]*> 3c1c0043 lui gp,0x43
+-004000b4 <[^>]*> 279c9ff0 addiu gp,gp,-24592
+-004000b8 <[^>]*> afbc0008 sw gp,8\(sp\)
++004000d0 <[^>]*> 3c1c0043 lui gp,0x43
++004000d4 <[^>]*> 279c9ff0 addiu gp,gp,-24592
++004000d8 <[^>]*> afbc0008 sw gp,8\(sp\)
+ #...
+ 00408d60 <[^>]*> 3c1c0043 lui gp,0x43
+ 00408d64 <[^>]*> 279c2c98 addiu gp,gp,11416
+--- binutils-2.24/ld/testsuite/ld-mips-elf/pic-and-nonpic-3a.sd
++++ binutils-2.24/ld/testsuite/ld-mips-elf/pic-and-nonpic-3a.sd
+@@ -1,7 +1,7 @@
+
+ Elf file type is DYN \(Shared object file\)
+ Entry point .*
+-There are 5 program headers, starting at offset .*
++There are [0-9] program headers, starting at offset .*
+
+ Program Headers:
+ * Type * Offset * VirtAddr * PhysAddr * FileSiz * MemSiz * Flg * Align
+@@ -9,6 +9,7 @@ Program Headers:
+ * LOAD * [^ ]+ * 0x0+00000 * 0x0+00000 [^ ]+ * [^ ]+ * R E * 0x.*
+ * LOAD * [^ ]+ * 0x0+10000 * 0x0+10000 [^ ]+ * [^ ]+ * RW * 0x.*
+ * DYNAMIC * [^ ]+ * 0x0+00400 * 0x0+00400 .*
++ * PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ * NULL * .*
+
+ *Section to Segment mapping:
+@@ -18,3 +19,4 @@ Program Headers:
+ *0*2 * \.data \.got *
+ *0*3 * \.dynamic *
+ *0*4 *
++ *0*5 *
+--- binutils-2.24/ld/testsuite/ld-mips-elf/pic-and-nonpic-3b.sd
++++ binutils-2.24/ld/testsuite/ld-mips-elf/pic-and-nonpic-3b.sd
+@@ -1,7 +1,7 @@
+
+ Elf file type is EXEC \(Executable file\)
+ Entry point 0x44000
+-There are 8 program headers, starting at offset .*
++There are [0-9] program headers, starting at offset .*
+
+ Program Headers:
+ * Type * Offset * VirtAddr * PhysAddr * FileSiz * MemSiz * Flg * Align
+@@ -13,6 +13,7 @@ Program Headers:
+ * LOAD * [^ ]+ * 0x0+80000 * 0x0+80000 [^ ]+ * [^ ]+ * RW * 0x.*
+ * LOAD * [^ ]+ * 0x0+a0000 * 0x0+a0000 [^ ]+ * [^ ]+ * RW * 0x.*
+ * DYNAMIC * [^ ]+ * 0x0+42000 * 0x0+42000 .*
++ * PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ * NULL * .*
+
+ *Section to Segment mapping:
+@@ -25,3 +26,4 @@ Program Headers:
+ *0*5 *\.got \.data *
+ *0*6 *\.dynamic *
+ *0*7 *
++ *0*8 *
+--- binutils-2.24/ld/testsuite/ld-mips-elf/pic-and-nonpic-4b.sd
++++ binutils-2.24/ld/testsuite/ld-mips-elf/pic-and-nonpic-4b.sd
+@@ -1,7 +1,7 @@
+
+ Elf file type is EXEC \(Executable file\)
+ Entry point 0x44000
+-There are 8 program headers, starting at offset .*
++There are [0-9] program headers, starting at offset .*
+
+ Program Headers:
+ * Type * Offset * VirtAddr * PhysAddr * FileSiz * MemSiz * Flg * Align
+@@ -13,6 +13,7 @@ Program Headers:
+ * LOAD * [^ ]+ * 0x0+80000 * 0x0+80000 [^ ]+ * [^ ]+ * RW * 0x.*
+ * LOAD * [^ ]+ * 0x0+a0000 * 0x0+a0000 [^ ]+ * [^ ]+ * RW * 0x.*
+ * DYNAMIC * [^ ]+ * 0x0+42000 * 0x0+42000 .*
++ * PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ * NULL * .*
+
+ *Section to Segment mapping:
+@@ -25,3 +26,4 @@ Program Headers:
+ *0*5 * \.got \.data \.bss *
+ *0*6 * \.dynamic *
+ *0*7 *
++ *0*8 *
+--- binutils-2.24/ld/testsuite/ld-mips-elf/pic-and-nonpic-5b.sd
++++ binutils-2.24/ld/testsuite/ld-mips-elf/pic-and-nonpic-5b.sd
+@@ -1,7 +1,7 @@
+
+ Elf file type is EXEC \(Executable file\)
+ Entry point 0x44000
+-There are 8 program headers, starting at offset .*
++There are [0-9] program headers, starting at offset .*
+
+ Program Headers:
+ * Type * Offset * VirtAddr * PhysAddr * FileSiz * MemSiz * Flg * Align
+@@ -13,6 +13,7 @@ Program Headers:
+ * LOAD * [^ ]+ * 0x0+80000 * 0x0+80000 [^ ]+ * [^ ]+ * RW * 0x.*
+ * LOAD * [^ ]+ * 0x0+a0000 * 0x0+a0000 [^ ]+ * [^ ]+ * RW * 0x.*
+ * DYNAMIC * [^ ]+ * 0x0+42000 * 0x0+42000 .*
++ * PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ * NULL * .*
+
+ *Section to Segment mapping:
+@@ -25,3 +26,4 @@ Program Headers:
+ *0*5 * \.got \.data \.bss *
+ *0*6 * \.dynamic *
+ *0*7 *
++ *0*8 *
+--- binutils-2.24/ld/testsuite/ld-mips-elf/pic-and-nonpic-6-n32.sd
++++ binutils-2.24/ld/testsuite/ld-mips-elf/pic-and-nonpic-6-n32.sd
+@@ -1,7 +1,7 @@
+
+ Elf file type is EXEC \(Executable file\)
+ Entry point 0x44000
+-There are 8 program headers, starting at offset .*
++There are [0-9] program headers, starting at offset .*
+
+ Program Headers:
+ * Type * Offset * VirtAddr * PhysAddr * FileSiz * MemSiz * Flg * Align
+@@ -13,6 +13,7 @@ Program Headers:
+ * LOAD * [^ ]+ * 0x0+80000 * 0x0+80000 [^ ]+ * [^ ]+ * RW * 0x.*
+ * LOAD * [^ ]+ * 0x0+a0000 * 0x0+a0000 [^ ]+ * [^ ]+ * RW * 0x.*
+ * DYNAMIC * [^ ]+ * 0x0+42000 * 0x0+42000 .*
++ * PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ * NULL * .*
+
+ *Section to Segment mapping:
+@@ -25,3 +26,4 @@ Program Headers:
+ *0*5 * \.got \.data \.bss *
+ *0*6 * \.dynamic *
+ *0*7 *
++ *0*8 *
+--- binutils-2.24/ld/testsuite/ld-mips-elf/pic-and-nonpic-6-n64.sd
++++ binutils-2.24/ld/testsuite/ld-mips-elf/pic-and-nonpic-6-n64.sd
+@@ -1,7 +1,7 @@
+
+ Elf file type is EXEC \(Executable file\)
+ Entry point 0x44000
+-There are 7 program headers, starting at offset .*
++There are [0-9] program headers, starting at offset .*
+
+ Program Headers:
+ * Type * Offset * VirtAddr * PhysAddr * FileSiz * MemSiz * Flg * Align
+@@ -12,6 +12,7 @@ Program Headers:
+ * LOAD * [^ ]+ * 0x0+80000 * 0x0+80000 [^ ]+ * [^ ]+ * RW * 0x.*
+ * LOAD * [^ ]+ * 0x0+a0000 * 0x0+a0000 [^ ]+ * [^ ]+ * RW * 0x.*
+ * DYNAMIC * [^ ]+ * 0x0+42000 * 0x0+42000 .*
++ * PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ * NULL * .*
+
+ *Section to Segment mapping:
+@@ -23,3 +24,4 @@ Program Headers:
+ *0*4 * \.got \.data \.bss *
+ *0*5 * \.dynamic *
+ *0*6 *
++ *0*7 *
+--- binutils-2.24/ld/testsuite/ld-mips-elf/pic-and-nonpic-6-o32.sd
++++ binutils-2.24/ld/testsuite/ld-mips-elf/pic-and-nonpic-6-o32.sd
+@@ -1,7 +1,7 @@
+
+ Elf file type is EXEC \(Executable file\)
+ Entry point 0x44000
+-There are 8 program headers, starting at offset .*
++There are [0-9] program headers, starting at offset .*
+
+ Program Headers:
+ * Type * Offset * VirtAddr * PhysAddr * FileSiz * MemSiz * Flg * Align
+@@ -13,6 +13,7 @@ Program Headers:
+ * LOAD * [^ ]+ * 0x0+80000 * 0x0+80000 [^ ]+ * [^ ]+ * RW * 0x.*
+ * LOAD * [^ ]+ * 0x0+a0000 * 0x0+a0000 [^ ]+ * [^ ]+ * RW * 0x.*
+ * DYNAMIC * [^ ]+ * 0x0+42000 * 0x0+42000 .*
++ * PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ * NULL * .*
+
+ *Section to Segment mapping:
+@@ -25,3 +26,4 @@ Program Headers:
+ *0*5 * \.got \.data \.bss *
+ *0*6 * \.dynamic *
+ *0*7 *
++ *0*8 *
+--- binutils-2.24/ld/testsuite/ld-powerpc/tlsexe32.r
++++ binutils-2.24/ld/testsuite/ld-powerpc/tlsexe32.r
+@@ -33,13 +33,14 @@ There are [0-9]+ program headers, starting at offset [0-9]+
+
+ Program Headers:
+ +Type +Offset +VirtAddr +PhysAddr +FileSiz MemSiz +Flg Align
+- +PHDR +0x000034 0x01800034 0x01800034 0x000c0 0x000c0 R E 0x4
+- +INTERP +0x0000f4 0x018000f4 0x018000f4 0x00011 0x00011 R +0x1
++ +PHDR +0x000034 0x01800034 0x01800034 (0x000[0-9a-f]{2}) \1 R E 0x4
++ +INTERP +0x000([0-9a-f]{3}) 0x01800\1 0x01800\1 0x00011 0x00011 R +0x1
+ +\[Requesting program interpreter: .*\]
+ +LOAD .* R E 0x10000
+ +LOAD .* RWE 0x10000
+ +DYNAMIC .* RW +0x4
+ +TLS .* 0x0001c 0x00038 R +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+
+ Section to Segment mapping:
+ +Segment Sections\.\.\.
+@@ -49,6 +50,7 @@ Program Headers:
+ +03 +\.tdata \.dynamic \.got \.plt
+ +04 +\.dynamic
+ +05 +\.tdata \.tbss
++ +06 +
+
+ Relocation section '\.rela\.dyn' at offset .* contains 2 entries:
+ Offset +Info +Type +Sym\. Value +Symbol's Name \+ Addend
+--- binutils-2.24/ld/testsuite/ld-powerpc/tlsso32.r
++++ binutils-2.24/ld/testsuite/ld-powerpc/tlsso32.r
+@@ -35,6 +35,7 @@ Program Headers:
+ +LOAD .* RWE 0x10000
+ +DYNAMIC .* RW +0x4
+ +TLS .* 0x0+1c 0x0+38 R +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+
+ Section to Segment mapping:
+ +Segment Sections\.\.\.
+@@ -42,6 +43,7 @@ Program Headers:
+ +01 +\.tdata \.dynamic \.got \.plt
+ +02 +\.dynamic
+ +03 +\.tdata \.tbss
++ +04 +
+
+ Relocation section '\.rela\.dyn' at offset 0x[0-9a-f]+ contains 18 entries:
+ Offset +Info +Type +Sym\. Value +Symbol's Name \+ Addend
+@@ -52,9 +54,9 @@ Relocation section '\.rela\.dyn' at offset 0x[0-9a-f]+ contains 18 entries:
+ [0-9a-f ]+R_PPC_TPREL16 +0+30 +le0 \+ 0
+ [0-9a-f ]+R_PPC_TPREL16_HA +0+34 +le1 \+ 0
+ [0-9a-f ]+R_PPC_TPREL16_LO +0+34 +le1 \+ 0
+-[0-9a-f ]+R_PPC_TPREL16 +0+103d0 +\.tdata \+ 103e4
+-[0-9a-f ]+R_PPC_TPREL16_HA +0+103d0 +\.tdata \+ 103e8
+-[0-9a-f ]+R_PPC_TPREL16_LO +0+103d0 +\.tdata \+ 103e8
++[0-9a-f ]+R_PPC_TPREL16 +0+103[df]0 +\.tdata \+ 10[0-9a-f]{3}
++[0-9a-f ]+R_PPC_TPREL16_HA +0+103[df]0 +\.tdata \+ 10[0-9a-f]{3}
++[0-9a-f ]+R_PPC_TPREL16_LO +0+103[df]0 +\.tdata \+ 10[0-9a-f]{3}
+ [0-9a-f ]+R_PPC_DTPMOD32 +0
+ [0-9a-f ]+R_PPC_DTPREL32 +0
+ [0-9a-f ]+R_PPC_DTPMOD32 +0
+--- binutils-2.24/ld/testsuite/ld-s390/tlsbin.rd
++++ binutils-2.24/ld/testsuite/ld-s390/tlsbin.rd
+@@ -36,6 +36,7 @@ There are [0-9]+ program headers, starting at offset [0-9]+
+ +LOAD .* RW +0x1000
+ +DYNAMIC .* RW +0x4
+ +TLS .* 0x0+60 0x0+a0 R +0x20
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+
+ Section to Segment mapping:
+ +Segment Sections...
+@@ -52,6 +53,7 @@ Program Headers:
+ +03 +.tdata .dynamic .got *
+ +04 +.dynamic *
+ +05 +.tdata .tbss *
++ +06 +
+
+ Relocation section '.rela.dyn' at offset .* contains 4 entries:
+ Offset +Info +Type +Sym.Value +Sym. Name \+ Addend
+--- binutils-2.24/ld/testsuite/ld-s390/tlsbin_64.rd
++++ binutils-2.24/ld/testsuite/ld-s390/tlsbin_64.rd
+@@ -36,6 +36,7 @@ There are [0-9]+ program headers, starting at offset [0-9]+
+ +LOAD .* RW +0x1000
+ +DYNAMIC .* RW +0x8
+ +TLS .* 0x0+60 0x0+a0 R +0x20
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+
+ Section to Segment mapping:
+ +Segment Sections...
+@@ -52,6 +53,7 @@ Program Headers:
+ +03 +.tdata .dynamic .got *
+ +04 +.dynamic *
+ +05 +.tdata .tbss *
++ +06 +
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 4 entries:
+ +Offset +Info +Type +Symbol's Value +Symbol's Name \+ Addend
+--- binutils-2.24/ld/testsuite/ld-s390/tlspic.rd
++++ binutils-2.24/ld/testsuite/ld-s390/tlspic.rd
+@@ -39,6 +39,7 @@ Program Headers:
+ +LOAD .* RW +0x1000
+ +DYNAMIC .* RW +0x4
+ +TLS .* 0x0+60 0x0+80 R +0x20
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+
+ Section to Segment mapping:
+ +Segment Sections...
+@@ -46,6 +47,7 @@ Program Headers:
+ +01 +.tdata .dynamic .got
+ +02 +.dynamic
+ +03 +.tdata .tbss
++ +04 +
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 14 entries:
+ Offset +Info +Type +Sym.Value +Sym. Name \+ Addend
+--- binutils-2.24/ld/testsuite/ld-s390/tlspic_64.rd
++++ binutils-2.24/ld/testsuite/ld-s390/tlspic_64.rd
+@@ -39,6 +39,7 @@ Program Headers:
+ +LOAD .* RW +0x1000
+ +DYNAMIC .* RW +0x8
+ +TLS .* 0x0+60 0x0+80 R +0x20
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+
+ Section to Segment mapping:
+ +Segment Sections...
+@@ -46,6 +47,7 @@ Program Headers:
+ +01 +.tdata .dynamic .got *
+ +02 +.dynamic *
+ +03 +.tdata .tbss *
++ +04 +
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 14 entries:
+ +Offset +Info +Type +Symbol's Value +Symbol's Name \+ Addend
+--- binutils-2.24/ld/testsuite/ld-sh/tlsbin-2.d
++++ binutils-2.24/ld/testsuite/ld-sh/tlsbin-2.d
+@@ -44,6 +44,7 @@ Program Headers:
+ +LOAD.*
+ +DYNAMIC.*
+ +TLS +0x[0-9a-f]+ 0x[0-9a-f]+ 0x[0-9a-f]+ 0x0+18 0x0+28 R +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+
+ Section to Segment mapping:
+ +Segment Sections\.\.\.
+@@ -53,6 +54,7 @@ Program Headers:
+ +03 +\.tdata \.dynamic \.got *
+ +04 +\.dynamic *
+ +05 +\.tdata \.tbss *
++ +06 +
+
+ Relocation section '\.rela\.dyn' at offset 0x[0-9a-f]+ contains 4 entries:
+ Offset +Info +Type +Sym\.Value +Sym\. Name \+ Addend
+--- binutils-2.24/ld/testsuite/ld-sh/tlspic-2.d
++++ binutils-2.24/ld/testsuite/ld-sh/tlspic-2.d
+@@ -32,7 +32,7 @@ Key to Flags:
+
+ Elf file type is DYN \(Shared object file\)
+ Entry point 0x[0-9a-f]+
+-There are 4 program headers, starting at offset [0-9]+
++There are [0-9] program headers, starting at offset [0-9]+
+
+ Program Headers:
+ +Type +Offset +VirtAddr +PhysAddr +FileSiz +MemSiz +Flg Align
+@@ -40,6 +40,7 @@ Program Headers:
+ +LOAD.*
+ +DYNAMIC.*
+ +TLS .* 0x0+18 0x0+20 R +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+
+ Section to Segment mapping:
+ +Segment Sections\.\.\.
+@@ -47,6 +48,7 @@ Program Headers:
+ +01 +\.tdata \.dynamic \.got *
+ +02 +\.dynamic *
+ +03 +\.tdata \.tbss *
++ +04 +
+
+ Relocation section '\.rela\.dyn' at offset 0x[0-9a-f]+ contains 10 entries:
+ Offset +Info +Type +Sym\.Value +Sym\. Name \+ Addend
+--- binutils-2.24/ld/testsuite/ld-sparc/gotop32.rd
++++ binutils-2.24/ld/testsuite/ld-sparc/gotop32.rd
+@@ -31,6 +31,7 @@ Program Headers:
+ +LOAD +0x0+ 0x0+ 0x0+ 0x0+2000 0x0+2000 R E 0x10000
+ +LOAD +0x0+2000 0x0+12000 0x0+12000 0x0+2000 0x0+2000 RW +0x10000
+ +DYNAMIC +0x0+2000 0x0+12000 0x0+12000 0x0+70 0x0+70 RW +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ #...
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 1 entries:
+--- binutils-2.24/ld/testsuite/ld-sparc/gotop64.rd
++++ binutils-2.24/ld/testsuite/ld-sparc/gotop64.rd
+@@ -31,6 +31,7 @@ Program Headers:
+ +LOAD +0x0+ 0x0+ 0x0+ 0x0+2000 0x0+2000 R E 0x100000
+ +LOAD +0x0+2000 0x0+102000 0x0+102000 0x0+2000 0x0+2000 RW +0x100000
+ +DYNAMIC +0x0+2000 0x0+102000 0x0+102000 0x0+e0 0x0+e0 RW +0x8
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ #...
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 1 entries:
+--- binutils-2.24/ld/testsuite/ld-sparc/tlssunbin32.rd
++++ binutils-2.24/ld/testsuite/ld-sparc/tlssunbin32.rd
+@@ -30,13 +30,14 @@ There are [0-9]+ program headers, starting at offset [0-9]+
+
+ Program Headers:
+ +Type +Offset +VirtAddr +PhysAddr +FileSiz MemSiz +Flg Align
+- +PHDR +0x0+34 0x0+10034 0x0+10034 0x0+c0 0x0+c0 R E 0x4
+- +INTERP +0x0+f4 0x0+100f4 0x0+100f4 0x0+11 0x0+11 R +0x1
++ +PHDR +0x0+34 0x0+10034 0x0+10034 (0x[0-9a-f]+) \1 R E 0x4
++ +INTERP +(0x[0-9a-f]+ ){3}0x0+11 0x0+11 R +0x1
+ .*Requesting program interpreter.*
+ +LOAD .* R E 0x10000
+ +LOAD .* RW +0x10000
+ +DYNAMIC .* RW +0x4
+ +TLS .* 0x0+1060 0x0+10a0 R +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ #...
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 4 entries:
+--- binutils-2.24/ld/testsuite/ld-sparc/tlssunbin64.rd
++++ binutils-2.24/ld/testsuite/ld-sparc/tlssunbin64.rd
+@@ -30,13 +30,14 @@ There are [0-9]+ program headers, starting at offset [0-9]+
+
+ Program Headers:
+ +Type +Offset +VirtAddr +PhysAddr +FileSiz +MemSiz +Flg Align
+- +PHDR +0x0+40 0x0+100040 0x0+100040 0x0+150 0x0+150 R E 0x8
+- +INTERP +0x0+190 0x0+100190 0x0+100190 0x0+19 0x0+19 R +0x1
++ +PHDR +0x0+40 0x0+100040 0x0+100040 (0x[0-9a-f]+) \1 R E 0x8
++ +INTERP +0x0+([0-9a-f]+) (0x0+10+\1) \2 0x0+19 0x0+19 R +0x1
+ .*Requesting program interpreter.*
+ +LOAD .* R E 0x100000
+ +LOAD .* RW +0x100000
+ +DYNAMIC .* RW +0x8
+ +TLS .* 0x0+60 0x0+a0 R +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ #...
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 4 entries:
+--- binutils-2.24/ld/testsuite/ld-sparc/tlssunnopic32.rd
++++ binutils-2.24/ld/testsuite/ld-sparc/tlssunnopic32.rd
+@@ -32,6 +32,7 @@ Program Headers:
+ +LOAD .* RW +0x10000
+ +DYNAMIC .* RW +0x4
+ +TLS .* 0x0+ 0x0+24 R +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ #...
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 12 entries:
+--- binutils-2.24/ld/testsuite/ld-sparc/tlssunnopic64.rd
++++ binutils-2.24/ld/testsuite/ld-sparc/tlssunnopic64.rd
+@@ -32,6 +32,7 @@ Program Headers:
+ +LOAD .* RW +0x100000
+ +DYNAMIC .* RW +0x8
+ +TLS .* 0x0+ 0x0+24 R +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ #...
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 14 entries:
+--- binutils-2.24/ld/testsuite/ld-sparc/tlssunpic32.rd
++++ binutils-2.24/ld/testsuite/ld-sparc/tlssunpic32.rd
+@@ -36,6 +36,7 @@ Program Headers:
+ +LOAD +0x0+2000 0x0+12000 0x0+12000 0x0+184 0x0+184 RWE 0x10000
+ +DYNAMIC +0x0+2060 0x0+12060 0x0+12060 0x0+98 0x0+98 RW +0x4
+ +TLS +0x0+2000 0x0+12000 0x0+12000 0x0+60 0x0+80 R +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ #...
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 14 entries:
+--- binutils-2.24/ld/testsuite/ld-sparc/tlssunpic64.rd
++++ binutils-2.24/ld/testsuite/ld-sparc/tlssunpic64.rd
+@@ -36,6 +36,7 @@ Program Headers:
+ +LOAD +0x0+2000 0x0+102000 0x0+102000 0x0+3a0 0x0+3a0 RWE 0x100000
+ +DYNAMIC +0x0+2060 0x0+102060 0x0+102060 0x0+130 0x0+130 RW +0x8
+ +TLS +0x0+2000 0x0+102000 0x0+102000 0x0+60 0x0+80 R +0x4
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+ #...
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 14 entries:
+--- binutils-2.24/ld/testsuite/ld-x86-64/tlsgdesc.rd
++++ binutils-2.24/ld/testsuite/ld-x86-64/tlsgdesc.rd
+@@ -36,12 +36,14 @@ Program Headers:
+ +LOAD.*
+ +LOAD.*
+ +DYNAMIC.*
++ +PAX_FLAGS.*
+
+ Section to Segment mapping:
+ +Segment Sections...
+ +00 +.hash .dynsym .dynstr .rela.dyn .rela.plt .plt .text *
+ +01 +.dynamic .got .got.plt *
+ +02 +.dynamic *
++ +03 +
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 8 entries:
+ +Offset +Info +Type +Symbol's Value +Symbol's Name \+ Addend
+--- binutils-2.24/ld/testsuite/ld-x86-64/tlspic.rd
++++ binutils-2.24/ld/testsuite/ld-x86-64/tlspic.rd
+@@ -40,6 +40,7 @@ Program Headers:
+ +LOAD +0x0+131a 0x0+20131a 0x0+20131a 0x0+246 0x0+246 RW +0x200000
+ +DYNAMIC +0x0+1380 0x0+201380 0x0+201380 0x0+130 0x0+130 RW +0x8
+ +TLS +0x0+131a 0x0+20131a 0x0+20131a 0x0+60 0x0+80 R +0x1
++ +PAX_FLAGS +0x0+ 0x0+ 0x0+ 0x0+ 0x0+ +0x[48]
+
+ Section to Segment mapping:
+ +Segment Sections...
+@@ -47,6 +48,7 @@ Program Headers:
+ +01 +.tdata .dynamic .got .got.plt *
+ +02 +.dynamic *
+ +03 +.tdata .tbss *
++ +04 +
+
+ Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains 14 entries:
+ +Offset +Info +Type +Symbol's Value +Symbol's Name \+ Addend
--- /dev/null
+From fa14bec83b2db010fd076910fddab56957b9375d Mon Sep 17 00:00:00 2001
+From: Simon Kelley <simon@thekelleys.org.uk>
+Date: Sun, 20 Dec 2015 17:12:16 +0000
+Subject: [PATCH] Major tidy up of EDNS0 handling and computation/use of udp
+ packet size.
+
+---
+ src/auth.c | 8 ++-
+ src/dnsmasq.h | 7 ++-
+ src/dnssec.c | 1 -
+ src/forward.c | 184 ++++++++++++++++++++++++++++++++++++++++----------------
+ src/netlink.c | 3 +-
+ src/rfc1035.c | 81 +++++++------------------
+ src/rrfilter.c | 2 +-
+ 7 files changed, 168 insertions(+), 118 deletions(-)
+
+diff --git a/src/auth.c b/src/auth.c
+index 2b0b7d6..85bd5e7 100644
+--- a/src/auth.c
++++ b/src/auth.c
+@@ -81,7 +81,8 @@ int in_zone(struct auth_zone *zone, char *name, char **cut)
+ }
+
+
+-size_t answer_auth(struct dns_header *header, char *limit, size_t qlen, time_t now, union mysockaddr *peer_addr, int local_query)
++size_t answer_auth(struct dns_header *header, char *limit, size_t qlen, time_t now, union mysockaddr *peer_addr,
++ int local_query, int do_bit, int have_pseudoheader)
+ {
+ char *name = daemon->namebuff;
+ unsigned char *p, *ansp;
+@@ -820,6 +821,11 @@ size_t answer_auth(struct dns_header *header, char *limit, size_t qlen, time_t n
+ header->ancount = htons(anscount);
+ header->nscount = htons(authcount);
+ header->arcount = htons(0);
++
++ /* Advertise our packet size limit in our reply */
++ if (have_pseudoheader)
++ return add_pseudoheader(header, ansp - (unsigned char *)header, (unsigned char *)limit, daemon->edns_pktsz, 0, NULL, 0, do_bit);
++
+ return ansp - (unsigned char *)header;
+ }
+
+diff --git a/src/dnsmasq.h b/src/dnsmasq.h
+index 39a930c..abb34c5 100644
+--- a/src/dnsmasq.h
++++ b/src/dnsmasq.h
+@@ -1113,7 +1113,7 @@ int extract_addresses(struct dns_header *header, size_t qlen, char *namebuff,
+ int no_cache, int secure, int *doctored);
+ size_t answer_request(struct dns_header *header, char *limit, size_t qlen,
+ struct in_addr local_addr, struct in_addr local_netmask,
+- time_t now, int *ad_reqd, int *do_bit);
++ time_t now, int ad_reqd, int do_bit, int have_pseudoheader);
+ int check_for_bogus_wildcard(struct dns_header *header, size_t qlen, char *name,
+ struct bogus_addr *addr, time_t now);
+ int check_for_ignored_address(struct dns_header *header, size_t qlen, struct bogus_addr *baddr);
+@@ -1123,6 +1123,8 @@ int check_for_local_domain(char *name, time_t now);
+ unsigned int questions_crc(struct dns_header *header, size_t plen, char *buff);
+ size_t resize_packet(struct dns_header *header, size_t plen,
+ unsigned char *pheader, size_t hlen);
++size_t add_pseudoheader(struct dns_header *header, size_t plen, unsigned char *limit,
++ unsigned short udp_sz, int optno, unsigned char *opt, size_t optlen, int set_do);
+ size_t add_mac(struct dns_header *header, size_t plen, char *limit, union mysockaddr *l3);
+ size_t add_source_addr(struct dns_header *header, size_t plen, char *limit, union mysockaddr *source);
+ #ifdef HAVE_DNSSEC
+@@ -1141,7 +1143,8 @@ int private_net(struct in_addr addr, int ban_localhost);
+ /* auth.c */
+ #ifdef HAVE_AUTH
+ size_t answer_auth(struct dns_header *header, char *limit, size_t qlen,
+- time_t now, union mysockaddr *peer_addr, int local_query);
++ time_t now, union mysockaddr *peer_addr, int local_query,
++ int do_bit, int have_pseudoheader);
+ int in_zone(struct auth_zone *zone, char *name, char **cut);
+ #endif
+
+diff --git a/src/dnssec.c b/src/dnssec.c
+index 82394ee..299ca64 100644
+--- a/src/dnssec.c
++++ b/src/dnssec.c
+@@ -67,7 +67,6 @@ static char *algo_digest_name(int algo)
+ case 12: return "gosthash94";
+ case 13: return "sha256";
+ case 14: return "sha384";
+-
+ default: return NULL;
+ }
+ }
+diff --git a/src/forward.c b/src/forward.c
+index 3e801c8..041353c 100644
+--- a/src/forward.c
++++ b/src/forward.c
+@@ -244,7 +244,6 @@ static int forward_query(int udpfd, union mysockaddr *udpaddr,
+ void *hash = &crc;
+ #endif
+ unsigned int gotname = extract_request(header, plen, daemon->namebuff, NULL);
+- unsigned char *pheader;
+
+ (void)do_bit;
+
+@@ -264,7 +263,8 @@ static int forward_query(int udpfd, union mysockaddr *udpaddr,
+ there's no point retrying the query, retry the key query instead...... */
+ if (forward->blocking_query)
+ {
+- int fd;
++ int fd, is_sign;
++ unsigned char *pheader;
+
+ forward->flags &= ~FREC_TEST_PKTSZ;
+
+@@ -276,8 +276,8 @@ static int forward_query(int udpfd, union mysockaddr *udpaddr,
+ blockdata_retrieve(forward->stash, forward->stash_len, (void *)header);
+ plen = forward->stash_len;
+
+- if (find_pseudoheader(header, plen, NULL, &pheader, NULL))
+- PUTSHORT((forward->flags & FREC_TEST_PKTSZ) ? SAFE_PKTSZ : forward->sentto->edns_pktsz, pheader);
++ if (find_pseudoheader(header, plen, NULL, &pheader, &is_sign) && !is_sign)
++ PUTSHORT(SAFE_PKTSZ, pheader);
+
+ if (forward->sentto->addr.sa.sa_family == AF_INET)
+ log_query(F_NOEXTRA | F_DNSSEC | F_IPV4, "retry", (struct all_addr *)&forward->sentto->addr.in.sin_addr, "dnssec");
+@@ -394,32 +394,40 @@ static int forward_query(int udpfd, union mysockaddr *udpaddr,
+ forward->log_id = daemon->log_id;
+
+ if (option_bool(OPT_ADD_MAC))
+- plen = add_mac(header, plen, ((char *) header) + daemon->packet_buff_sz, &forward->source);
+-
++ {
++ size_t new = add_mac(header, plen, ((char *) header) + daemon->packet_buff_sz, &forward->source);
++ if (new != plen)
++ {
++ plen = new;
++ forward->flags |= FREC_ADDED_PHEADER;
++ }
++ }
++
+ if (option_bool(OPT_CLIENT_SUBNET))
+ {
+ size_t new = add_source_addr(header, plen, ((char *) header) + daemon->packet_buff_sz, &forward->source);
+ if (new != plen)
+ {
+ plen = new;
+- forward->flags |= FREC_HAS_SUBNET;
++ forward->flags |= FREC_HAS_SUBNET | FREC_ADDED_PHEADER;
+ }
+ }
+
+ #ifdef HAVE_DNSSEC
+ if (option_bool(OPT_DNSSEC_VALID))
+ {
+- size_t new_plen = add_do_bit(header, plen, ((char *) header) + daemon->packet_buff_sz);
++ size_t new = add_do_bit(header, plen, ((char *) header) + daemon->packet_buff_sz);
+
++ if (new != plen)
++ forward->flags |= FREC_ADDED_PHEADER;
++
++ plen = new;
++
+ /* For debugging, set Checking Disabled, otherwise, have the upstream check too,
+ this allows it to select auth servers when one is returning bad data. */
+ if (option_bool(OPT_DNSSEC_DEBUG))
+ header->hb4 |= HB4_CD;
+
+- if (new_plen != plen)
+- forward->flags |= FREC_ADDED_PHEADER;
+-
+- plen = new_plen;
+ }
+ #endif
+
+@@ -469,10 +477,23 @@ static int forward_query(int udpfd, union mysockaddr *udpaddr,
+ }
+ #endif
+ }
+-
+- if (find_pseudoheader(header, plen, NULL, &pheader, NULL))
+- PUTSHORT((forward->flags & FREC_TEST_PKTSZ) ? SAFE_PKTSZ : start->edns_pktsz, pheader);
+
++#ifdef HAVE_DNSSEC
++ if (option_bool(OPT_DNSSEC_VALID) && !do_bit)
++ {
++ /* Difficult one here. If our client didn't send EDNS0, we will have set the UDP
++ packet size to 512. But that won't provide space for the RRSIGS in many cases.
++ The RRSIGS will be stripped out before the answer goes back, so the packet should
++ shrink again. So, if we added a do-bit, bump the udp packet size to the value
++ known to be OK for this server. Maybe check returned size after stripping and set
++ the truncated bit? */
++ unsigned char *pheader;
++ int is_sign;
++ if (find_pseudoheader(header, plen, NULL, &pheader, &is_sign))
++ PUTSHORT(start->edns_pktsz, pheader);
++ }
++#endif
++
+ if (retry_send(sendto(fd, (char *)header, plen, 0,
+ &start->addr.sa,
+ sa_len(&start->addr))))
+@@ -563,30 +584,34 @@ static size_t process_reply(struct dns_header *header, time_t now, struct server
+ }
+ #endif
+
+- /* If upstream is advertising a larger UDP packet size
+- than we allow, trim it so that we don't get overlarge
+- requests for the client. We can't do this for signed packets. */
+-
+ if ((pheader = find_pseudoheader(header, n, &plen, &sizep, &is_sign)))
+ {
+- unsigned short udpsz;
+- unsigned char *psave = sizep;
+-
+- GETSHORT(udpsz, sizep);
+-
+- if (!is_sign && udpsz > daemon->edns_pktsz)
+- PUTSHORT(daemon->edns_pktsz, psave);
+-
+ if (check_subnet && !check_source(header, plen, pheader, query_source))
+ {
+ my_syslog(LOG_WARNING, _("discarding DNS reply: subnet option mismatch"));
+ return 0;
+ }
+
+- if (added_pheader)
++ if (!is_sign)
+ {
+- pheader = 0;
+- header->arcount = htons(0);
++ if (added_pheader)
++ {
++ /* client didn't send EDNS0, we added one, strip it off before returning answer. */
++ n = rrfilter(header, n, 0);
++ pheader = NULL;
++ }
++ else
++ {
++ /* If upstream is advertising a larger UDP packet size
++ than we allow, trim it so that we don't get overlarge
++ requests for the client. We can't do this for signed packets. */
++ unsigned short udpsz;
++ unsigned char *psave = sizep;
++
++ GETSHORT(udpsz, sizep);
++ if (udpsz > daemon->edns_pktsz)
++ PUTSHORT(daemon->edns_pktsz, psave);
++ }
+ }
+ }
+
+@@ -655,14 +680,16 @@ static size_t process_reply(struct dns_header *header, time_t now, struct server
+ }
+
+ if (option_bool(OPT_DNSSEC_VALID))
+- header->hb4 &= ~HB4_AD;
+-
+- if (!(header->hb4 & HB4_CD) && ad_reqd && cache_secure)
+- header->hb4 |= HB4_AD;
+-
+- /* If the requestor didn't set the DO bit, don't return DNSSEC info. */
+- if (!do_bit)
+- n = rrfilter(header, n, 1);
++ {
++ header->hb4 &= ~HB4_AD;
++
++ if (!(header->hb4 & HB4_CD) && ad_reqd && cache_secure)
++ header->hb4 |= HB4_AD;
++
++ /* If the requestor didn't set the DO bit, don't return DNSSEC info. */
++ if (!do_bit)
++ n = rrfilter(header, n, 1);
++ }
+ #endif
+
+ /* do this after extract_addresses. Ensure NODATA reply and remove
+@@ -761,8 +788,14 @@ void reply_query(int fd, int family, time_t now)
+ if ((nn = resize_packet(header, (size_t)n, pheader, plen)))
+ {
+ header->hb3 &= ~(HB3_QR | HB3_AA | HB3_TC);
+- header->hb4 &= ~(HB4_RA | HB4_RCODE);
+- forward_query(-1, NULL, NULL, 0, header, nn, now, forward, 0, 0);
++ header->hb4 &= ~(HB4_RA | HB4_RCODE | HB4_CD | HB4_AD);
++ if (forward->flags |= FREC_CHECKING_DISABLED)
++ header->hb4 |= HB4_CD;
++ if (forward->flags |= FREC_AD_QUESTION)
++ header->hb4 |= HB4_AD;
++ if (forward->flags & FREC_DO_QUESTION)
++ add_do_bit(header, nn, (char *)pheader + plen);
++ forward_query(-1, NULL, NULL, 0, header, nn, now, forward, forward->flags & FREC_AD_QUESTION, forward->flags & FREC_DO_QUESTION);
+ return;
+ }
+ }
+@@ -1007,12 +1040,13 @@ void receive_query(struct listener *listen, time_t now)
+ {
+ struct dns_header *header = (struct dns_header *)daemon->packet;
+ union mysockaddr source_addr;
+- unsigned short type;
++ unsigned char *pheader;
++ unsigned short type, udp_size = PACKETSZ; /* default if no EDNS0 */
+ struct all_addr dst_addr;
+ struct in_addr netmask, dst_addr_4;
+ size_t m;
+ ssize_t n;
+- int if_index = 0, auth_dns = 0;
++ int if_index = 0, auth_dns = 0, do_bit = 0, have_pseudoheader = 0;
+ #ifdef HAVE_AUTH
+ int local_auth = 0;
+ #endif
+@@ -1279,10 +1313,30 @@ void receive_query(struct listener *listen, time_t now)
+ #endif
+ }
+
++ if (find_pseudoheader(header, (size_t)n, NULL, &pheader, NULL))
++ {
++ unsigned short flags;
++
++ have_pseudoheader = 1;
++ GETSHORT(udp_size, pheader);
++ pheader += 2; /* ext_rcode */
++ GETSHORT(flags, pheader);
++
++ if (flags & 0x8000)
++ do_bit = 1;/* do bit */
++
++ /* If the client provides an EDNS0 UDP size, use that to limit our reply.
++ (bounded by the maximum configured). If no EDNS0, then it
++ defaults to 512 */
++ if (udp_size > daemon->edns_pktsz)
++ udp_size = daemon->edns_pktsz;
++ }
++
+ #ifdef HAVE_AUTH
+ if (auth_dns)
+ {
+- m = answer_auth(header, ((char *) header) + daemon->packet_buff_sz, (size_t)n, now, &source_addr, local_auth);
++ m = answer_auth(header, ((char *) header) + udp_size, (size_t)n, now, &source_addr,
++ local_auth, do_bit, have_pseudoheader);
+ if (m >= 1)
+ {
+ send_from(listen->fd, option_bool(OPT_NOWILD) || option_bool(OPT_CLEVERBIND),
+@@ -1293,9 +1347,13 @@ void receive_query(struct listener *listen, time_t now)
+ else
+ #endif
+ {
+- int ad_reqd, do_bit;
+- m = answer_request(header, ((char *) header) + daemon->packet_buff_sz, (size_t)n,
+- dst_addr_4, netmask, now, &ad_reqd, &do_bit);
++ int ad_reqd = do_bit;
++ /* RFC 6840 5.7 */
++ if (header->hb4 & HB4_AD)
++ ad_reqd = 1;
++
++ m = answer_request(header, ((char *) header) + udp_size, (size_t)n,
++ dst_addr_4, netmask, now, ad_reqd, do_bit, have_pseudoheader);
+
+ if (m >= 1)
+ {
+@@ -1397,7 +1455,7 @@ unsigned char *tcp_request(int confd, time_t now,
+ #ifdef HAVE_AUTH
+ int local_auth = 0;
+ #endif
+- int checking_disabled, ad_question, do_bit, added_pheader = 0;
++ int checking_disabled, do_bit, added_pheader = 0, have_pseudoheader = 0;
+ int check_subnet, no_cache_dnssec = 0, cache_secure = 0, bogusanswer = 0;
+ size_t m;
+ unsigned short qtype;
+@@ -1414,6 +1472,7 @@ unsigned char *tcp_request(int confd, time_t now,
+ union mysockaddr peer_addr;
+ socklen_t peer_len = sizeof(union mysockaddr);
+ int query_count = 0;
++ unsigned char *pheader;
+
+ if (getpeername(confd, (struct sockaddr *)&peer_addr, &peer_len) == -1)
+ return packet;
+@@ -1508,15 +1567,35 @@ unsigned char *tcp_request(int confd, time_t now,
+ else
+ dst_addr_4.s_addr = 0;
+
++ do_bit = 0;
++
++ if (find_pseudoheader(header, (size_t)size, NULL, &pheader, NULL))
++ {
++ unsigned short flags;
++
++ have_pseudoheader = 1;
++ pheader += 4; /* udp_size, ext_rcode */
++ GETSHORT(flags, pheader);
++
++ if (flags & 0x8000)
++ do_bit = 1;/* do bit */
++ }
++
+ #ifdef HAVE_AUTH
+ if (auth_dns)
+- m = answer_auth(header, ((char *) header) + 65536, (size_t)size, now, &peer_addr, local_auth);
++ m = answer_auth(header, ((char *) header) + 65536, (size_t)size, now, &peer_addr,
++ local_auth, do_bit, have_pseudoheader);
+ else
+ #endif
+ {
+- /* m > 0 if answered from cache */
+- m = answer_request(header, ((char *) header) + 65536, (size_t)size,
+- dst_addr_4, netmask, now, &ad_question, &do_bit);
++ int ad_reqd = do_bit;
++ /* RFC 6840 5.7 */
++ if (header->hb4 & HB4_AD)
++ ad_reqd = 1;
++
++ /* m > 0 if answered from cache */
++ m = answer_request(header, ((char *) header) + 65536, (size_t)size,
++ dst_addr_4, netmask, now, ad_reqd, do_bit, have_pseudoheader);
+
+ /* Do this by steam now we're not in the select() loop */
+ check_log_writer(1);
+@@ -1615,6 +1694,7 @@ unsigned char *tcp_request(int confd, time_t now,
+ }
+
+ #ifdef HAVE_DNSSEC
++ added_pheader = 0;
+ if (option_bool(OPT_DNSSEC_VALID))
+ {
+ size_t new_size = add_do_bit(header, size, ((char *) header) + 65536);
+@@ -1719,7 +1799,7 @@ unsigned char *tcp_request(int confd, time_t now,
+
+ m = process_reply(header, now, last_server, (unsigned int)m,
+ option_bool(OPT_NO_REBIND) && !norebind, no_cache_dnssec, cache_secure, bogusanswer,
+- ad_question, do_bit, added_pheader, check_subnet, &peer_addr);
++ ad_reqd, do_bit, added_pheader, check_subnet, &peer_addr);
+
+ break;
+ }
+diff --git a/src/netlink.c b/src/netlink.c
+index 753784d..3376d68 100644
+--- a/src/netlink.c
++++ b/src/netlink.c
+@@ -288,7 +288,8 @@ int iface_enumerate(int family, void *parm, int (*callback)())
+ rta = RTA_NEXT(rta, len1);
+ }
+
+- if (inaddr && mac && callback_ok)
++ if (!(neigh->ndm_state & (NUD_NOARP | NUD_INCOMPLETE | NUD_FAILED)) &&
++ inaddr && mac && callback_ok)
+ if (!((*callback)(neigh->ndm_family, inaddr, mac, maclen, parm)))
+ callback_ok = 0;
+ }
+diff --git a/src/rfc1035.c b/src/rfc1035.c
+index 188d05f..18858a8 100644
+--- a/src/rfc1035.c
++++ b/src/rfc1035.c
+@@ -489,8 +489,8 @@ struct macparm {
+ union mysockaddr *l3;
+ };
+
+-static size_t add_pseudoheader(struct dns_header *header, size_t plen, unsigned char *limit,
+- int optno, unsigned char *opt, size_t optlen, int set_do)
++size_t add_pseudoheader(struct dns_header *header, size_t plen, unsigned char *limit,
++ unsigned short udp_sz, int optno, unsigned char *opt, size_t optlen, int set_do)
+ {
+ unsigned char *lenp, *datap, *p;
+ int rdlen, is_sign;
+@@ -508,7 +508,7 @@ static size_t add_pseudoheader(struct dns_header *header, size_t plen, unsigned
+ return plen;
+ *p++ = 0; /* empty name */
+ PUTSHORT(T_OPT, p);
+- PUTSHORT(SAFE_PKTSZ, p); /* max packet length, this will be overwritten */
++ PUTSHORT(udp_sz, p); /* max packet length, 512 if not given in EDNS0 header */
+ PUTSHORT(0, p); /* extended RCODE and version */
+ PUTSHORT(set_do ? 0x8000 : 0, p); /* DO flag */
+ lenp = p;
+@@ -594,7 +594,7 @@ static int filter_mac(int family, char *addrp, char *mac, size_t maclen, void *p
+ if (!match)
+ return 1; /* continue */
+
+- parm->plen = add_pseudoheader(parm->header, parm->plen, parm->limit, EDNS0_OPTION_MAC, (unsigned char *)mac, maclen, 0);
++ parm->plen = add_pseudoheader(parm->header, parm->plen, parm->limit, PACKETSZ, EDNS0_OPTION_MAC, (unsigned char *)mac, maclen, 0);
+
+ return 0; /* done */
+ }
+@@ -603,12 +603,6 @@ size_t add_mac(struct dns_header *header, size_t plen, char *limit, union mysock
+ {
+ struct macparm parm;
+
+-/* Must have an existing pseudoheader as the only ar-record,
+- or have no ar-records. Must also not be signed */
+-
+- if (ntohs(header->arcount) > 1)
+- return plen;
+-
+ parm.header = header;
+ parm.limit = (unsigned char *)limit;
+ parm.plen = plen;
+@@ -699,13 +693,13 @@ size_t add_source_addr(struct dns_header *header, size_t plen, char *limit, unio
+ struct subnet_opt opt;
+
+ len = calc_subnet_opt(&opt, source);
+- return add_pseudoheader(header, plen, (unsigned char *)limit, EDNS0_OPTION_CLIENT_SUBNET, (unsigned char *)&opt, len, 0);
++ return add_pseudoheader(header, plen, (unsigned char *)limit, PACKETSZ, EDNS0_OPTION_CLIENT_SUBNET, (unsigned char *)&opt, len, 0);
+ }
+
+ #ifdef HAVE_DNSSEC
+ size_t add_do_bit(struct dns_header *header, size_t plen, char *limit)
+ {
+- return add_pseudoheader(header, plen, (unsigned char *)limit, 0, NULL, 0, 1);
++ return add_pseudoheader(header, plen, (unsigned char *)limit, PACKETSZ, 0, NULL, 0, 1);
+ }
+ #endif
+
+@@ -1525,16 +1519,16 @@ static unsigned long crec_ttl(struct crec *crecp, time_t now)
+ /* return zero if we can't answer from cache, or packet size if we can */
+ size_t answer_request(struct dns_header *header, char *limit, size_t qlen,
+ struct in_addr local_addr, struct in_addr local_netmask,
+- time_t now, int *ad_reqd, int *do_bit)
++ time_t now, int ad_reqd, int do_bit, int have_pseudoheader)
+ {
+ char *name = daemon->namebuff;
+- unsigned char *p, *ansp, *pheader;
++ unsigned char *p, *ansp;
+ unsigned int qtype, qclass;
+ struct all_addr addr;
+ int nameoffset;
+ unsigned short flag;
+ int q, ans, anscount = 0, addncount = 0;
+- int dryrun = 0, sec_reqd = 0, have_pseudoheader = 0;
++ int dryrun = 0;
+ struct crec *crecp;
+ int nxdomain = 0, auth = 1, trunc = 0, sec_data = 1;
+ struct mx_srv_record *rec;
+@@ -1550,35 +1544,11 @@ size_t answer_request(struct dns_header *header, char *limit, size_t qlen,
+ if (header->hb4 & HB4_CD)
+ sec_data = 0;
+
+- /* RFC 6840 5.7 */
+- *ad_reqd = header->hb4 & HB4_AD;
+- *do_bit = 0;
+-
+ /* If there is an additional data section then it will be overwritten by
+ partial replies, so we have to do a dry run to see if we can answer
+ the query. */
+-
+ if (ntohs(header->arcount) != 0)
+- {
+- dryrun = 1;
+-
+- /* If there's an additional section, there might be an EDNS(0) pseudoheader */
+- if (find_pseudoheader(header, qlen, NULL, &pheader, NULL))
+- {
+- unsigned short flags;
+-
+- have_pseudoheader = 1;
+-
+- pheader += 4; /* udp size, ext_rcode */
+- GETSHORT(flags, pheader);
+-
+- if ((sec_reqd = flags & 0x8000))
+- {
+- *do_bit = 1;/* do bit */
+- *ad_reqd = 1;
+- }
+- }
+- }
++ dryrun = 1;
+
+ for (rec = daemon->mxnames; rec; rec = rec->next)
+ rec->offset = 0;
+@@ -1603,11 +1573,6 @@ size_t answer_request(struct dns_header *header, char *limit, size_t qlen,
+ GETSHORT(qtype, p);
+ GETSHORT(qclass, p);
+
+- /* Don't filter RRSIGS from answers to ANY queries, even if do-bit
+- not set. */
+- if (qtype == T_ANY)
+- *do_bit = 1;
+-
+ ans = 0; /* have we answered this question */
+
+ if (qtype == T_TXT || qtype == T_ANY)
+@@ -1739,7 +1704,7 @@ size_t answer_request(struct dns_header *header, char *limit, size_t qlen,
+ the zone is unsigned, which implies that we're doing
+ validation. */
+ if ((crecp->flags & (F_HOSTS | F_DHCP | F_CONFIG)) ||
+- !sec_reqd ||
++ !do_bit ||
+ (option_bool(OPT_DNSSEC_VALID) && !(crecp->flags & F_DNSSECOK)))
+ {
+ do
+@@ -1927,7 +1892,7 @@ size_t answer_request(struct dns_header *header, char *limit, size_t qlen,
+ }
+
+ /* If the client asked for DNSSEC don't use cached data. */
+- if ((crecp->flags & (F_HOSTS | F_DHCP | F_CONFIG)) || !sec_reqd || !(crecp->flags & F_DNSSECOK))
++ if ((crecp->flags & (F_HOSTS | F_DHCP | F_CONFIG)) || !do_bit || !(crecp->flags & F_DNSSECOK))
+ do
+ {
+ /* don't answer wildcard queries with data not from /etc/hosts
+@@ -1961,17 +1926,12 @@ size_t answer_request(struct dns_header *header, char *limit, size_t qlen,
+
+ if (crecp->flags & F_NEG)
+ {
+- /* We don't cache NSEC records, so if a DNSSEC-validated negative answer
+- is cached and the client wants DNSSEC, forward rather than answering from the cache */
+- if (!sec_reqd || !(crecp->flags & F_DNSSECOK))
+- {
+- ans = 1;
+- auth = 0;
+- if (crecp->flags & F_NXDOMAIN)
+- nxdomain = 1;
+- if (!dryrun)
+- log_query(crecp->flags, name, NULL, NULL);
+- }
++ ans = 1;
++ auth = 0;
++ if (crecp->flags & F_NXDOMAIN)
++ nxdomain = 1;
++ if (!dryrun)
++ log_query(crecp->flags, name, NULL, NULL);
+ }
+ else
+ {
+@@ -2209,10 +2169,11 @@ size_t answer_request(struct dns_header *header, char *limit, size_t qlen,
+
+ len = ansp - (unsigned char *)header;
+
++ /* Advertise our packet size limit in our reply */
+ if (have_pseudoheader)
+- len = add_pseudoheader(header, len, (unsigned char *)limit, 0, NULL, 0, sec_reqd);
++ len = add_pseudoheader(header, len, (unsigned char *)limit, daemon->edns_pktsz, 0, NULL, 0, do_bit);
+
+- if (*ad_reqd && sec_data)
++ if (ad_reqd && sec_data)
+ header->hb4 |= HB4_AD;
+ else
+ header->hb4 &= ~HB4_AD;
+diff --git a/src/rrfilter.c b/src/rrfilter.c
+index ae12261..b26b39f 100644
+--- a/src/rrfilter.c
++++ b/src/rrfilter.c
+@@ -243,7 +243,7 @@ size_t rrfilter(struct dns_header *header, size_t plen, int mode)
+ for (p = rrs[0], i = 1; i < rr_found; i += 2)
+ {
+ unsigned char *start = rrs[i];
+- unsigned char *end = (i != rr_found - 1) ? rrs[i+1] : ((unsigned char *)(header+1)) + plen;
++ unsigned char *end = (i != rr_found - 1) ? rrs[i+1] : ((unsigned char *)header) + plen;
+
+ memmove(p, start, end-start);
+ p += end-start;
+--
+1.7.10.4
+
--- /dev/null
+From d67ecac59d58f249707d26e38d49c29b552af4d8 Mon Sep 17 00:00:00 2001
+From: Simon Kelley <simon@thekelleys.org.uk>
+Date: Sun, 20 Dec 2015 20:44:23 +0000
+Subject: [PATCH] More tweaks in handling unknown DNSSEC algorithms.
+
+---
+ src/dnssec.c | 128 +++++++++++++++++++++++++++++-----------------------------
+ 1 file changed, 63 insertions(+), 65 deletions(-)
+
+diff --git a/src/dnssec.c b/src/dnssec.c
+index 299ca64..e09f304 100644
+--- a/src/dnssec.c
++++ b/src/dnssec.c
+@@ -70,7 +70,17 @@ static char *algo_digest_name(int algo)
+ default: return NULL;
+ }
+ }
+-
++
++/* http://www.iana.org/assignments/dnssec-nsec3-parameters/dnssec-nsec3-parameters.xhtml */
++static char *nsec3_digest_name(int digest)
++{
++ switch (digest)
++ {
++ case 1: return "sha1";
++ default: return NULL;
++ }
++}
++
+ /* Find pointer to correct hash function in nettle library */
+ static const struct nettle_hash *hash_find(char *name)
+ {
+@@ -667,7 +677,6 @@ static int explore_rrset(struct dns_header *header, size_t plen, int class, int
+ static int rrset_sz = 0, sig_sz = 0;
+ unsigned char *p;
+ int rrsetidx, sigidx, j, rdlen, res;
+- int name_labels = count_labels(name); /* For 4035 5.3.2 check */
+ int gotkey = 0;
+
+ if (!(p = skip_questions(header, plen)))
+@@ -678,7 +687,7 @@ static int explore_rrset(struct dns_header *header, size_t plen, int class, int
+ j != 0; j--)
+ {
+ unsigned char *pstart, *pdata;
+- int stype, sclass, algo, type_covered, labels, sig_expiration, sig_inception;
++ int stype, sclass, type_covered;
+
+ pstart = p;
+
+@@ -712,12 +721,7 @@ static int explore_rrset(struct dns_header *header, size_t plen, int class, int
+ return 0; /* bad packet */
+
+ GETSHORT(type_covered, p);
+- algo = *p++;
+- labels = *p++;
+- p += 4; /* orig_ttl */
+- GETLONG(sig_expiration, p);
+- GETLONG(sig_inception, p);
+- p += 2; /* key_tag */
++ p += 16; /* algo, labels, orig_ttl, sig_expiration, sig_inception, key_tag */
+
+ if (gotkey)
+ {
+@@ -749,11 +753,8 @@ static int explore_rrset(struct dns_header *header, size_t plen, int class, int
+ }
+ }
+
+- /* Don't count signatures for algos we don't support */
+- if (check_date_range(sig_inception, sig_expiration) &&
+- labels <= name_labels &&
+- type_covered == type &&
+- verify_func(algo))
++
++ if (type_covered == type)
+ {
+ if (!expand_workspace(&sigs, &sig_sz, sigidx))
+ return 0;
+@@ -795,7 +796,7 @@ static int validate_rrset(time_t now, struct dns_header *header, size_t plen, in
+ char *name, char *keyname, char **wildcard_out, struct blockdata *key, int keylen, int algo_in, int keytag_in)
+ {
+ unsigned char *p;
+- int rdlen, j, name_labels;
++ int rdlen, j, name_labels, sig_expiration, sig_inception;
+ struct crec *crecp = NULL;
+ int algo, labels, orig_ttl, key_tag;
+ u16 *rr_desc = rrfilter_desc(type);
+@@ -828,13 +829,16 @@ static int validate_rrset(time_t now, struct dns_header *header, size_t plen, in
+ algo = *p++;
+ labels = *p++;
+ GETLONG(orig_ttl, p);
+- p += 8; /* sig_expiration, sig_inception already checked */
++ GETLONG(sig_expiration, p);
++ GETLONG(sig_inception, p);
+ GETSHORT(key_tag, p);
+
+ if (!extract_name(header, plen, &p, keyname, 1, 0))
+ return STAT_BOGUS;
+
+- if (!(hash = hash_find(algo_digest_name(algo))) ||
++ if (!check_date_range(sig_inception, sig_expiration) ||
++ labels > name_labels ||
++ !(hash = hash_find(algo_digest_name(algo))) ||
+ !hash_init(hash, &ctx, &digest))
+ continue;
+
+@@ -1112,7 +1116,10 @@ int dnssec_validate_by_ds(time_t now, struct dns_header *header, size_t plen, ch
+ else
+ {
+ a.addr.keytag = keytag;
+- log_query(F_NOEXTRA | F_KEYTAG | F_UPSTREAM, name, &a, "DNSKEY keytag %u");
++ if (verify_func(algo))
++ log_query(F_NOEXTRA | F_KEYTAG | F_UPSTREAM, name, &a, "DNSKEY keytag %u");
++ else
++ log_query(F_NOEXTRA | F_KEYTAG | F_UPSTREAM, name, &a, "DNSKEY keytag %u (not supported)");
+
+ recp1->addr.key.keylen = rdlen - 4;
+ recp1->addr.key.keydata = key;
+@@ -1235,7 +1242,11 @@ int dnssec_validate_ds(time_t now, struct dns_header *header, size_t plen, char
+ else
+ {
+ a.addr.keytag = keytag;
+- log_query(F_NOEXTRA | F_KEYTAG | F_UPSTREAM, name, &a, "DS keytag %u");
++ if (hash_find(ds_digest_name(digest)) && verify_func(algo))
++ log_query(F_NOEXTRA | F_KEYTAG | F_UPSTREAM, name, &a, "DS keytag %u");
++ else
++ log_query(F_NOEXTRA | F_KEYTAG | F_UPSTREAM, name, &a, "DS keytag %u (not supported)");
++
+ crecp->addr.ds.digest = digest;
+ crecp->addr.ds.keydata = key;
+ crecp->addr.ds.algo = algo;
+@@ -1660,7 +1671,7 @@ static int prove_non_existence_nsec3(struct dns_header *header, size_t plen, uns
+ *nons = 1;
+
+ /* Look though the NSEC3 records to find the first one with
+- an algorithm we support (currently only algo == 1).
++ an algorithm we support.
+
+ Take the algo, iterations, and salt of that record
+ as the ones we're going to use, and prune any
+@@ -1674,7 +1685,7 @@ static int prove_non_existence_nsec3(struct dns_header *header, size_t plen, uns
+ p += 10; /* type, class, TTL, rdlen */
+ algo = *p++;
+
+- if (algo == 1)
++ if ((hash = hash_find(nsec3_digest_name(algo))))
+ break; /* known algo */
+ }
+
+@@ -1724,10 +1735,6 @@ static int prove_non_existence_nsec3(struct dns_header *header, size_t plen, uns
+ nsecs[i] = nsec3p;
+ }
+
+- /* Algo is checked as 1 above */
+- if (!(hash = hash_find("sha1")))
+- return 0;
+-
+ if ((digest_len = hash_name(name, &digest, hash, salt, salt_len, iterations)) == 0)
+ return 0;
+
+@@ -1843,8 +1850,10 @@ static int prove_non_existence(struct dns_header *header, size_t plen, char *key
+
+ if (type_found == T_NSEC)
+ return prove_non_existence_nsec(header, plen, nsecset, nsecs_found, daemon->workspacename, keyname, name, qtype, nons);
+- else
++ else if (type_found == T_NSEC3)
+ return prove_non_existence_nsec3(header, plen, nsecset, nsecs_found, daemon->workspacename, keyname, name, qtype, wildname, nons);
++ else
++ return 0;
+ }
+
+ /* Check signing status of name.
+@@ -1857,7 +1866,7 @@ static int prove_non_existence(struct dns_header *header, size_t plen, char *key
+ */
+ static int zone_status(char *name, int class, char *keyname, time_t now)
+ {
+- int secure_ds, name_start = strlen(name);
++ int name_start = strlen(name);
+ struct crec *crecp;
+ char *p;
+
+@@ -1867,51 +1876,40 @@ static int zone_status(char *name, int class, char *keyname, time_t now)
+
+ if (!(crecp = cache_find_by_name(NULL, keyname, now, F_DS)))
+ return STAT_NEED_DS;
++
++ /* F_DNSSECOK misused in DS cache records to non-existance of NS record.
++ F_NEG && !F_DNSSECOK implies that we've proved there's no DS record here,
++ but that's because there's no NS record either, ie this isn't the start
++ of a zone. We only prove that the DNS tree below a node is unsigned when
++ we prove that we're at a zone cut AND there's no DS record. */
++ if (crecp->flags & F_NEG)
++ {
++ if (crecp->flags & F_DNSSECOK)
++ return STAT_INSECURE; /* proved no DS here */
++ }
+ else
+ {
+- secure_ds = 0;
+-
++ int gotone = 0;
++
++ /* If all the DS records have digest and/or sig algos we don't support,
++ then the zone is insecure. Note that if an algo
++ appears in the DS, then RRSIGs for that algo MUST
++ exist for each RRset: 4035 para 2.2 So if we find
++ a DS here with digest and sig we can do, we're entitled
++ to assume we can validate the zone and if we can't later,
++ because an RRSIG is missing we return BOGUS.
++ */
+ do
+ {
+- if (crecp->uid == (unsigned int)class)
+- {
+- /* F_DNSSECOK misused in DS cache records to non-existance of NS record.
+- F_NEG && !F_DNSSECOK implies that we've proved there's no DS record here,
+- but that's because there's no NS record either, ie this isn't the start
+- of a zone. We only prove that the DNS tree below a node is unsigned when
+- we prove that we're at a zone cut AND there's no DS record.
+- */
+- if (crecp->flags & F_NEG)
+- {
+- if (crecp->flags & F_DNSSECOK)
+- return STAT_INSECURE; /* proved no DS here */
+- }
+- else if (!hash_find(ds_digest_name(crecp->addr.ds.digest)) || !verify_func(crecp->addr.ds.algo))
+- return STAT_INSECURE; /* algo we can't use - insecure */
+- else
+- secure_ds = 1;
+- }
++ if (crecp->uid == (unsigned int)class &&
++ hash_find(ds_digest_name(crecp->addr.ds.digest)) &&
++ verify_func(crecp->addr.ds.algo))
++ gotone = 1;
+ }
+ while ((crecp = cache_find_by_name(crecp, keyname, now, F_DS)));
+- }
+-
+- if (secure_ds)
+- {
+- /* We've found only DS records that attest to the DNSKEY RRset in the zone, so we believe
+- that RRset is good. Furthermore the DNSKEY whose hash is proved by the DS record is
+- one we can use. However the DNSKEY RRset may contain more than one key and
+- one of the other keys may use an algorithm we don't support. If that's
+- the case the zone is insecure for us. */
+-
+- if (!(crecp = cache_find_by_name(NULL, keyname, now, F_DNSKEY)))
+- return STAT_NEED_KEY;
+
+- do
+- {
+- if (crecp->uid == (unsigned int)class && !verify_func(crecp->addr.key.algo))
+- return STAT_INSECURE;
+- }
+- while ((crecp = cache_find_by_name(crecp, keyname, now, F_DNSKEY)));
++ if (!gotone)
++ return STAT_INSECURE;
+ }
+
+ if (name_start == 0)
+--
+1.7.10.4
+
--- /dev/null
+From 3e86d316c4bb406ed813aa5256615c8a95cac6d8 Mon Sep 17 00:00:00 2001
+From: Simon Kelley <simon@thekelleys.org.uk>
+Date: Sun, 20 Dec 2015 20:50:05 +0000
+Subject: [PATCH] Nasty, rare and obscure off-by-one in DNSSEC hostname_cmp().
+
+---
+ src/dnssec.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/dnssec.c b/src/dnssec.c
+index e09f304..29848e1 100644
+--- a/src/dnssec.c
++++ b/src/dnssec.c
+@@ -1394,8 +1394,8 @@ static int hostname_cmp(const char *a, const char *b)
+ if (sb == b)
+ return 1;
+
+- ea = sa--;
+- eb = sb--;
++ ea = --sa;
++ eb = --sb;
+ }
+ }
+
+--
+1.7.10.4
+
--- /dev/null
+From a86fdf437ecc29398f9715ceb5240442a17ac014 Mon Sep 17 00:00:00 2001
+From: Simon Kelley <simon@thekelleys.org.uk>
+Date: Sun, 20 Dec 2015 21:19:20 +0000
+Subject: [PATCH] Minor tweak to previous commit.
+
+---
+ src/dnssec.c | 6 ++----
+ 1 file changed, 2 insertions(+), 4 deletions(-)
+
+diff --git a/src/dnssec.c b/src/dnssec.c
+index 29848e1..9fa64b6 100644
+--- a/src/dnssec.c
++++ b/src/dnssec.c
+@@ -1889,8 +1889,6 @@ static int zone_status(char *name, int class, char *keyname, time_t now)
+ }
+ else
+ {
+- int gotone = 0;
+-
+ /* If all the DS records have digest and/or sig algos we don't support,
+ then the zone is insecure. Note that if an algo
+ appears in the DS, then RRSIGs for that algo MUST
+@@ -1904,11 +1902,11 @@ static int zone_status(char *name, int class, char *keyname, time_t now)
+ if (crecp->uid == (unsigned int)class &&
+ hash_find(ds_digest_name(crecp->addr.ds.digest)) &&
+ verify_func(crecp->addr.ds.algo))
+- gotone = 1;
++ break;
+ }
+ while ((crecp = cache_find_by_name(crecp, keyname, now, F_DS)));
+
+- if (!gotone)
++ if (!crecp)
+ return STAT_INSECURE;
+ }
+
+--
+1.7.10.4
+
--- /dev/null
+From ce5732e84fc46d7f99c152f736cfb4ef5ec98a01 Mon Sep 17 00:00:00 2001
+From: Simon Kelley <simon@thekelleys.org.uk>
+Date: Sun, 20 Dec 2015 21:39:19 +0000
+Subject: [PATCH] NSEC3 check: RFC5155 para 8.2
+
+---
+ src/dnssec.c | 8 ++++++--
+ 1 file changed, 6 insertions(+), 2 deletions(-)
+
+diff --git a/src/dnssec.c b/src/dnssec.c
+index 9fa64b6..486e422 100644
+--- a/src/dnssec.c
++++ b/src/dnssec.c
+@@ -1704,7 +1704,7 @@ static int prove_non_existence_nsec3(struct dns_header *header, size_t plen, uns
+ for (i = 0; i < nsec_count; i++)
+ {
+ unsigned char *nsec3p = nsecs[i];
+- int this_iter;
++ int this_iter, flags;
+
+ nsecs[i] = NULL; /* Speculative, will be restored if OK. */
+
+@@ -1716,8 +1716,12 @@ static int prove_non_existence_nsec3(struct dns_header *header, size_t plen, uns
+ if (*p++ != algo)
+ continue;
+
+- p++; /* flags */
++ flags = *p++; /* flags */
+
++ /* 5155 8.2 */
++ if (flags != 0 && flags != 1)
++ continue;
++
+ GETSHORT(this_iter, p);
+ if (this_iter != iterations)
+ continue;
+--
+1.7.10.4
+
--- /dev/null
+From: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61164
+
+--- trunk/libitm/local_atomic 2015/08/20 17:43:55 227039
++++ trunk/libitm/local_atomic 2015/08/20 17:55:24 227040
+@@ -41,8 +41,7 @@
+ #ifndef _GLIBCXX_ATOMIC
+ #define _GLIBCXX_ATOMIC 1
+
+-#undef __always_inline
+-#define __always_inline __attribute__((always_inline))
++#define __libitm_always_inline __attribute__((always_inline))
+
+ // #pragma GCC system_header
+
+@@ -74,7 +73,7 @@
+ memory_order_seq_cst
+ } memory_order;
+
+- inline __always_inline memory_order
++ inline __libitm_always_inline memory_order
+ __calculate_memory_order(memory_order __m) noexcept
+ {
+ const bool __cond1 = __m == memory_order_release;
+@@ -84,13 +83,13 @@
+ return __mo2;
+ }
+
+- inline __always_inline void
++ inline __libitm_always_inline void
+ atomic_thread_fence(memory_order __m) noexcept
+ {
+ __atomic_thread_fence (__m);
+ }
+
+- inline __always_inline void
++ inline __libitm_always_inline void
+ atomic_signal_fence(memory_order __m) noexcept
+ {
+ __atomic_thread_fence (__m);
+@@ -280,19 +279,19 @@
+ // Conversion to ATOMIC_FLAG_INIT.
+ atomic_flag(bool __i) noexcept : __atomic_flag_base({ __i }) { }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ test_and_set(memory_order __m = memory_order_seq_cst) noexcept
+ {
+ return __atomic_test_and_set (&_M_i, __m);
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ test_and_set(memory_order __m = memory_order_seq_cst) volatile noexcept
+ {
+ return __atomic_test_and_set (&_M_i, __m);
+ }
+
+- __always_inline void
++ __libitm_always_inline void
+ clear(memory_order __m = memory_order_seq_cst) noexcept
+ {
+ // __glibcxx_assert(__m != memory_order_consume);
+@@ -302,7 +301,7 @@
+ __atomic_clear (&_M_i, __m);
+ }
+
+- __always_inline void
++ __libitm_always_inline void
+ clear(memory_order __m = memory_order_seq_cst) volatile noexcept
+ {
+ // __glibcxx_assert(__m != memory_order_consume);
+@@ -455,7 +454,7 @@
+ is_lock_free() const volatile noexcept
+ { return __atomic_is_lock_free (sizeof (_M_i), &_M_i); }
+
+- __always_inline void
++ __libitm_always_inline void
+ store(__int_type __i, memory_order __m = memory_order_seq_cst) noexcept
+ {
+ // __glibcxx_assert(__m != memory_order_acquire);
+@@ -465,7 +464,7 @@
+ __atomic_store_n(&_M_i, __i, __m);
+ }
+
+- __always_inline void
++ __libitm_always_inline void
+ store(__int_type __i,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ {
+@@ -476,7 +475,7 @@
+ __atomic_store_n(&_M_i, __i, __m);
+ }
+
+- __always_inline __int_type
++ __libitm_always_inline __int_type
+ load(memory_order __m = memory_order_seq_cst) const noexcept
+ {
+ // __glibcxx_assert(__m != memory_order_release);
+@@ -485,7 +484,7 @@
+ return __atomic_load_n(&_M_i, __m);
+ }
+
+- __always_inline __int_type
++ __libitm_always_inline __int_type
+ load(memory_order __m = memory_order_seq_cst) const volatile noexcept
+ {
+ // __glibcxx_assert(__m != memory_order_release);
+@@ -494,21 +493,21 @@
+ return __atomic_load_n(&_M_i, __m);
+ }
+
+- __always_inline __int_type
++ __libitm_always_inline __int_type
+ exchange(__int_type __i,
+ memory_order __m = memory_order_seq_cst) noexcept
+ {
+ return __atomic_exchange_n(&_M_i, __i, __m);
+ }
+
+- __always_inline __int_type
++ __libitm_always_inline __int_type
+ exchange(__int_type __i,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ {
+ return __atomic_exchange_n(&_M_i, __i, __m);
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(__int_type& __i1, __int_type __i2,
+ memory_order __m1, memory_order __m2) noexcept
+ {
+@@ -519,7 +518,7 @@
+ return __atomic_compare_exchange_n(&_M_i, &__i1, __i2, 1, __m1, __m2);
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(__int_type& __i1, __int_type __i2,
+ memory_order __m1,
+ memory_order __m2) volatile noexcept
+@@ -531,7 +530,7 @@
+ return __atomic_compare_exchange_n(&_M_i, &__i1, __i2, 1, __m1, __m2);
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(__int_type& __i1, __int_type __i2,
+ memory_order __m = memory_order_seq_cst) noexcept
+ {
+@@ -539,7 +538,7 @@
+ __calculate_memory_order(__m));
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(__int_type& __i1, __int_type __i2,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ {
+@@ -547,7 +546,7 @@
+ __calculate_memory_order(__m));
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(__int_type& __i1, __int_type __i2,
+ memory_order __m1, memory_order __m2) noexcept
+ {
+@@ -558,7 +557,7 @@
+ return __atomic_compare_exchange_n(&_M_i, &__i1, __i2, 0, __m1, __m2);
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(__int_type& __i1, __int_type __i2,
+ memory_order __m1,
+ memory_order __m2) volatile noexcept
+@@ -570,7 +569,7 @@
+ return __atomic_compare_exchange_n(&_M_i, &__i1, __i2, 0, __m1, __m2);
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(__int_type& __i1, __int_type __i2,
+ memory_order __m = memory_order_seq_cst) noexcept
+ {
+@@ -578,7 +577,7 @@
+ __calculate_memory_order(__m));
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(__int_type& __i1, __int_type __i2,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ {
+@@ -586,52 +585,52 @@
+ __calculate_memory_order(__m));
+ }
+
+- __always_inline __int_type
++ __libitm_always_inline __int_type
+ fetch_add(__int_type __i,
+ memory_order __m = memory_order_seq_cst) noexcept
+ { return __atomic_fetch_add(&_M_i, __i, __m); }
+
+- __always_inline __int_type
++ __libitm_always_inline __int_type
+ fetch_add(__int_type __i,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return __atomic_fetch_add(&_M_i, __i, __m); }
+
+- __always_inline __int_type
++ __libitm_always_inline __int_type
+ fetch_sub(__int_type __i,
+ memory_order __m = memory_order_seq_cst) noexcept
+ { return __atomic_fetch_sub(&_M_i, __i, __m); }
+
+- __always_inline __int_type
++ __libitm_always_inline __int_type
+ fetch_sub(__int_type __i,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return __atomic_fetch_sub(&_M_i, __i, __m); }
+
+- __always_inline __int_type
++ __libitm_always_inline __int_type
+ fetch_and(__int_type __i,
+ memory_order __m = memory_order_seq_cst) noexcept
+ { return __atomic_fetch_and(&_M_i, __i, __m); }
+
+- __always_inline __int_type
++ __libitm_always_inline __int_type
+ fetch_and(__int_type __i,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return __atomic_fetch_and(&_M_i, __i, __m); }
+
+- __always_inline __int_type
++ __libitm_always_inline __int_type
+ fetch_or(__int_type __i,
+ memory_order __m = memory_order_seq_cst) noexcept
+ { return __atomic_fetch_or(&_M_i, __i, __m); }
+
+- __always_inline __int_type
++ __libitm_always_inline __int_type
+ fetch_or(__int_type __i,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return __atomic_fetch_or(&_M_i, __i, __m); }
+
+- __always_inline __int_type
++ __libitm_always_inline __int_type
+ fetch_xor(__int_type __i,
+ memory_order __m = memory_order_seq_cst) noexcept
+ { return __atomic_fetch_xor(&_M_i, __i, __m); }
+
+- __always_inline __int_type
++ __libitm_always_inline __int_type
+ fetch_xor(__int_type __i,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return __atomic_fetch_xor(&_M_i, __i, __m); }
+@@ -733,7 +732,7 @@
+ is_lock_free() const volatile noexcept
+ { return __atomic_is_lock_free (sizeof (_M_p), &_M_p); }
+
+- __always_inline void
++ __libitm_always_inline void
+ store(__pointer_type __p,
+ memory_order __m = memory_order_seq_cst) noexcept
+ {
+@@ -744,7 +743,7 @@
+ __atomic_store_n(&_M_p, __p, __m);
+ }
+
+- __always_inline void
++ __libitm_always_inline void
+ store(__pointer_type __p,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ {
+@@ -755,7 +754,7 @@
+ __atomic_store_n(&_M_p, __p, __m);
+ }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ load(memory_order __m = memory_order_seq_cst) const noexcept
+ {
+ // __glibcxx_assert(__m != memory_order_release);
+@@ -764,7 +763,7 @@
+ return __atomic_load_n(&_M_p, __m);
+ }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ load(memory_order __m = memory_order_seq_cst) const volatile noexcept
+ {
+ // __glibcxx_assert(__m != memory_order_release);
+@@ -773,21 +772,21 @@
+ return __atomic_load_n(&_M_p, __m);
+ }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ exchange(__pointer_type __p,
+ memory_order __m = memory_order_seq_cst) noexcept
+ {
+ return __atomic_exchange_n(&_M_p, __p, __m);
+ }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ exchange(__pointer_type __p,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ {
+ return __atomic_exchange_n(&_M_p, __p, __m);
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2,
+ memory_order __m1,
+ memory_order __m2) noexcept
+@@ -799,7 +798,7 @@
+ return __atomic_compare_exchange_n(&_M_p, &__p1, __p2, 0, __m1, __m2);
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2,
+ memory_order __m1,
+ memory_order __m2) volatile noexcept
+@@ -811,22 +810,22 @@
+ return __atomic_compare_exchange_n(&_M_p, &__p1, __p2, 0, __m1, __m2);
+ }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ fetch_add(ptrdiff_t __d,
+ memory_order __m = memory_order_seq_cst) noexcept
+ { return __atomic_fetch_add(&_M_p, __d, __m); }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ fetch_add(ptrdiff_t __d,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return __atomic_fetch_add(&_M_p, __d, __m); }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ fetch_sub(ptrdiff_t __d,
+ memory_order __m = memory_order_seq_cst) noexcept
+ { return __atomic_fetch_sub(&_M_p, __d, __m); }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ fetch_sub(ptrdiff_t __d,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return __atomic_fetch_sub(&_M_p, __d, __m); }
+@@ -870,67 +869,67 @@
+ bool
+ is_lock_free() const volatile noexcept { return _M_base.is_lock_free(); }
+
+- __always_inline void
++ __libitm_always_inline void
+ store(bool __i, memory_order __m = memory_order_seq_cst) noexcept
+ { _M_base.store(__i, __m); }
+
+- __always_inline void
++ __libitm_always_inline void
+ store(bool __i, memory_order __m = memory_order_seq_cst) volatile noexcept
+ { _M_base.store(__i, __m); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ load(memory_order __m = memory_order_seq_cst) const noexcept
+ { return _M_base.load(__m); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ load(memory_order __m = memory_order_seq_cst) const volatile noexcept
+ { return _M_base.load(__m); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ exchange(bool __i, memory_order __m = memory_order_seq_cst) noexcept
+ { return _M_base.exchange(__i, __m); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ exchange(bool __i,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return _M_base.exchange(__i, __m); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(bool& __i1, bool __i2, memory_order __m1,
+ memory_order __m2) noexcept
+ { return _M_base.compare_exchange_weak(__i1, __i2, __m1, __m2); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(bool& __i1, bool __i2, memory_order __m1,
+ memory_order __m2) volatile noexcept
+ { return _M_base.compare_exchange_weak(__i1, __i2, __m1, __m2); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(bool& __i1, bool __i2,
+ memory_order __m = memory_order_seq_cst) noexcept
+ { return _M_base.compare_exchange_weak(__i1, __i2, __m); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(bool& __i1, bool __i2,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return _M_base.compare_exchange_weak(__i1, __i2, __m); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(bool& __i1, bool __i2, memory_order __m1,
+ memory_order __m2) noexcept
+ { return _M_base.compare_exchange_strong(__i1, __i2, __m1, __m2); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(bool& __i1, bool __i2, memory_order __m1,
+ memory_order __m2) volatile noexcept
+ { return _M_base.compare_exchange_strong(__i1, __i2, __m1, __m2); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(bool& __i1, bool __i2,
+ memory_order __m = memory_order_seq_cst) noexcept
+ { return _M_base.compare_exchange_strong(__i1, __i2, __m); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(bool& __i1, bool __i2,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return _M_base.compare_exchange_strong(__i1, __i2, __m); }
+@@ -980,11 +979,11 @@
+ store(_Tp __i, memory_order _m = memory_order_seq_cst) noexcept
+ { __atomic_store(&_M_i, &__i, _m); }
+
+- __always_inline void
++ __libitm_always_inline void
+ store(_Tp __i, memory_order _m = memory_order_seq_cst) volatile noexcept
+ { __atomic_store(&_M_i, &__i, _m); }
+
+- __always_inline _Tp
++ __libitm_always_inline _Tp
+ load(memory_order _m = memory_order_seq_cst) const noexcept
+ {
+ _Tp tmp;
+@@ -992,7 +991,7 @@
+ return tmp;
+ }
+
+- __always_inline _Tp
++ __libitm_always_inline _Tp
+ load(memory_order _m = memory_order_seq_cst) const volatile noexcept
+ {
+ _Tp tmp;
+@@ -1000,7 +999,7 @@
+ return tmp;
+ }
+
+- __always_inline _Tp
++ __libitm_always_inline _Tp
+ exchange(_Tp __i, memory_order _m = memory_order_seq_cst) noexcept
+ {
+ _Tp tmp;
+@@ -1008,7 +1007,7 @@
+ return tmp;
+ }
+
+- __always_inline _Tp
++ __libitm_always_inline _Tp
+ exchange(_Tp __i,
+ memory_order _m = memory_order_seq_cst) volatile noexcept
+ {
+@@ -1017,50 +1016,50 @@
+ return tmp;
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(_Tp& __e, _Tp __i, memory_order __s,
+ memory_order __f) noexcept
+ {
+ return __atomic_compare_exchange(&_M_i, &__e, &__i, true, __s, __f);
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(_Tp& __e, _Tp __i, memory_order __s,
+ memory_order __f) volatile noexcept
+ {
+ return __atomic_compare_exchange(&_M_i, &__e, &__i, true, __s, __f);
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(_Tp& __e, _Tp __i,
+ memory_order __m = memory_order_seq_cst) noexcept
+ { return compare_exchange_weak(__e, __i, __m, __m); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(_Tp& __e, _Tp __i,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return compare_exchange_weak(__e, __i, __m, __m); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(_Tp& __e, _Tp __i, memory_order __s,
+ memory_order __f) noexcept
+ {
+ return __atomic_compare_exchange(&_M_i, &__e, &__i, false, __s, __f);
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(_Tp& __e, _Tp __i, memory_order __s,
+ memory_order __f) volatile noexcept
+ {
+ return __atomic_compare_exchange(&_M_i, &__e, &__i, false, __s, __f);
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(_Tp& __e, _Tp __i,
+ memory_order __m = memory_order_seq_cst) noexcept
+ { return compare_exchange_strong(__e, __i, __m, __m); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(_Tp& __e, _Tp __i,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return compare_exchange_strong(__e, __i, __m, __m); }
+@@ -1153,46 +1152,46 @@
+ is_lock_free() const volatile noexcept
+ { return _M_b.is_lock_free(); }
+
+- __always_inline void
++ __libitm_always_inline void
+ store(__pointer_type __p,
+ memory_order __m = memory_order_seq_cst) noexcept
+ { return _M_b.store(__p, __m); }
+
+- __always_inline void
++ __libitm_always_inline void
+ store(__pointer_type __p,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return _M_b.store(__p, __m); }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ load(memory_order __m = memory_order_seq_cst) const noexcept
+ { return _M_b.load(__m); }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ load(memory_order __m = memory_order_seq_cst) const volatile noexcept
+ { return _M_b.load(__m); }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ exchange(__pointer_type __p,
+ memory_order __m = memory_order_seq_cst) noexcept
+ { return _M_b.exchange(__p, __m); }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ exchange(__pointer_type __p,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return _M_b.exchange(__p, __m); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(__pointer_type& __p1, __pointer_type __p2,
+ memory_order __m1, memory_order __m2) noexcept
+ { return _M_b.compare_exchange_strong(__p1, __p2, __m1, __m2); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(__pointer_type& __p1, __pointer_type __p2,
+ memory_order __m1,
+ memory_order __m2) volatile noexcept
+ { return _M_b.compare_exchange_strong(__p1, __p2, __m1, __m2); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(__pointer_type& __p1, __pointer_type __p2,
+ memory_order __m = memory_order_seq_cst) noexcept
+ {
+@@ -1200,7 +1199,7 @@
+ __calculate_memory_order(__m));
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_weak(__pointer_type& __p1, __pointer_type __p2,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ {
+@@ -1208,18 +1207,18 @@
+ __calculate_memory_order(__m));
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2,
+ memory_order __m1, memory_order __m2) noexcept
+ { return _M_b.compare_exchange_strong(__p1, __p2, __m1, __m2); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2,
+ memory_order __m1,
+ memory_order __m2) volatile noexcept
+ { return _M_b.compare_exchange_strong(__p1, __p2, __m1, __m2); }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2,
+ memory_order __m = memory_order_seq_cst) noexcept
+ {
+@@ -1227,7 +1226,7 @@
+ __calculate_memory_order(__m));
+ }
+
+- __always_inline bool
++ __libitm_always_inline bool
+ compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ {
+@@ -1235,22 +1234,22 @@
+ __calculate_memory_order(__m));
+ }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ fetch_add(ptrdiff_t __d,
+ memory_order __m = memory_order_seq_cst) noexcept
+ { return _M_b.fetch_add(__d, __m); }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ fetch_add(ptrdiff_t __d,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return _M_b.fetch_add(__d, __m); }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ fetch_sub(ptrdiff_t __d,
+ memory_order __m = memory_order_seq_cst) noexcept
+ { return _M_b.fetch_sub(__d, __m); }
+
+- __always_inline __pointer_type
++ __libitm_always_inline __pointer_type
+ fetch_sub(ptrdiff_t __d,
+ memory_order __m = memory_order_seq_cst) volatile noexcept
+ { return _M_b.fetch_sub(__d, __m); }
+@@ -1544,98 +1543,98 @@
+
+
+ // Function definitions, atomic_flag operations.
+- inline __always_inline bool
++ inline __libitm_always_inline bool
+ atomic_flag_test_and_set_explicit(atomic_flag* __a,
+ memory_order __m) noexcept
+ { return __a->test_and_set(__m); }
+
+- inline __always_inline bool
++ inline __libitm_always_inline bool
+ atomic_flag_test_and_set_explicit(volatile atomic_flag* __a,
+ memory_order __m) noexcept
+ { return __a->test_and_set(__m); }
+
+- inline __always_inline void
++ inline __libitm_always_inline void
+ atomic_flag_clear_explicit(atomic_flag* __a, memory_order __m) noexcept
+ { __a->clear(__m); }
+
+- inline __always_inline void
++ inline __libitm_always_inline void
+ atomic_flag_clear_explicit(volatile atomic_flag* __a,
+ memory_order __m) noexcept
+ { __a->clear(__m); }
+
+- inline __always_inline bool
++ inline __libitm_always_inline bool
+ atomic_flag_test_and_set(atomic_flag* __a) noexcept
+ { return atomic_flag_test_and_set_explicit(__a, memory_order_seq_cst); }
+
+- inline __always_inline bool
++ inline __libitm_always_inline bool
+ atomic_flag_test_and_set(volatile atomic_flag* __a) noexcept
+ { return atomic_flag_test_and_set_explicit(__a, memory_order_seq_cst); }
+
+- inline __always_inline void
++ inline __libitm_always_inline void
+ atomic_flag_clear(atomic_flag* __a) noexcept
+ { atomic_flag_clear_explicit(__a, memory_order_seq_cst); }
+
+- inline __always_inline void
++ inline __libitm_always_inline void
+ atomic_flag_clear(volatile atomic_flag* __a) noexcept
+ { atomic_flag_clear_explicit(__a, memory_order_seq_cst); }
+
+
+ // Function templates generally applicable to atomic types.
+ template<typename _ITp>
+- __always_inline bool
++ __libitm_always_inline bool
+ atomic_is_lock_free(const atomic<_ITp>* __a) noexcept
+ { return __a->is_lock_free(); }
+
+ template<typename _ITp>
+- __always_inline bool
++ __libitm_always_inline bool
+ atomic_is_lock_free(const volatile atomic<_ITp>* __a) noexcept
+ { return __a->is_lock_free(); }
+
+ template<typename _ITp>
+- __always_inline void
++ __libitm_always_inline void
+ atomic_init(atomic<_ITp>* __a, _ITp __i) noexcept;
+
+ template<typename _ITp>
+- __always_inline void
++ __libitm_always_inline void
+ atomic_init(volatile atomic<_ITp>* __a, _ITp __i) noexcept;
+
+ template<typename _ITp>
+- __always_inline void
++ __libitm_always_inline void
+ atomic_store_explicit(atomic<_ITp>* __a, _ITp __i,
+ memory_order __m) noexcept
+ { __a->store(__i, __m); }
+
+ template<typename _ITp>
+- __always_inline void
++ __libitm_always_inline void
+ atomic_store_explicit(volatile atomic<_ITp>* __a, _ITp __i,
+ memory_order __m) noexcept
+ { __a->store(__i, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_load_explicit(const atomic<_ITp>* __a, memory_order __m) noexcept
+ { return __a->load(__m); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_load_explicit(const volatile atomic<_ITp>* __a,
+ memory_order __m) noexcept
+ { return __a->load(__m); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_exchange_explicit(atomic<_ITp>* __a, _ITp __i,
+ memory_order __m) noexcept
+ { return __a->exchange(__i, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_exchange_explicit(volatile atomic<_ITp>* __a, _ITp __i,
+ memory_order __m) noexcept
+ { return __a->exchange(__i, __m); }
+
+ template<typename _ITp>
+- __always_inline bool
++ __libitm_always_inline bool
+ atomic_compare_exchange_weak_explicit(atomic<_ITp>* __a,
+ _ITp* __i1, _ITp __i2,
+ memory_order __m1,
+@@ -1643,7 +1642,7 @@
+ { return __a->compare_exchange_weak(*__i1, __i2, __m1, __m2); }
+
+ template<typename _ITp>
+- __always_inline bool
++ __libitm_always_inline bool
+ atomic_compare_exchange_weak_explicit(volatile atomic<_ITp>* __a,
+ _ITp* __i1, _ITp __i2,
+ memory_order __m1,
+@@ -1651,7 +1650,7 @@
+ { return __a->compare_exchange_weak(*__i1, __i2, __m1, __m2); }
+
+ template<typename _ITp>
+- __always_inline bool
++ __libitm_always_inline bool
+ atomic_compare_exchange_strong_explicit(atomic<_ITp>* __a,
+ _ITp* __i1, _ITp __i2,
+ memory_order __m1,
+@@ -1659,7 +1658,7 @@
+ { return __a->compare_exchange_strong(*__i1, __i2, __m1, __m2); }
+
+ template<typename _ITp>
+- __always_inline bool
++ __libitm_always_inline bool
+ atomic_compare_exchange_strong_explicit(volatile atomic<_ITp>* __a,
+ _ITp* __i1, _ITp __i2,
+ memory_order __m1,
+@@ -1668,37 +1667,37 @@
+
+
+ template<typename _ITp>
+- __always_inline void
++ __libitm_always_inline void
+ atomic_store(atomic<_ITp>* __a, _ITp __i) noexcept
+ { atomic_store_explicit(__a, __i, memory_order_seq_cst); }
+
+ template<typename _ITp>
+- __always_inline void
++ __libitm_always_inline void
+ atomic_store(volatile atomic<_ITp>* __a, _ITp __i) noexcept
+ { atomic_store_explicit(__a, __i, memory_order_seq_cst); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_load(const atomic<_ITp>* __a) noexcept
+ { return atomic_load_explicit(__a, memory_order_seq_cst); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_load(const volatile atomic<_ITp>* __a) noexcept
+ { return atomic_load_explicit(__a, memory_order_seq_cst); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_exchange(atomic<_ITp>* __a, _ITp __i) noexcept
+ { return atomic_exchange_explicit(__a, __i, memory_order_seq_cst); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_exchange(volatile atomic<_ITp>* __a, _ITp __i) noexcept
+ { return atomic_exchange_explicit(__a, __i, memory_order_seq_cst); }
+
+ template<typename _ITp>
+- __always_inline bool
++ __libitm_always_inline bool
+ atomic_compare_exchange_weak(atomic<_ITp>* __a,
+ _ITp* __i1, _ITp __i2) noexcept
+ {
+@@ -1708,7 +1707,7 @@
+ }
+
+ template<typename _ITp>
+- __always_inline bool
++ __libitm_always_inline bool
+ atomic_compare_exchange_weak(volatile atomic<_ITp>* __a,
+ _ITp* __i1, _ITp __i2) noexcept
+ {
+@@ -1718,7 +1717,7 @@
+ }
+
+ template<typename _ITp>
+- __always_inline bool
++ __libitm_always_inline bool
+ atomic_compare_exchange_strong(atomic<_ITp>* __a,
+ _ITp* __i1, _ITp __i2) noexcept
+ {
+@@ -1728,7 +1727,7 @@
+ }
+
+ template<typename _ITp>
+- __always_inline bool
++ __libitm_always_inline bool
+ atomic_compare_exchange_strong(volatile atomic<_ITp>* __a,
+ _ITp* __i1, _ITp __i2) noexcept
+ {
+@@ -1742,158 +1741,158 @@
+ // intergral types as specified in the standard, excluding address
+ // types.
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_add_explicit(__atomic_base<_ITp>* __a, _ITp __i,
+ memory_order __m) noexcept
+ { return __a->fetch_add(__i, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_add_explicit(volatile __atomic_base<_ITp>* __a, _ITp __i,
+ memory_order __m) noexcept
+ { return __a->fetch_add(__i, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_sub_explicit(__atomic_base<_ITp>* __a, _ITp __i,
+ memory_order __m) noexcept
+ { return __a->fetch_sub(__i, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_sub_explicit(volatile __atomic_base<_ITp>* __a, _ITp __i,
+ memory_order __m) noexcept
+ { return __a->fetch_sub(__i, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_and_explicit(__atomic_base<_ITp>* __a, _ITp __i,
+ memory_order __m) noexcept
+ { return __a->fetch_and(__i, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_and_explicit(volatile __atomic_base<_ITp>* __a, _ITp __i,
+ memory_order __m) noexcept
+ { return __a->fetch_and(__i, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_or_explicit(__atomic_base<_ITp>* __a, _ITp __i,
+ memory_order __m) noexcept
+ { return __a->fetch_or(__i, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_or_explicit(volatile __atomic_base<_ITp>* __a, _ITp __i,
+ memory_order __m) noexcept
+ { return __a->fetch_or(__i, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_xor_explicit(__atomic_base<_ITp>* __a, _ITp __i,
+ memory_order __m) noexcept
+ { return __a->fetch_xor(__i, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_xor_explicit(volatile __atomic_base<_ITp>* __a, _ITp __i,
+ memory_order __m) noexcept
+ { return __a->fetch_xor(__i, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_add(__atomic_base<_ITp>* __a, _ITp __i) noexcept
+ { return atomic_fetch_add_explicit(__a, __i, memory_order_seq_cst); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_add(volatile __atomic_base<_ITp>* __a, _ITp __i) noexcept
+ { return atomic_fetch_add_explicit(__a, __i, memory_order_seq_cst); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_sub(__atomic_base<_ITp>* __a, _ITp __i) noexcept
+ { return atomic_fetch_sub_explicit(__a, __i, memory_order_seq_cst); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_sub(volatile __atomic_base<_ITp>* __a, _ITp __i) noexcept
+ { return atomic_fetch_sub_explicit(__a, __i, memory_order_seq_cst); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_and(__atomic_base<_ITp>* __a, _ITp __i) noexcept
+ { return atomic_fetch_and_explicit(__a, __i, memory_order_seq_cst); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_and(volatile __atomic_base<_ITp>* __a, _ITp __i) noexcept
+ { return atomic_fetch_and_explicit(__a, __i, memory_order_seq_cst); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_or(__atomic_base<_ITp>* __a, _ITp __i) noexcept
+ { return atomic_fetch_or_explicit(__a, __i, memory_order_seq_cst); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_or(volatile __atomic_base<_ITp>* __a, _ITp __i) noexcept
+ { return atomic_fetch_or_explicit(__a, __i, memory_order_seq_cst); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_xor(__atomic_base<_ITp>* __a, _ITp __i) noexcept
+ { return atomic_fetch_xor_explicit(__a, __i, memory_order_seq_cst); }
+
+ template<typename _ITp>
+- __always_inline _ITp
++ __libitm_always_inline _ITp
+ atomic_fetch_xor(volatile __atomic_base<_ITp>* __a, _ITp __i) noexcept
+ { return atomic_fetch_xor_explicit(__a, __i, memory_order_seq_cst); }
+
+
+ // Partial specializations for pointers.
+ template<typename _ITp>
+- __always_inline _ITp*
++ __libitm_always_inline _ITp*
+ atomic_fetch_add_explicit(atomic<_ITp*>* __a, ptrdiff_t __d,
+ memory_order __m) noexcept
+ { return __a->fetch_add(__d, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp*
++ __libitm_always_inline _ITp*
+ atomic_fetch_add_explicit(volatile atomic<_ITp*>* __a, ptrdiff_t __d,
+ memory_order __m) noexcept
+ { return __a->fetch_add(__d, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp*
++ __libitm_always_inline _ITp*
+ atomic_fetch_add(volatile atomic<_ITp*>* __a, ptrdiff_t __d) noexcept
+ { return __a->fetch_add(__d); }
+
+ template<typename _ITp>
+- __always_inline _ITp*
++ __libitm_always_inline _ITp*
+ atomic_fetch_add(atomic<_ITp*>* __a, ptrdiff_t __d) noexcept
+ { return __a->fetch_add(__d); }
+
+ template<typename _ITp>
+- __always_inline _ITp*
++ __libitm_always_inline _ITp*
+ atomic_fetch_sub_explicit(volatile atomic<_ITp*>* __a,
+ ptrdiff_t __d, memory_order __m) noexcept
+ { return __a->fetch_sub(__d, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp*
++ __libitm_always_inline _ITp*
+ atomic_fetch_sub_explicit(atomic<_ITp*>* __a, ptrdiff_t __d,
+ memory_order __m) noexcept
+ { return __a->fetch_sub(__d, __m); }
+
+ template<typename _ITp>
+- __always_inline _ITp*
++ __libitm_always_inline _ITp*
+ atomic_fetch_sub(volatile atomic<_ITp*>* __a, ptrdiff_t __d) noexcept
+ { return __a->fetch_sub(__d); }
+
+ template<typename _ITp>
+- __always_inline _ITp*
++ __libitm_always_inline _ITp*
+ atomic_fetch_sub(atomic<_ITp*>* __a, ptrdiff_t __d) noexcept
+ { return __a->fetch_sub(__d); }
+ // @} group atomics
+++ /dev/null
-2007-07-22 Roland McGrath <roland@redhat.com>
-
- * config/rs6000/sysv4.h (LINK_EH_SPEC): Add --build-id for
- non-relocatable link.
- * config/linux.h (LINK_EH_SPEC): Likewise.
- * config/alpha/elf.h (LINK_EH_SPEC): Likewise.
- * config/ia64/linux.h (LINK_EH_SPEC): Likewise.
-
---- gcc/config/rs6000/sysv4.h.~1~
-+++ gcc/config/rs6000/sysv4.h
-@@ -906,7 +906,7 @@ extern int fixuplabelno;
- %{!dynamic-linker:-dynamic-linker " LINUX_DYNAMIC_LINKER "}}}"
-
- #if defined(HAVE_LD_EH_FRAME_HDR)
--# define LINK_EH_SPEC "%{!static:--eh-frame-hdr} "
-+# define LINK_EH_SPEC "%{!static:--eh-frame-hdr} %{!r:--build-id} "
- #endif
-
- #define CPP_OS_LINUX_SPEC "-D__unix__ -D__gnu_linux__ -D__linux__ \
---- gcc/config/linux.h.~1~
-+++ gcc/config/linux.h
-@@ -85,7 +85,7 @@ Boston, MA 02110-1301, USA. */
- } while (0)
-
- #if defined(HAVE_LD_EH_FRAME_HDR)
--#define LINK_EH_SPEC "%{!static:--eh-frame-hdr} "
-+#define LINK_EH_SPEC "%{!static:--eh-frame-hdr} %{!r:--build-id} "
- #endif
-
- /* Define this so we can compile MS code for use with WINE. */
---- gcc/config/alpha/elf.h.~1~
-+++ gcc/config/alpha/elf.h
-@@ -421,7 +421,7 @@ extern int alpha_this_gpdisp_sequence_nu
- I imagine that other systems will catch up. In the meantime, it
- doesn't harm to make sure that the data exists to be used later. */
- #if defined(HAVE_LD_EH_FRAME_HDR)
--#define LINK_EH_SPEC "%{!static:--eh-frame-hdr} "
-+#define LINK_EH_SPEC "%{!static:--eh-frame-hdr} %{!r:--build-id} "
- #endif
-
- /* A C statement (sans semicolon) to output to the stdio stream STREAM
---- gcc/config/ia64/linux.h.~1~
-+++ gcc/config/ia64/linux.h
-@@ -56,7 +56,7 @@ do { \
- Signalize that because we have fde-glibc, we don't need all C shared libs
- linked against -lgcc_s. */
- #undef LINK_EH_SPEC
--#define LINK_EH_SPEC ""
-+#define LINK_EH_SPEC "%{!r:--build-id} "
-
- #define MD_UNWIND_SUPPORT "config/ia64/linux-unwind.h"
-
+++ /dev/null
-2007-10-02 Jakub Jelinek <jakub@redhat.com>
-
- * decl.c (duplicate_decls): When redeclaring a builtin function,
- keep the merged decl builtin whenever types match, even if new
- decl defines a function.
-
- * gcc.dg/builtins-65.c: New test.
- * g++.dg/ext/builtin10.C: New test.
-
---- gcc/cp/decl.c.jj 2007-10-01 22:11:09.000000000 +0200
-+++ gcc/cp/decl.c 2007-10-02 11:39:46.000000000 +0200
-@@ -2001,23 +2001,21 @@ duplicate_decls (tree newdecl, tree oldd
- DECL_ARGUMENTS (olddecl) = DECL_ARGUMENTS (newdecl);
- DECL_RESULT (olddecl) = DECL_RESULT (newdecl);
- }
-+ /* If redeclaring a builtin function, it stays built in. */
-+ if (types_match && DECL_BUILT_IN (olddecl))
-+ {
-+ DECL_BUILT_IN_CLASS (newdecl) = DECL_BUILT_IN_CLASS (olddecl);
-+ DECL_FUNCTION_CODE (newdecl) = DECL_FUNCTION_CODE (olddecl);
-+ /* If we're keeping the built-in definition, keep the rtl,
-+ regardless of declaration matches. */
-+ COPY_DECL_RTL (olddecl, newdecl);
-+ }
- if (new_defines_function)
- /* If defining a function declared with other language
- linkage, use the previously declared language linkage. */
- SET_DECL_LANGUAGE (newdecl, DECL_LANGUAGE (olddecl));
- else if (types_match)
- {
-- /* If redeclaring a builtin function, and not a definition,
-- it stays built in. */
-- if (DECL_BUILT_IN (olddecl))
-- {
-- DECL_BUILT_IN_CLASS (newdecl) = DECL_BUILT_IN_CLASS (olddecl);
-- DECL_FUNCTION_CODE (newdecl) = DECL_FUNCTION_CODE (olddecl);
-- /* If we're keeping the built-in definition, keep the rtl,
-- regardless of declaration matches. */
-- COPY_DECL_RTL (olddecl, newdecl);
-- }
--
- DECL_RESULT (newdecl) = DECL_RESULT (olddecl);
- /* Don't clear out the arguments if we're just redeclaring a
- function. */
---- gcc/testsuite/gcc.dg/builtins-65.c.jj 2007-10-02 11:23:51.000000000 +0200
-+++ gcc/testsuite/gcc.dg/builtins-65.c 2007-10-02 11:24:12.000000000 +0200
-@@ -0,0 +1,25 @@
-+/* { dg-do compile } */
-+/* { dg-options "-O2" } */
-+
-+typedef __SIZE_TYPE__ size_t;
-+extern void __chk_fail (void);
-+extern int snprintf (char *, size_t, const char *, ...);
-+extern inline __attribute__((gnu_inline, always_inline)) int snprintf (char *a, size_t b, const char *fmt, ...)
-+{
-+ if (__builtin_object_size (a, 0) != -1UL && __builtin_object_size (a, 0) < b)
-+ __chk_fail ();
-+ return __builtin_snprintf (a, b, fmt, __builtin_va_arg_pack ());
-+}
-+extern int snprintf (char *, size_t, const char *, ...) __asm ("mysnprintf");
-+
-+char buf[10];
-+
-+int
-+main (void)
-+{
-+ snprintf (buf, 10, "%d%d\n", 10, 10);
-+ return 0;
-+}
-+
-+/* { dg-final { scan-assembler "mysnprintf" } } */
-+/* { dg-final { scan-assembler-not "__chk_fail" } } */
---- gcc/testsuite/g++.dg/ext/builtin10.C.jj 2007-10-02 11:19:45.000000000 +0200
-+++ gcc/testsuite/g++.dg/ext/builtin10.C 2007-10-02 11:23:26.000000000 +0200
-@@ -0,0 +1,27 @@
-+// { dg-do compile }
-+// { dg-options "-O2" }
-+
-+typedef __SIZE_TYPE__ size_t;
-+extern "C" {
-+extern void __chk_fail (void);
-+extern int snprintf (char *, size_t, const char *, ...);
-+extern inline __attribute__((gnu_inline, always_inline)) int snprintf (char *a, size_t b, const char *fmt, ...)
-+{
-+ if (__builtin_object_size (a, 0) != -1UL && __builtin_object_size (a, 0) < b)
-+ __chk_fail ();
-+ return __builtin_snprintf (a, b, fmt, __builtin_va_arg_pack ());
-+}
-+extern int snprintf (char *, size_t, const char *, ...) __asm ("mysnprintf");
-+}
-+
-+char buf[10];
-+
-+int
-+main (void)
-+{
-+ snprintf (buf, 10, "%d%d\n", 10, 10);
-+ return 0;
-+}
-+
-+// { dg-final { scan-assembler "mysnprintf" } }
-+// { dg-final { scan-assembler-not "__chk_fail" } }
+++ /dev/null
-Build i386.rpm libgomp and libsupc++.a(guard.o) as i486+, pre-i486
-hardware isn't supported because NPTL doesn't support it anyway.
-
---- libgomp/configure.tgt.jj 2008-01-10 20:53:48.000000000 +0100
-+++ libgomp/configure.tgt 2008-03-27 12:44:51.000000000 +0100
-@@ -44,14 +44,14 @@ if test $enable_linux_futex = yes; then
- ;;
-
- # Note that bare i386 is not included here. We need cmpxchg.
-- i[456]86-*-linux*)
-+ i[3456]86-*-linux*)
- config_path="linux/x86 linux posix"
- case " ${CC} ${CFLAGS} " in
- *" -m64 "*)
- ;;
- *)
- if test -z "$with_arch"; then
-- XCFLAGS="${XCFLAGS} -march=i486 -mtune=${target_cpu}"
-+ XCFLAGS="${XCFLAGS} -march=i486 -mtune=generic"
- fi
- esac
- ;;
-@@ -63,7 +63,7 @@ if test $enable_linux_futex = yes; then
- config_path="linux/x86 linux posix"
- case " ${CC} ${CFLAGS} " in
- *" -m32 "*)
-- XCFLAGS="${XCFLAGS} -march=i486 -mtune=i686"
-+ XCFLAGS="${XCFLAGS} -march=i486 -mtune=generic"
- ;;
- esac
- ;;
---- libstdc++-v3/libsupc++/guard.cc.jj 2008-03-01 00:58:24.000000000 +0100
-+++ libstdc++-v3/libsupc++/guard.cc 2008-03-27 14:08:44.000000000 +0100
-@@ -35,6 +35,27 @@
- #include <new>
- #include <ext/atomicity.h>
- #include <ext/concurrence.h>
-+#if defined __i386__ && !defined _GLIBCXX_ATOMIC_BUILTINS_4
-+# define _GLIBCXX_ATOMIC_BUILTINS_4 1
-+# define __sync_val_compare_and_swap(a, b, c) \
-+ ({ \
-+ typedef char sltast[sizeof (*a) == sizeof (int) ? 1 : -1]; \
-+ int sltas; \
-+ __asm __volatile ("lock; cmpxchgl %3, (%1)" \
-+ : "=a" (sltas) \
-+ : "r" (a), "0" (b), "r" (c) : "memory"); \
-+ sltas; \
-+ })
-+# define __sync_lock_test_and_set(a, b) \
-+ ({ \
-+ typedef char sltast[sizeof (*a) == sizeof (int) ? 1 : -1]; \
-+ int sltas; \
-+ __asm __volatile ("xchgl (%1), %0" \
-+ : "=r" (sltas) \
-+ : "r" (a), "0" (b) : "memory"); \
-+ sltas; \
-+ })
-+#endif
- #if defined(__GTHREADS) && defined(__GTHREAD_HAS_COND) \
- && defined(_GLIBCXX_ATOMIC_BUILTINS_4) && defined(_GLIBCXX_HAVE_LINUX_FUTEX)
- # include <climits>
+++ /dev/null
-2010-02-08 Roland McGrath <roland@redhat.com>
-
- * config/rs6000/sysv4.h (LINK_EH_SPEC): Pass --no-add-needed to the
- linker.
- * config/linux.h (LINK_EH_SPEC): Likewise.
- * config/alpha/elf.h (LINK_EH_SPEC): Likewise.
- * config/ia64/linux.h (LINK_EH_SPEC): Likewise.
-
---- gcc/config/alpha/elf.h.~1~
-+++ gcc/config/alpha/elf.h
-@@ -421,7 +421,7 @@ extern int alpha_this_gpdisp_sequence_nu
- I imagine that other systems will catch up. In the meantime, it
- doesn't harm to make sure that the data exists to be used later. */
- #if defined(HAVE_LD_EH_FRAME_HDR)
--#define LINK_EH_SPEC "%{!static:--eh-frame-hdr} %{!r:--build-id} "
-+#define LINK_EH_SPEC "--no-add-needed %{!static:--eh-frame-hdr} %{!r:--build-id} "
- #endif
-
- /* A C statement (sans semicolon) to output to the stdio stream STREAM
---- gcc/config/ia64/linux.h.~1~
-+++ gcc/config/ia64/linux.h
-@@ -58,7 +58,7 @@ do { \
- Signalize that because we have fde-glibc, we don't need all C shared libs
- linked against -lgcc_s. */
- #undef LINK_EH_SPEC
--#define LINK_EH_SPEC "%{!r:--build-id} "
-+#define LINK_EH_SPEC "--no-add-needed %{!r:--build-id} "
-
- #define MD_UNWIND_SUPPORT "config/ia64/linux-unwind.h"
-
---- gcc/config/linux.h.~1~
-+++ gcc/config/linux.h
-@@ -89,7 +89,7 @@ see the files COPYING3 and COPYING.RUNTI
- } while (0)
-
- #if defined(HAVE_LD_EH_FRAME_HDR)
--#define LINK_EH_SPEC "%{!static:--eh-frame-hdr} %{!r:--build-id} "
-+#define LINK_EH_SPEC "--no-add-needed %{!static:--eh-frame-hdr} %{!r:--build-id} "
- #endif
-
- /* Define this so we can compile MS code for use with WINE. */
---- gcc/config/rs6000/sysv4.h.~1~
-+++ gcc/config/rs6000/sysv4.h
-@@ -917,7 +917,7 @@ SVR4_ASM_SPEC \
- %{!dynamic-linker:-dynamic-linker " LINUX_DYNAMIC_LINKER "}}}"
-
- #if defined(HAVE_LD_EH_FRAME_HDR)
--# define LINK_EH_SPEC "%{!static:--eh-frame-hdr} %{!r:--build-id} "
-+# define LINK_EH_SPEC "--no-add-needed %{!static:--eh-frame-hdr} %{!r:--build-id} "
- #endif
-
- #define CPP_OS_LINUX_SPEC "-D__unix__ -D__gnu_linux__ -D__linux__ \
+++ /dev/null
-2007-11-06 Jakub Jelinek <jakub@redhat.com>
-
- PR tree-optimization/33763
- * gcc.dg/pr33763.c: New test.
- * g++.dg/opt/inline13.C: New test.
-
-2007-11-06 Jan Hubicka <jh@suse.cz>
-
- PR tree-optimization/33763
- * tree-inline.c (expand_call_inline): Silently ignore always_inline
- attribute for redefined extern inline functions.
-
---- gcc/tree-inline.c.jj 2007-11-06 09:29:04.000000000 +0100
-+++ gcc/tree-inline.c 2007-11-06 16:19:12.000000000 +0100
-@@ -3157,6 +3157,12 @@ expand_call_inline (basic_block bb, gimp
- goto egress;
-
- if (lookup_attribute ("always_inline", DECL_ATTRIBUTES (fn))
-+ /* For extern inline functions that get redefined we always
-+ silently ignored alway_inline flag. Better behaviour would
-+ be to be able to keep both bodies and use extern inline body
-+ for inlining, but we can't do that because frontends overwrite
-+ the body. */
-+ && !cg_edge->callee->local.redefined_extern_inline
- /* Avoid warnings during early inline pass. */
- && cgraph_global_info_ready)
- {
---- gcc/testsuite/gcc.dg/pr33763.c.jj 2007-11-06 16:19:12.000000000 +0100
-+++ gcc/testsuite/gcc.dg/pr33763.c 2007-11-06 16:19:12.000000000 +0100
-@@ -0,0 +1,60 @@
-+/* PR tree-optimization/33763 */
-+/* { dg-do compile } */
-+/* { dg-options "-O2" } */
-+
-+typedef struct
-+{
-+ void *a;
-+ void *b;
-+} T;
-+extern void *foo (const char *, const char *);
-+extern void *bar (void *, const char *, T);
-+extern int baz (const char *, int);
-+
-+extern inline __attribute__ ((always_inline, gnu_inline)) int
-+baz (const char *x, int y)
-+{
-+ return 2;
-+}
-+
-+int
-+baz (const char *x, int y)
-+{
-+ return 1;
-+}
-+
-+int xa, xb;
-+
-+static void *
-+inl (const char *x, const char *y)
-+{
-+ T t = { &xa, &xb };
-+ int *f = (int *) __builtin_malloc (sizeof (int));
-+ const char *z;
-+ int o = 0;
-+ void *r = 0;
-+
-+ for (z = y; *z; z++)
-+ {
-+ if (*z == 'r')
-+ o |= 1;
-+ if (*z == 'w')
-+ o |= 2;
-+ }
-+ if (o == 1)
-+ *f = baz (x, 0);
-+ if (o == 2)
-+ *f = baz (x, 1);
-+ if (o == 3)
-+ *f = baz (x, 2);
-+
-+ if (o && *f > 0)
-+ r = bar (f, "w", t);
-+ return r;
-+}
-+
-+void *
-+foo (const char *x, const char *y)
-+{
-+ return inl (x, y);
-+}
---- gcc/testsuite/g++.dg/opt/inline13.C.jj 2007-11-06 16:20:20.000000000 +0100
-+++ gcc/testsuite/g++.dg/opt/inline13.C 2007-11-06 16:21:30.000000000 +0100
-@@ -0,0 +1,60 @@
-+// PR tree-optimization/33763
-+// { dg-do compile }
-+// { dg-options "-O2" }
-+
-+typedef struct
-+{
-+ void *a;
-+ void *b;
-+} T;
-+extern void *foo (const char *, const char *);
-+extern void *bar (void *, const char *, T);
-+extern int baz (const char *, int);
-+
-+extern inline __attribute__ ((always_inline, gnu_inline)) int
-+baz (const char *x, int y)
-+{
-+ return 2;
-+}
-+
-+int
-+baz (const char *x, int y)
-+{
-+ return 1;
-+}
-+
-+int xa, xb;
-+
-+static void *
-+inl (const char *x, const char *y)
-+{
-+ T t = { &xa, &xb };
-+ int *f = (int *) __builtin_malloc (sizeof (int));
-+ const char *z;
-+ int o = 0;
-+ void *r = 0;
-+
-+ for (z = y; *z; z++)
-+ {
-+ if (*z == 'r')
-+ o |= 1;
-+ if (*z == 'w')
-+ o |= 2;
-+ }
-+ if (o == 1)
-+ *f = baz (x, 0);
-+ if (o == 2)
-+ *f = baz (x, 1);
-+ if (o == 3)
-+ *f = baz (x, 2);
-+
-+ if (o && *f > 0)
-+ r = bar (f, "w", t);
-+ return r;
-+}
-+
-+void *
-+foo (const char *x, const char *y)
-+{
-+ return inl (x, y);
-+}
+++ /dev/null
-2007-10-16 Jakub Jelinek <jakub@redhat.com>
-
- * Makefile.am (libgcj_tools_la_LIBADD): Add.
- * Makefile.in: Regenerated.
-
---- libjava/Makefile.am.jj 2009-05-06 08:14:50.000000000 +0200
-+++ libjava/Makefile.am 2009-05-06 10:26:43.000000000 +0200
-@@ -314,6 +314,8 @@ libgcj_tools_la_SOURCES = classpath/tool
- libgcj_tools_la_GCJFLAGS = $(AM_GCJFLAGS) -findirect-dispatch \
- -fno-bootstrap-classes -fno-indirect-classes \
- -fsource-filename=$(here)/classpath/tools/all-classes.lst
-+## See jv_convert_LDADD.
-+libgcj_tools_la_LIBADD = -L$(here)/.libs libgcj.la
- libgcj_tools_la_LDFLAGS = -rpath $(toolexeclibdir) \
- -version-info `grep -v '^\#' $(srcdir)/libtool-version` \
- $(LIBGCJ_LD_SYMBOLIC_FUNCTIONS)
---- libjava/Makefile.in.jj 2009-05-06 08:14:49.000000000 +0200
-+++ libjava/Makefile.in 2009-05-06 10:27:18.000000000 +0200
-@@ -160,7 +160,6 @@ am__objects_1 = gnu/gcj/xlib/lib_gnu_awt
- am_lib_gnu_awt_xlib_la_OBJECTS = $(am__objects_1)
- lib_gnu_awt_xlib_la_OBJECTS = $(am_lib_gnu_awt_xlib_la_OBJECTS)
- @XLIB_AWT_TRUE@am_lib_gnu_awt_xlib_la_rpath = -rpath $(toolexeclibdir)
--libgcj_tools_la_LIBADD =
- am_libgcj_tools_la_OBJECTS = classpath/tools/libgcj_tools_la-tools.lo
- libgcj_tools_la_OBJECTS = $(am_libgcj_tools_la_OBJECTS)
- @INTERPRETER_TRUE@am__DEPENDENCIES_1 = gnu/classpath/jdwp.lo \
-@@ -1041,6 +1040,7 @@ libgcj_tools_la_GCJFLAGS = $(AM_GCJFLAGS
- -fno-bootstrap-classes -fno-indirect-classes \
- -fsource-filename=$(here)/classpath/tools/all-classes.lst
-
-+libgcj_tools_la_LIBADD = -L$(here)/.libs libgcj.la
- libgcj_tools_la_LDFLAGS = -rpath $(toolexeclibdir) \
- -version-info `grep -v '^\#' $(srcdir)/libtool-version` \
- $(LIBGCJ_LD_SYMBOLIC_FUNCTIONS)
+++ /dev/null
-2010-07-22 Jakub Jelinek <jakub@redhat.com>
-
- * gimplify.c (enum gimplify_omp_var_data): Add
- GOVD_THREADPRIVATE_WARNED.
- (gimplify_bind_expr): Add GOVD_LOCAL | GOVD_SEEN even for global vars.
- (omp_notice_threadprivate_variable): Note used threadprivate vars
- with current function's context in shared clauses.
- (gimplify_adjust_omp_clauses_1): Allow globals with current function's
- context in taskreg shared clause.
- * omp-low.c (lower_rec_input_clauses): For function-local is_global_var
- VAR_DECLs in shared clauses add a decl copy with DECL_VALUE_EXPR
- pointing to the original.
-
- * trans-openmp.c (gfc_omp_private_debug_clause): Return false for
- threadprivate decls.
-
- * gcc.dg/gomp/tls-3.c: New test.
-
---- gcc/fortran/trans-openmp.c.jj 2010-06-24 21:47:09.908230044 +0200
-+++ gcc/fortran/trans-openmp.c 2010-07-26 10:45:15.830229443 +0200
-@@ -351,6 +351,18 @@ gfc_omp_disregard_value_expr (tree decl,
- bool
- gfc_omp_private_debug_clause (tree decl, bool shared)
- {
-+ if (TREE_STATIC (decl) || DECL_EXTERNAL (decl))
-+ {
-+ if (DECL_THREAD_LOCAL_P (decl))
-+ return false;
-+ if (DECL_HAS_VALUE_EXPR_P (decl))
-+ {
-+ tree value = get_base_address (DECL_VALUE_EXPR (decl));
-+ if (value && DECL_P (value) && DECL_THREAD_LOCAL_P (value))
-+ return false;
-+ }
-+ }
-+
- if (GFC_DECL_CRAY_POINTEE (decl))
- return true;
-
---- gcc/gimplify.c.jj 2010-07-09 09:01:37.049604412 +0200
-+++ gcc/gimplify.c 2010-07-26 10:50:05.646291216 +0200
-@@ -66,6 +66,7 @@ enum gimplify_omp_var_data
- GOVD_LOCAL = 128,
- GOVD_DEBUG_PRIVATE = 256,
- GOVD_PRIVATE_OUTER_REF = 512,
-+ GOVD_THREADPRIVATE_WARNED = 1024,
- GOVD_DATA_SHARE_CLASS = (GOVD_SHARED | GOVD_PRIVATE | GOVD_FIRSTPRIVATE
- | GOVD_LASTPRIVATE | GOVD_REDUCTION | GOVD_LOCAL)
- };
-@@ -1234,7 +1235,7 @@ gimplify_bind_expr (tree *expr_p, gimple
- struct gimplify_omp_ctx *ctx = gimplify_omp_ctxp;
-
- /* Mark variable as local. */
-- if (ctx && !is_global_var (t)
-+ if (ctx
- && (! DECL_SEEN_IN_BIND_EXPR_P (t)
- || splay_tree_lookup (ctx->variables,
- (splay_tree_key) t) == NULL))
-@@ -5339,18 +5340,36 @@ omp_notice_threadprivate_variable (struc
- {
- splay_tree_node n;
-
-- if (ctx->region_type != ORT_UNTIED_TASK)
-+ while (ctx && ctx->region_type == ORT_WORKSHARE)
-+ {
-+ n = splay_tree_lookup (ctx->variables, (splay_tree_key)decl);
-+ if (n != NULL)
-+ {
-+ gcc_assert (n->value & GOVD_LOCAL);
-+ return false;
-+ }
-+ ctx = ctx->outer_context;
-+ }
-+ if (ctx == NULL)
- return false;
-+
- n = splay_tree_lookup (ctx->variables, (splay_tree_key)decl);
- if (n == NULL)
-+ n = splay_tree_insert (ctx->variables, (splay_tree_key)decl,
-+ DECL_CONTEXT (decl) == current_function_decl
-+ ? GOVD_SHARED | GOVD_SEEN : 0);
-+ if (ctx->region_type == ORT_UNTIED_TASK
-+ && (n->value & GOVD_THREADPRIVATE_WARNED) == 0)
- {
- error ("threadprivate variable %qs used in untied task",
- IDENTIFIER_POINTER (DECL_NAME (decl)));
- error ("%Henclosing task", &ctx->location);
-- splay_tree_insert (ctx->variables, (splay_tree_key)decl, 0);
-+ n->value |= GOVD_THREADPRIVATE_WARNED;
- }
- if (decl2)
-- splay_tree_insert (ctx->variables, (splay_tree_key)decl2, 0);
-+ splay_tree_insert (ctx->variables, (splay_tree_key)decl2,
-+ DECL_CONTEXT (decl2) == current_function_decl
-+ ? GOVD_SHARED | GOVD_SEEN : 0);
- return false;
- }
-
-@@ -5779,7 +5798,9 @@ gimplify_adjust_omp_clauses_1 (splay_tre
- break;
- ctx = ctx->outer_context;
- }
-- if (ctx == NULL)
-+ if (ctx == NULL
-+ && (DECL_CONTEXT (decl) != current_function_decl
-+ || gimplify_omp_ctxp->region_type == ORT_WORKSHARE))
- return 0;
- }
- code = OMP_CLAUSE_SHARED;
---- gcc/omp-low.c.jj 2010-06-11 11:06:00.913659301 +0200
-+++ gcc/omp-low.c 2010-07-26 10:45:15.866229447 +0200
-@@ -2222,6 +2222,17 @@ lower_rec_input_clauses (tree clauses, g
- continue;
- break;
- case OMP_CLAUSE_SHARED:
-+ if (pass == 0
-+ && is_global_var (OMP_CLAUSE_DECL (c))
-+ && (DECL_CONTEXT (OMP_CLAUSE_DECL (c))
-+ == current_function_decl)
-+ && is_taskreg_ctx (ctx)
-+ && !DECL_IGNORED_P (OMP_CLAUSE_DECL (c)))
-+ {
-+ new_var = omp_copy_decl_1 (OMP_CLAUSE_DECL (c), ctx);
-+ SET_DECL_VALUE_EXPR (new_var, OMP_CLAUSE_DECL (c));
-+ DECL_HAS_VALUE_EXPR_P (new_var) = 1;
-+ }
- if (maybe_lookup_decl (OMP_CLAUSE_DECL (c), ctx) == NULL)
- {
- gcc_assert (is_global_var (OMP_CLAUSE_DECL (c)));
---- gcc/testsuite/gcc.dg/gomp/tls-3.c.jj 2010-07-26 10:45:15.868228753 +0200
-+++ gcc/testsuite/gcc.dg/gomp/tls-3.c 2010-07-26 10:45:15.868228753 +0200
-@@ -0,0 +1,21 @@
-+/* { dg-do compile } */
-+/* { dg-require-effective-target tls_native } */
-+
-+int thr;
-+#pragma omp threadprivate(thr)
-+
-+void
-+foo (void)
-+{
-+ #pragma omp task untied /* { dg-error "enclosing task" } */
-+ {
-+ static int thr2;
-+ #pragma omp threadprivate(thr2)
-+ static int thr3;
-+ #pragma omp threadprivate(thr3)
-+ thr++; /* { dg-error "used in untied task" } */
-+ thr2++; /* { dg-error "used in untied task" } */
-+ thr++;
-+ thr2++;
-+ }
-+}
+++ /dev/null
-2010-07-07 Jakub Jelinek <jakub@redhat.com>
-
- * tree-sra.c (sra_build_assignment): Don't add BIT_XOR_EXPR/MINUS_EXPR
- of signbit if signbit is the most significant bit of utype already.
-
- * gcc.c-torture/execute/20100707-1.c: New test.
-
---- gcc/tree-sra.c.jj 2010-05-13 13:08:52.000000000 +0200
-+++ gcc/tree-sra.c 2010-07-06 19:50:09.000000000 +0200
-@@ -2211,7 +2211,10 @@ sra_build_assignment (tree dst, tree src
-
- /* Perform sign extension, if required.
- ??? This should never be necessary. */
-- if (!unsignedp)
-+ if (!unsignedp
-+ && (TREE_INT_CST_LOW (width) != TYPE_PRECISION (utype)
-+ || (TREE_INT_CST_LOW (width)
-+ != GET_MODE_BITSIZE (TYPE_MODE (utype)))))
- {
- tree signbit = int_const_binop (LSHIFT_EXPR,
- build_int_cst_wide (utype, 1, 0),
---- gcc/testsuite/gcc.c-torture/execute/20100707-1.c 2010-05-27 15:41:40.446237053 +0200
-+++ gcc/testsuite/gcc.c-torture/execute/20100707-1.c 2010-07-06 13:55:35.000000000 +0200
-@@ -0,0 +1,50 @@
-+struct S { int s; };
-+struct T { int w; int h; };
-+int vr;
-+
-+inline struct T
-+bar (const struct S * x)
-+{
-+ struct T t;
-+ t.w = vr;
-+ t.h = x->s;
-+ return t;
-+}
-+
-+__attribute__ ((noinline))
-+void foo (struct S * w, unsigned char *x, int y, int *z[2])
-+{
-+ struct T t;
-+ int i, j, k;
-+ t = bar (w);
-+ k = t.w + 2;
-+ for (i = 0; i <= t.h; i++)
-+ {
-+ int *u = z[i > 0] + 1;
-+ unsigned char *v;
-+ int q = 0;
-+ v = x + k * i + 1;
-+ for (j = 0; j < t.w; j++)
-+ {
-+ int m = u[j];
-+ if (m > y && !q && v[j - k] != 2)
-+ v[j] = 0;
-+ }
-+ }
-+}
-+
-+unsigned char b[64];
-+
-+int
-+main (void)
-+{
-+ int v[32], *z[2];
-+ struct S s;
-+ __builtin_memset (v, 0, sizeof (v));
-+ vr = 16;
-+ s.s = 16;
-+ z[0] = v;
-+ z[1] = v;
-+ foo (&s, b + 32, -1, z);
-+ return 0;
-+}
+++ /dev/null
-2010-04-27 Jakub Jelinek <jakub@redhat.com>
-
- * unwind-dw2.c (_Unwind_DebugHook): Add used attribute.
-
-2009-05-27 Tom Tromey <tromey@redhat.com>
-
- * unwind-dw2.c (_Unwind_DebugHook): New function.
- (uw_install_context): Call _Unwind_DebugHook.
-
---- gcc/unwind-dw2.c (revision 147933)
-+++ gcc/unwind-dw2.c (revision 147934)
-@@ -1473,18 +1473,32 @@ uw_init_context_1 (struct _Unwind_Contex
- context->ra = __builtin_extract_return_addr (outer_ra);
- }
-
-+static void _Unwind_DebugHook (void *, void *)
-+ __attribute__ ((__noinline__, __used__));
-+
-+/* This function is called during unwinding. It is intended as a hook
-+ for a debugger to intercept exceptions. CFA is the CFA of the
-+ target frame. HANDLER is the PC to which control will be
-+ transferred. */
-+static void
-+_Unwind_DebugHook (void *cfa __attribute__ ((__unused__)),
-+ void *handler __attribute__ ((__unused__)))
-+{
-+ asm ("");
-+}
-
- /* Install TARGET into CURRENT so that we can return to it. This is a
- macro because __builtin_eh_return must be invoked in the context of
- our caller. */
-
--#define uw_install_context(CURRENT, TARGET) \
-- do \
-- { \
-- long offset = uw_install_context_1 ((CURRENT), (TARGET)); \
-- void *handler = __builtin_frob_return_addr ((TARGET)->ra); \
-- __builtin_eh_return (offset, handler); \
-- } \
-+#define uw_install_context(CURRENT, TARGET) \
-+ do \
-+ { \
-+ long offset = uw_install_context_1 ((CURRENT), (TARGET)); \
-+ void *handler = __builtin_frob_return_addr ((TARGET)->ra); \
-+ _Unwind_DebugHook ((TARGET)->cfa, handler); \
-+ __builtin_eh_return (offset, handler); \
-+ } \
- while (0)
-
- static long
--- /dev/null
+--- libgomp/configure.tgt.jj 2008-01-10 20:53:48.000000000 +0100
++++ libgomp/configure.tgt 2008-03-27 12:44:51.000000000 +0100
+@@ -67,7 +67,7 @@ if test $enable_linux_futex = yes; then
+ ;;
+ *)
+ if test -z "$with_arch"; then
+- XCFLAGS="${XCFLAGS} -march=i486 -mtune=${target_cpu}"
++ XCFLAGS="${XCFLAGS} -march=i486 -mtune=generic"
+ fi
+ esac
+ ;;
--- /dev/null
+2010-02-08 Roland McGrath <roland@redhat.com>
+
+ * config/rs6000/sysv4.h (LINK_EH_SPEC): Pass --no-add-needed to the
+ linker.
+ * config/gnu-user.h (LINK_EH_SPEC): Likewise.
+ * config/alpha/elf.h (LINK_EH_SPEC): Likewise.
+ * config/ia64/linux.h (LINK_EH_SPEC): Likewise.
+
+--- gcc/config/alpha/elf.h.jj 2011-01-03 12:52:31.118056764 +0100
++++ gcc/config/alpha/elf.h 2011-01-04 18:14:10.931874160 +0100
+@@ -165,5 +165,5 @@ extern int alpha_this_gpdisp_sequence_nu
+ I imagine that other systems will catch up. In the meantime, it
+ doesn't harm to make sure that the data exists to be used later. */
+ #if defined(HAVE_LD_EH_FRAME_HDR)
+-#define LINK_EH_SPEC "%{!static:--eh-frame-hdr} "
++#define LINK_EH_SPEC "--no-add-needed %{!static:--eh-frame-hdr} "
+ #endif
+--- gcc/config/ia64/linux.h.jj 2011-01-03 13:02:11.462994522 +0100
++++ gcc/config/ia64/linux.h 2011-01-04 18:14:10.931874160 +0100
+@@ -77,7 +77,7 @@ do { \
+ Signalize that because we have fde-glibc, we don't need all C shared libs
+ linked against -lgcc_s. */
+ #undef LINK_EH_SPEC
+-#define LINK_EH_SPEC ""
++#define LINK_EH_SPEC "--no-add-needed "
+
+ /* Put all *tf routines in libgcc. */
+ #undef LIBGCC2_HAS_TF_MODE
+--- gcc/config/gnu-user.h.jj 2011-01-03 12:53:03.739057299 +0100
++++ gcc/config/gnu-user.h 2011-01-04 18:14:10.932814884 +0100
+@@ -82,7 +82,7 @@ see the files COPYING3 and COPYING.RUNTI
+ #define LIB_SPEC GNU_USER_TARGET_LIB_SPEC
+
+ #if defined(HAVE_LD_EH_FRAME_HDR)
+-#define LINK_EH_SPEC "%{!static:--eh-frame-hdr} "
++#define LINK_EH_SPEC "--no-add-needed %{!static:--eh-frame-hdr} "
+ #endif
+
+ #undef LINK_GCC_C_SEQUENCE_SPEC
+--- gcc/config/rs6000/sysv4.h.jj 2011-01-03 13:02:18.255994215 +0100
++++ gcc/config/rs6000/sysv4.h 2011-01-04 18:14:10.933888871 +0100
+@@ -820,7 +820,7 @@ extern int fixuplabelno;
+ -dynamic-linker " GNU_USER_DYNAMIC_LINKER "}}"
+
+ #if defined(HAVE_LD_EH_FRAME_HDR)
+-# define LINK_EH_SPEC "%{!static:--eh-frame-hdr} "
++# define LINK_EH_SPEC "--no-add-needed %{!static:--eh-frame-hdr} "
+ #endif
+
+ #define CPP_OS_LINUX_SPEC "-D__unix__ -D__gnu_linux__ -D__linux__ \
--- /dev/null
+2009-03-18 Jakub Jelinek <jakub@redhat.com>
+
+ PR debug/38757
+ * langhooks.h (struct lang_hooks): Add source_language langhook.
+ * langhooks-def.h (LANG_HOOKS_SOURCE_LANGUAGE): Define to NULL.
+ (LANG_HOOKS_INITIALIZER): Add LANG_HOOKS_SOURCE_LANGUAGE.
+ * dwarf2out.c (add_prototyped_attribute): Add DW_AT_prototype
+ also for DW_LANG_{C,C99,ObjC}.
+ (gen_compile_unit_die): Use lang_hooks.source_language () to
+ determine if DW_LANG_C99 or DW_LANG_C89 should be returned.
+c/
+ * c-lang.c (c_source_language): New function.
+ (LANG_HOOKS_SOURCE_LANGUAGE): Define.
+
+--- gcc/langhooks.h.jj 2011-01-03 12:53:05.125745450 +0100
++++ gcc/langhooks.h 2011-01-04 17:59:43.166744926 +0100
+@@ -467,6 +467,10 @@ struct lang_hooks
+ gimplification. */
+ bool deep_unsharing;
+
++ /* Return year of the source language standard version if the FE supports
++ multiple versions of the standard. */
++ int (*source_language) (void);
++
+ /* Whenever you add entries here, make sure you adjust langhooks-def.h
+ and langhooks.c accordingly. */
+ };
+--- gcc/langhooks-def.h.jj 2011-01-03 12:53:05.000000000 +0100
++++ gcc/langhooks-def.h 2011-01-04 18:00:44.858851030 +0100
+@@ -118,6 +118,7 @@ extern void lhd_omp_firstprivatize_type_
+ #define LANG_HOOKS_BLOCK_MAY_FALLTHRU hook_bool_const_tree_true
+ #define LANG_HOOKS_EH_USE_CXA_END_CLEANUP false
+ #define LANG_HOOKS_DEEP_UNSHARING false
++#define LANG_HOOKS_SOURCE_LANGUAGE NULL
+
+ /* Attribute hooks. */
+ #define LANG_HOOKS_ATTRIBUTE_TABLE NULL
+@@ -303,7 +304,8 @@ extern void lhd_end_section (void);
+ LANG_HOOKS_EH_PROTECT_CLEANUP_ACTIONS, \
+ LANG_HOOKS_BLOCK_MAY_FALLTHRU, \
+ LANG_HOOKS_EH_USE_CXA_END_CLEANUP, \
+- LANG_HOOKS_DEEP_UNSHARING \
++ LANG_HOOKS_DEEP_UNSHARING, \
++ LANG_HOOKS_SOURCE_LANGUAGE \
+ }
+
+ #endif /* GCC_LANG_HOOKS_DEF_H */
+--- gcc/c/c-lang.c.jj 2011-01-03 12:53:05.376056936 +0100
++++ gcc/c/c-lang.c 2011-01-04 17:59:43.167743798 +0100
+@@ -36,6 +36,12 @@ along with GCC; see the file COPYING3.
+
+ enum c_language_kind c_language = clk_c;
+
++static int
++c_source_language (void)
++{
++ return flag_isoc99 ? 1999 : 1989;
++}
++
+ /* Lang hooks common to C and ObjC are declared in c-objc-common.h;
+ consequently, there should be very few hooks below. */
+
+@@ -45,6 +51,8 @@ enum c_language_kind c_language = clk_c;
+ #define LANG_HOOKS_INIT c_objc_common_init
+ #undef LANG_HOOKS_INIT_TS
+ #define LANG_HOOKS_INIT_TS c_common_init_ts
++#undef LANG_HOOKS_SOURCE_LANGUAGE
++#define LANG_HOOKS_SOURCE_LANGUAGE c_source_language
+
+ /* Each front end provides its own lang hook initializer. */
+ struct lang_hooks lang_hooks = LANG_HOOKS_INITIALIZER;
+--- gcc/dwarf2out.c.jj 2011-01-03 12:53:05.102056475 +0100
++++ gcc/dwarf2out.c 2011-01-04 18:03:14.534151763 +0100
+@@ -16109,9 +16109,18 @@ add_bit_size_attribute (dw_die_ref die,
+ static inline void
+ add_prototyped_attribute (dw_die_ref die, tree func_type)
+ {
+- if (get_AT_unsigned (comp_unit_die (), DW_AT_language) == DW_LANG_C89
+- && prototype_p (func_type))
+- add_AT_flag (die, DW_AT_prototyped, 1);
++ switch (get_AT_unsigned (comp_unit_die (), DW_AT_language))
++ {
++ case DW_LANG_C:
++ case DW_LANG_C89:
++ case DW_LANG_C99:
++ case DW_LANG_ObjC:
++ if (prototype_p (func_type))
++ add_AT_flag (die, DW_AT_prototyped, 1);
++ break;
++ default:
++ break;
++ }
+ }
+
+ /* Add an 'abstract_origin' attribute below a given DIE. The DIE is found
+@@ -18915,6 +18924,10 @@ gen_compile_unit_die (const char *filena
+ if (strcmp (language_string, "GNU Go") == 0)
+ language = DW_LANG_Go;
+ }
++ else if (strcmp (language_string, "GNU C") == 0
++ && lang_hooks.source_language
++ && lang_hooks.source_language () >= 1999)
++ language = DW_LANG_C99;
+ }
+ /* Use a degraded Fortran setting in strict DWARF2 so is_fortran works. */
+ else if (strcmp (language_string, "GNU Fortran") == 0)
--- /dev/null
+2014-12-17 Jakub Jelinek <jakub@redhat.com>
+
+ PR sanitizer/64336
+ * tsan.c (instrument_expr): Ignore TREE_READONLY bit
+ on MEM_REFs.
+
+--- gcc/tsan.c.jj 2014-12-17 10:53:30.000000000 +0100
++++ gcc/tsan.c 2014-12-17 11:55:12.793058159 +0100
+@@ -138,7 +138,7 @@ instrument_expr (gimple_stmt_iterator gs
+ return false;
+ }
+
+- if (TREE_READONLY (base)
++ if ((TREE_READONLY (base) && TREE_CODE (base) != MEM_REF)
+ || (TREE_CODE (base) == VAR_DECL
+ && DECL_HARD_REGISTER (base)))
+ return false;
--- /dev/null
+From: https://sourceware.org/bugzilla/show_bug.cgi?id=12841
+
+--- libc/rt/bits/mqueue2.h 2009-05-16 19:23:37.000000000 +0200
++++ libc/rt/bits/mqueue2.h 2011-06-04 19:05:38.322333773 +0200
+@@ -1,5 +1,5 @@
+ /* Checking macros for mq functions.
+- Copyright (C) 2007 Free Software Foundation, Inc.
++ Copyright (C) 2007, 2011 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+
+ The GNU C Library is free software; you can redistribute it and/or
+@@ -25,16 +25,18 @@
+ parameter. */
+ extern mqd_t mq_open (__const char *__name, int __oflag, ...)
+ __THROW __nonnull ((1));
+-extern mqd_t __mq_open_2 (__const char *__name, int __oflag) __nonnull ((1));
+-extern mqd_t __REDIRECT (__mq_open_alias, (__const char *__name, int __oflag, ...),
+- mq_open) __nonnull ((1));
++extern mqd_t __mq_open_2 (__const char *__name, int __oflag)
++ __THROW __nonnull ((1));
++extern mqd_t __REDIRECT_NTH (__mq_open_alias, (__const char *__name,
++ int __oflag, ...), mq_open)
++ __nonnull ((1));
+ __errordecl (__mq_open_wrong_number_of_args,
+ "mq_open can be called either with 2 or 4 arguments");
+ __errordecl (__mq_open_missing_mode_and_attr,
+ "mq_open with O_CREAT in second argument needs 4 arguments");
+
+ __extern_always_inline mqd_t
+-mq_open (__const char *__name, int __oflag, ...)
++__NTH (mq_open (__const char *__name, int __oflag, ...))
+ {
+ if (__va_arg_pack_len () != 0 && __va_arg_pack_len () != 2)
+ __mq_open_wrong_number_of_args ();
+++ /dev/null
-diff --git a/drivers/media/usb/dvb-usb/dw2102.c b/drivers/media/usb/dvb-usb/dw2102.c
-index 1a3df10..82d35c6 100644
---- a/drivers/media/usb/dvb-usb/dw2102.c
-+++ b/drivers/media/usb/dvb-usb/dw2102.c
-@@ -31,6 +31,9 @@
- #include "m88rs2000.h"
- #include "tda18271.h"
- #include "cxd2820r.h"
-+#include "m88ds3103.h"
-+#include "m88ts2022.h"
-+
-
- /* Max transfer size done by I2C transfer functions */
- #define MAX_XFER_SIZE 64
-@@ -71,6 +74,14 @@
- #define USB_PID_TEVII_S480_2 0xd482
- #endif
-
-+#ifndef USB_PID_TEVII_S482_1
-+#define USB_PID_TEVII_S482_1 0xd483
-+#endif
-+
-+#ifndef USB_PID_TEVII_S482_2
-+#define USB_PID_TEVII_S482_2 0xd484
-+#endif
-+
- #ifndef USB_PID_PROF_1100
- #define USB_PID_PROF_1100 0xb012
- #endif
-@@ -1117,6 +1128,19 @@ static struct tda18271_config tda18271_config = {
- .gate = TDA18271_GATE_DIGITAL,
- };
-
-+static const struct m88ds3103_config s482_m88ds3103_config = {
-+ .i2c_addr = 0x68,
-+ .clock = 27000000,
-+ .i2c_wr_max = 33,
-+ .clock_out = 0,
-+ .ts_mode = M88DS3103_TS_CI,
-+ .ts_clk = 16000,
-+ .ts_clk_pol = 0,
-+ .agc = 0x99,
-+ .lnb_hv_pol = 1,
-+ .lnb_en_pol = 1,
-+ };
-+
- static u8 m88rs2000_inittab[] = {
- DEMOD_WRITE, 0x9a, 0x30,
- DEMOD_WRITE, 0x00, 0x01,
-@@ -1386,6 +1410,83 @@ static int su3000_frontend_attach(struct dvb_usb_adapter *d)
- return -EIO;
- }
-
-+static int m88ds3103_frontend_attach(struct dvb_usb_adapter *d)
-+{
-+ u8 obuf[3] = { 0xe, 0x80, 0 };
-+ u8 ibuf[] = { 0 };
-+
-+ /* demod I2C adapter */
-+ struct i2c_adapter *i2c_adapter;
-+ struct i2c_client *client;
-+ struct i2c_board_info info;
-+ struct m88ts2022_config m88ts2022_config = {
-+ .clock = 27000000,
-+ };
-+ memset(&info, 0, sizeof(struct i2c_board_info));
-+ if (dvb_usb_generic_rw(d->dev, obuf, 3, ibuf, 1, 0) < 0)
-+ err("command 0x0e transfer failed.");
-+
-+ obuf[0] = 0xe;
-+ obuf[1] = 0x02;
-+ obuf[2] = 1;
-+
-+ if (dvb_usb_generic_rw(d->dev, obuf, 3, ibuf, 1, 0) < 0)
-+ err("command 0x0e transfer failed.");
-+ msleep(300);
-+
-+ obuf[0] = 0xe;
-+ obuf[1] = 0x83;
-+ obuf[2] = 0;
-+
-+ if (dvb_usb_generic_rw(d->dev, obuf, 3, ibuf, 1, 0) < 0)
-+ err("command 0x0e transfer failed.");
-+
-+ obuf[0] = 0xe;
-+ obuf[1] = 0x83;
-+ obuf[2] = 1;
-+
-+ if (dvb_usb_generic_rw(d->dev, obuf, 3, ibuf, 1, 0) < 0)
-+ err("command 0x0e transfer failed.");
-+
-+ obuf[0] = 0x51;
-+
-+ if (dvb_usb_generic_rw(d->dev, obuf, 1, ibuf, 1, 0) < 0)
-+ err("command 0x51 transfer failed.");
-+ d->fe_adap[0].fe = dvb_attach(m88ds3103_attach,
-+ &s482_m88ds3103_config,
-+ &d->dev->i2c_adap,
-+ &i2c_adapter);
-+ if (d->fe_adap[0].fe == NULL)
-+ return -EIO;
-+ /* attach tuner */
-+ m88ts2022_config.fe = d->fe_adap[0].fe;
-+ strlcpy(info.type, "m88ts2022", I2C_NAME_SIZE);
-+ info.addr = 0x60;
-+ info.platform_data = &m88ts2022_config;
-+ request_module("m88ts2022");
-+ client = i2c_new_device(i2c_adapter, &info);
-+ if (client == NULL || client->dev.driver == NULL) {
-+ dvb_frontend_detach(d->fe_adap[0].fe);
-+ goto fail_attach;
-+ }
-+ if (!try_module_get(client->dev.driver->owner)) {
-+ i2c_unregister_device(client);
-+ dvb_frontend_detach(d->fe_adap[0].fe);
-+ goto fail_attach;
-+ }
-+ info("attached m88ds3103/m88ts2022!\n");
-+
-+ /* delegate signal strength measurement to tuner */
-+
-+ d->fe_adap[0].fe->ops.read_signal_strength =
-+ d->fe_adap[0].fe->ops.tuner_ops.get_rf_strength;
-+
-+ return 0;
-+fail_attach:
-+ info("Failed to attach m88ds3103/m88ts2022!\n");
-+ return -EIO;
-+}
-+
- static int t220_frontend_attach(struct dvb_usb_adapter *d)
- {
- u8 obuf[3] = { 0xe, 0x87, 0 };
-@@ -1557,6 +1658,8 @@ enum dw2102_table_entry {
- TEVII_S480_2,
- X3M_SPC1400HD,
- TEVII_S421,
-+ TEVII_S482_1,
-+ TEVII_S482_2,
- TEVII_S632,
- TERRATEC_CINERGY_S2_R2,
- GOTVIEW_SAT_HD,
-@@ -1580,7 +1683,9 @@ static struct usb_device_id dw2102_table[] = {
- [TEVII_S480_2] = {USB_DEVICE(0x9022, USB_PID_TEVII_S480_2)},
- [X3M_SPC1400HD] = {USB_DEVICE(0x1f4d, 0x3100)},
- [TEVII_S421] = {USB_DEVICE(0x9022, USB_PID_TEVII_S421)},
-- [TEVII_S632] = {USB_DEVICE(0x9022, USB_PID_TEVII_S632)},
-+ [TEVII_S482_1] = { USB_DEVICE(0x9022, USB_PID_TEVII_S482_1) },
-+ [TEVII_S482_2] = { USB_DEVICE(0x9022, USB_PID_TEVII_S482_2) },
-+ [TEVII_S632] = { USB_DEVICE(0x9022, USB_PID_TEVII_S632) },
- [TERRATEC_CINERGY_S2_R2] = {USB_DEVICE(USB_VID_TERRATEC, 0x00b0)},
- [GOTVIEW_SAT_HD] = {USB_DEVICE(0x1FE1, USB_PID_GOTVIEW_SAT_HD)},
- [GENIATECH_T220] = {USB_DEVICE(0x1f4d, 0xD220)},
-@@ -2012,6 +2117,59 @@ static struct dvb_usb_device_properties su3000_properties = {
- }
- };
-
-+static struct dvb_usb_device_properties m88ds3103_properties = {
-+ .caps = DVB_USB_IS_AN_I2C_ADAPTER,
-+ .usb_ctrl = DEVICE_SPECIFIC,
-+ .size_of_priv = sizeof(struct su3000_state),
-+ .power_ctrl = su3000_power_ctrl,
-+ .num_adapters = 1,
-+ .identify_state = su3000_identify_state,
-+ .i2c_algo = &su3000_i2c_algo,
-+
-+ .rc.core = {
-+ .rc_interval = 150,
-+ .rc_codes = RC_MAP_TEVII_NEC,
-+ .module_name = "dw2102",
-+ .allowed_protos = RC_BIT_NEC,
-+ .rc_query = dw2102_rc_query,
-+ },
-+
-+ .read_mac_address = su3000_read_mac_address,
-+
-+ .generic_bulk_ctrl_endpoint = 0x01,
-+
-+ .adapter = {
-+ {
-+ .num_frontends = 1,
-+ .fe = { {
-+ .streaming_ctrl = su3000_streaming_ctrl,
-+ .frontend_attach = m88ds3103_frontend_attach,
-+ .stream = {
-+ .type = USB_BULK,
-+ .count = 8,
-+ .endpoint = 0x82,
-+ .u = {
-+ .bulk = {
-+ .buffersize = 4096,
-+ }
-+ }
-+ }
-+ } },
-+ }
-+ },
-+ .num_device_descs = 2,
-+ .devices = {
-+ { "TeVii S482.1 USB",
-+ { &dw2102_table[TEVII_S482_1], NULL },
-+ { NULL },
-+ },
-+ { "TeVii S482.2 USB",
-+ { &dw2102_table[TEVII_S482_2], NULL },
-+ { NULL },
-+ },
-+ }
-+};
-+
- static struct dvb_usb_device_properties t220_properties = {
- .caps = DVB_USB_IS_AN_I2C_ADAPTER,
- .usb_ctrl = DEVICE_SPECIFIC,
-@@ -2131,11 +2289,13 @@ static int dw2102_probe(struct usb_interface *intf,
- 0 == dvb_usb_device_init(intf, p7500,
- THIS_MODULE, NULL, adapter_nr) ||
- 0 == dvb_usb_device_init(intf, s421,
-- THIS_MODULE, NULL, adapter_nr) ||
-- 0 == dvb_usb_device_init(intf, &su3000_properties,
-- THIS_MODULE, NULL, adapter_nr) ||
-+ THIS_MODULE, NULL, adapter_nr) ||
- 0 == dvb_usb_device_init(intf, &t220_properties,
-- THIS_MODULE, NULL, adapter_nr))
-+ THIS_MODULE, NULL, adapter_nr) ||
-+ 0 == dvb_usb_device_init(intf, &m88ds3103_properties,
-+ THIS_MODULE, NULL, adapter_nr) ||
-+ 0 == dvb_usb_device_init(intf, &su3000_properties,
-+ THIS_MODULE, NULL, adapter_nr))
- return 0;
-
- return -ENODEV;
-@@ -2153,7 +2313,7 @@ module_usb_driver(dw2102_driver);
- MODULE_AUTHOR("Igor M. Liplianin (c) liplianin@me.by");
- MODULE_DESCRIPTION("Driver for DVBWorld DVB-S 2101, 2102, DVB-S2 2104,"
- " DVB-C 3101 USB2.0,"
-- " TeVii S600, S630, S650, S660, S480, S421, S632"
-+ " TeVii S600, S630, S650, S660, S480, S482, S421, S632"
- " Prof 1100, 7500 USB2.0,"
- " Geniatech SU3000, T220 devices");
- MODULE_VERSION("0.1");
--- /dev/null
+From f3f885fa684ff18fa4d223dc22b782f5e5d32560 Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Sun, 16 Feb 2014 16:38:43 -0800
+Subject: [PATCH 01/25] Drivers: net: hyperv: Get rid of the
+ rndis_filter_packet structure
+
+This structure is redundant; get rid of it make the code little more efficient -
+get rid of the unnecessary indirection.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 6 ------
+ drivers/net/hyperv/netvsc_drv.c | 2 +-
+ drivers/net/hyperv/rndis_filter.c | 41 +++------------------------------------
+ 3 files changed, 4 insertions(+), 45 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index 7b594ce3f21d..7645ba38bde8 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -846,12 +846,6 @@ struct rndis_message {
+ };
+
+
+-struct rndis_filter_packet {
+- void *completion_ctx;
+- void (*completion)(void *context);
+- struct rndis_message msg;
+-};
+-
+ /* Handy macros */
+
+ /* get the size of an RNDIS message. Pass in the message type, */
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 3c1c33ceffba..28020f83ba6f 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -156,7 +156,7 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ /* Allocate a netvsc packet based on # of frags. */
+ packet = kzalloc(sizeof(struct hv_netvsc_packet) +
+ (num_pages * sizeof(struct hv_page_buffer)) +
+- sizeof(struct rndis_filter_packet) +
++ sizeof(struct rndis_message) +
+ NDIS_VLAN_PPI_SIZE, GFP_ATOMIC);
+ if (!packet) {
+ /* out of memory, drop packet */
+diff --git a/drivers/net/hyperv/rndis_filter.c b/drivers/net/hyperv/rndis_filter.c
+index b54fd257652b..6a9f6021f09c 100644
+--- a/drivers/net/hyperv/rndis_filter.c
++++ b/drivers/net/hyperv/rndis_filter.c
+@@ -58,9 +58,6 @@ struct rndis_request {
+ u8 request_ext[RNDIS_EXT_LEN];
+ };
+
+-static void rndis_filter_send_completion(void *ctx);
+-
+-
+ static struct rndis_device *get_rndis_device(void)
+ {
+ struct rndis_device *device;
+@@ -297,7 +294,7 @@ static void rndis_filter_receive_response(struct rndis_device *dev,
+ "rndis response buffer overflow "
+ "detected (size %u max %zu)\n",
+ resp->msg_len,
+- sizeof(struct rndis_filter_packet));
++ sizeof(struct rndis_message));
+
+ if (resp->ndis_msg_type ==
+ RNDIS_MSG_RESET_C) {
+@@ -917,17 +914,14 @@ int rndis_filter_close(struct hv_device *dev)
+ int rndis_filter_send(struct hv_device *dev,
+ struct hv_netvsc_packet *pkt)
+ {
+- int ret;
+- struct rndis_filter_packet *filter_pkt;
+ struct rndis_message *rndis_msg;
+ struct rndis_packet *rndis_pkt;
+ u32 rndis_msg_size;
+ bool isvlan = pkt->vlan_tci & VLAN_TAG_PRESENT;
+
+ /* Add the rndis header */
+- filter_pkt = (struct rndis_filter_packet *)pkt->extension;
++ rndis_msg = (struct rndis_message *)pkt->extension;
+
+- rndis_msg = &filter_pkt->msg;
+ rndis_msg_size = RNDIS_MESSAGE_SIZE(struct rndis_packet);
+ if (isvlan)
+ rndis_msg_size += NDIS_VLAN_PPI_SIZE;
+@@ -980,34 +974,5 @@ int rndis_filter_send(struct hv_device *dev,
+ pkt->page_buf[1].len = rndis_msg_size - pkt->page_buf[0].len;
+ }
+
+- /* Save the packet send completion and context */
+- filter_pkt->completion = pkt->completion.send.send_completion;
+- filter_pkt->completion_ctx =
+- pkt->completion.send.send_completion_ctx;
+-
+- /* Use ours */
+- pkt->completion.send.send_completion = rndis_filter_send_completion;
+- pkt->completion.send.send_completion_ctx = filter_pkt;
+-
+- ret = netvsc_send(dev, pkt);
+- if (ret != 0) {
+- /*
+- * Reset the completion to originals to allow retries from
+- * above
+- */
+- pkt->completion.send.send_completion =
+- filter_pkt->completion;
+- pkt->completion.send.send_completion_ctx =
+- filter_pkt->completion_ctx;
+- }
+-
+- return ret;
+-}
+-
+-static void rndis_filter_send_completion(void *ctx)
+-{
+- struct rndis_filter_packet *filter_pkt = ctx;
+-
+- /* Pass it back to the original handler */
+- filter_pkt->completion(filter_pkt->completion_ctx);
++ return netvsc_send(dev, pkt);
+ }
+--
+2.4.3
+
--- /dev/null
+From 5b54dac856cb5bd6f33f4159012773e4a33704f7 Mon Sep 17 00:00:00 2001
+From: Haiyang Zhang <haiyangz@microsoft.com>
+Date: Mon, 21 Apr 2014 10:20:28 -0700
+Subject: [PATCH 01/11] hyperv: Add support for virtual Receive Side Scaling
+ (vRSS)
+
+This feature allows multiple channels to be used by each virtual NIC.
+It is available on Hyper-V host 2012 R2.
+
+Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
+Reviewed-by: K. Y. Srinivasan <kys@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 110 +++++++++++++++++++++-
+ drivers/net/hyperv/netvsc.c | 136 +++++++++++++++++++++------
+ drivers/net/hyperv/netvsc_drv.c | 103 ++++++++++++++++++++-
+ drivers/net/hyperv/rndis_filter.c | 189 +++++++++++++++++++++++++++++++++++++-
+ 4 files changed, 504 insertions(+), 34 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index d18f711d0b0c..57eb3f906d64 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -28,6 +28,96 @@
+ #include <linux/hyperv.h>
+ #include <linux/rndis.h>
+
++/* RSS related */
++#define OID_GEN_RECEIVE_SCALE_CAPABILITIES 0x00010203 /* query only */
++#define OID_GEN_RECEIVE_SCALE_PARAMETERS 0x00010204 /* query and set */
++
++#define NDIS_OBJECT_TYPE_RSS_CAPABILITIES 0x88
++#define NDIS_OBJECT_TYPE_RSS_PARAMETERS 0x89
++
++#define NDIS_RECEIVE_SCALE_CAPABILITIES_REVISION_2 2
++#define NDIS_RECEIVE_SCALE_PARAMETERS_REVISION_2 2
++
++struct ndis_obj_header {
++ u8 type;
++ u8 rev;
++ u16 size;
++} __packed;
++
++/* ndis_recv_scale_cap/cap_flag */
++#define NDIS_RSS_CAPS_MESSAGE_SIGNALED_INTERRUPTS 0x01000000
++#define NDIS_RSS_CAPS_CLASSIFICATION_AT_ISR 0x02000000
++#define NDIS_RSS_CAPS_CLASSIFICATION_AT_DPC 0x04000000
++#define NDIS_RSS_CAPS_USING_MSI_X 0x08000000
++#define NDIS_RSS_CAPS_RSS_AVAILABLE_ON_PORTS 0x10000000
++#define NDIS_RSS_CAPS_SUPPORTS_MSI_X 0x20000000
++#define NDIS_RSS_CAPS_HASH_TYPE_TCP_IPV4 0x00000100
++#define NDIS_RSS_CAPS_HASH_TYPE_TCP_IPV6 0x00000200
++#define NDIS_RSS_CAPS_HASH_TYPE_TCP_IPV6_EX 0x00000400
++
++struct ndis_recv_scale_cap { /* NDIS_RECEIVE_SCALE_CAPABILITIES */
++ struct ndis_obj_header hdr;
++ u32 cap_flag;
++ u32 num_int_msg;
++ u32 num_recv_que;
++ u16 num_indirect_tabent;
++} __packed;
++
++
++/* ndis_recv_scale_param flags */
++#define NDIS_RSS_PARAM_FLAG_BASE_CPU_UNCHANGED 0x0001
++#define NDIS_RSS_PARAM_FLAG_HASH_INFO_UNCHANGED 0x0002
++#define NDIS_RSS_PARAM_FLAG_ITABLE_UNCHANGED 0x0004
++#define NDIS_RSS_PARAM_FLAG_HASH_KEY_UNCHANGED 0x0008
++#define NDIS_RSS_PARAM_FLAG_DISABLE_RSS 0x0010
++
++/* Hash info bits */
++#define NDIS_HASH_FUNC_TOEPLITZ 0x00000001
++#define NDIS_HASH_IPV4 0x00000100
++#define NDIS_HASH_TCP_IPV4 0x00000200
++#define NDIS_HASH_IPV6 0x00000400
++#define NDIS_HASH_IPV6_EX 0x00000800
++#define NDIS_HASH_TCP_IPV6 0x00001000
++#define NDIS_HASH_TCP_IPV6_EX 0x00002000
++
++#define NDIS_RSS_INDIRECTION_TABLE_MAX_SIZE_REVISION_2 (128 * 4)
++#define NDIS_RSS_HASH_SECRET_KEY_MAX_SIZE_REVISION_2 40
++
++#define ITAB_NUM 128
++#define HASH_KEYLEN NDIS_RSS_HASH_SECRET_KEY_MAX_SIZE_REVISION_2
++extern u8 netvsc_hash_key[];
++
++struct ndis_recv_scale_param { /* NDIS_RECEIVE_SCALE_PARAMETERS */
++ struct ndis_obj_header hdr;
++
++ /* Qualifies the rest of the information */
++ u16 flag;
++
++ /* The base CPU number to do receive processing. not used */
++ u16 base_cpu_number;
++
++ /* This describes the hash function and type being enabled */
++ u32 hashinfo;
++
++ /* The size of indirection table array */
++ u16 indirect_tabsize;
++
++ /* The offset of the indirection table from the beginning of this
++ * structure
++ */
++ u32 indirect_taboffset;
++
++ /* The size of the hash secret key */
++ u16 hashkey_size;
++
++ /* The offset of the secret key from the beginning of this structure */
++ u32 kashkey_offset;
++
++ u32 processor_masks_offset;
++ u32 num_processor_masks;
++ u32 processor_masks_entry_size;
++};
++
+ /* Fwd declaration */
+ struct hv_netvsc_packet;
+ struct ndis_tcp_ip_checksum_info;
+@@ -39,6 +129,8 @@ struct xferpage_packet {
+
+ /* # of netvsc packets this xfer packet contains */
+ u32 count;
++
++ struct vmbus_channel *channel;
+ };
+
+ /*
+@@ -54,6 +146,9 @@ struct hv_netvsc_packet {
+ bool is_data_pkt;
+ u16 vlan_tci;
+
++ u16 q_idx;
++ struct vmbus_channel *channel;
++
+ /*
+ * Valid only for receives when we break a xfer page packet
+ * into multiple netvsc packets
+@@ -120,6 +215,7 @@ void netvsc_linkstatus_callback(struct hv_device *device_obj,
+ int netvsc_recv_callback(struct hv_device *device_obj,
+ struct hv_netvsc_packet *packet,
+ struct ndis_tcp_ip_checksum_info *csum_info);
++void netvsc_channel_cb(void *context);
+ int rndis_filter_open(struct hv_device *dev);
+ int rndis_filter_close(struct hv_device *dev);
+ int rndis_filter_device_add(struct hv_device *dev,
+@@ -522,6 +618,8 @@ struct nvsp_message {
+
+ #define NETVSC_PACKET_SIZE 2048
+
++#define VRSS_SEND_TAB_SIZE 16
++
+ /* Per netvsc channel-specific */
+ struct netvsc_device {
+ struct hv_device *dev;
+@@ -555,10 +653,20 @@ struct netvsc_device {
+
+ struct net_device *ndev;
+
++ struct vmbus_channel *chn_table[NR_CPUS];
++ u32 send_table[VRSS_SEND_TAB_SIZE];
++ u32 num_chn;
++ atomic_t queue_sends[NR_CPUS];
++
+ /* Holds rndis device info */
+ void *extension;
+- /* The recive buffer for this device */
++
++ int ring_size;
++
++ /* The primary channel callback buffer */
+ unsigned char cb_buffer[NETVSC_PACKET_SIZE];
++ /* The sub channel callback buffer */
++ unsigned char *sub_cb_buf;
+ };
+
+ /* NdisInitialize message */
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index f7629ecefa84..e7e77f12bc38 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -422,6 +422,9 @@ int netvsc_device_remove(struct hv_device *device)
+ kfree(netvsc_packet);
+ }
+
++ if (net_device->sub_cb_buf)
++ vfree(net_device->sub_cb_buf);
++
+ kfree(net_device);
+ return 0;
+ }
+@@ -461,7 +464,9 @@ static void netvsc_send_completion(struct netvsc_device *net_device,
+ (nvsp_packet->hdr.msg_type ==
+ NVSP_MSG1_TYPE_SEND_RECV_BUF_COMPLETE) ||
+ (nvsp_packet->hdr.msg_type ==
+- NVSP_MSG1_TYPE_SEND_SEND_BUF_COMPLETE)) {
++ NVSP_MSG1_TYPE_SEND_SEND_BUF_COMPLETE) ||
++ (nvsp_packet->hdr.msg_type ==
++ NVSP_MSG5_TYPE_SUBCHANNEL)) {
+ /* Copy the response back */
+ memcpy(&net_device->channel_init_pkt, nvsp_packet,
+ sizeof(struct nvsp_message));
+@@ -469,28 +474,37 @@ static void netvsc_send_completion(struct netvsc_device *net_device,
+ } else if (nvsp_packet->hdr.msg_type ==
+ NVSP_MSG1_TYPE_SEND_RNDIS_PKT_COMPLETE) {
+ int num_outstanding_sends;
++ u16 q_idx = 0;
++ struct vmbus_channel *channel = device->channel;
++ int queue_sends;
+
+ /* Get the send context */
+ nvsc_packet = (struct hv_netvsc_packet *)(unsigned long)
+ packet->trans_id;
+
+ /* Notify the layer above us */
+- if (nvsc_packet)
++ if (nvsc_packet) {
++ q_idx = nvsc_packet->q_idx;
++ channel = nvsc_packet->channel;
+ nvsc_packet->completion.send.send_completion(
+ nvsc_packet->completion.send.
+ send_completion_ctx);
++ }
+
+ num_outstanding_sends =
+ atomic_dec_return(&net_device->num_outstanding_sends);
++ queue_sends = atomic_dec_return(&net_device->
++ queue_sends[q_idx]);
+
+ if (net_device->destroy && num_outstanding_sends == 0)
+ wake_up(&net_device->wait_drain);
+
+- if (netif_queue_stopped(ndev) && !net_device->start_remove &&
+- (hv_ringbuf_avail_percent(&device->channel->outbound)
+- > RING_AVAIL_PERCENT_HIWATER ||
+- num_outstanding_sends < 1))
+- netif_wake_queue(ndev);
++ if (netif_tx_queue_stopped(netdev_get_tx_queue(ndev, q_idx)) &&
++ !net_device->start_remove &&
++ (hv_ringbuf_avail_percent(&channel->outbound) >
++ RING_AVAIL_PERCENT_HIWATER || queue_sends < 1))
++ netif_tx_wake_queue(netdev_get_tx_queue(
++ ndev, q_idx));
+ } else {
+ netdev_err(ndev, "Unknown send completion packet type- "
+ "%d received!!\n", nvsp_packet->hdr.msg_type);
+@@ -505,6 +519,7 @@ int netvsc_send(struct hv_device *device,
+ int ret = 0;
+ struct nvsp_message sendMessage;
+ struct net_device *ndev;
++ struct vmbus_channel *out_channel = NULL;
+ u64 req_id;
+
+ net_device = get_outbound_net_device(device);
+@@ -531,15 +546,20 @@ int netvsc_send(struct hv_device *device,
+ else
+ req_id = 0;
+
++ out_channel = net_device->chn_table[packet->q_idx];
++ if (out_channel == NULL)
++ out_channel = device->channel;
++ packet->channel = out_channel;
++
+ if (packet->page_buf_cnt) {
+- ret = vmbus_sendpacket_pagebuffer(device->channel,
++ ret = vmbus_sendpacket_pagebuffer(out_channel,
+ packet->page_buf,
+ packet->page_buf_cnt,
+ &sendMessage,
+ sizeof(struct nvsp_message),
+ req_id);
+ } else {
+- ret = vmbus_sendpacket(device->channel, &sendMessage,
++ ret = vmbus_sendpacket(out_channel, &sendMessage,
+ sizeof(struct nvsp_message),
+ req_id,
+ VM_PKT_DATA_INBAND,
+@@ -548,17 +568,24 @@ int netvsc_send(struct hv_device *device,
+
+ if (ret == 0) {
+ atomic_inc(&net_device->num_outstanding_sends);
+- if (hv_ringbuf_avail_percent(&device->channel->outbound) <
++ atomic_inc(&net_device->queue_sends[packet->q_idx]);
++
++ if (hv_ringbuf_avail_percent(&out_channel->outbound) <
+ RING_AVAIL_PERCENT_LOWATER) {
+- netif_stop_queue(ndev);
++ netif_tx_stop_queue(netdev_get_tx_queue(
++ ndev, packet->q_idx));
++
+ if (atomic_read(&net_device->
+- num_outstanding_sends) < 1)
+- netif_wake_queue(ndev);
++ queue_sends[packet->q_idx]) < 1)
++ netif_tx_wake_queue(netdev_get_tx_queue(
++ ndev, packet->q_idx));
+ }
+ } else if (ret == -EAGAIN) {
+- netif_stop_queue(ndev);
+- if (atomic_read(&net_device->num_outstanding_sends) < 1) {
+- netif_wake_queue(ndev);
++ netif_tx_stop_queue(netdev_get_tx_queue(
++ ndev, packet->q_idx));
++ if (atomic_read(&net_device->queue_sends[packet->q_idx]) < 1) {
++ netif_tx_wake_queue(netdev_get_tx_queue(
++ ndev, packet->q_idx));
+ ret = -ENOSPC;
+ }
+ } else {
+@@ -570,6 +597,7 @@ int netvsc_send(struct hv_device *device,
+ }
+
+ static void netvsc_send_recv_completion(struct hv_device *device,
++ struct vmbus_channel *channel,
+ struct netvsc_device *net_device,
+ u64 transaction_id, u32 status)
+ {
+@@ -587,7 +615,7 @@ static void netvsc_send_recv_completion(struct hv_device *device,
+
+ retry_send_cmplt:
+ /* Send the completion */
+- ret = vmbus_sendpacket(device->channel, &recvcompMessage,
++ ret = vmbus_sendpacket(channel, &recvcompMessage,
+ sizeof(struct nvsp_message), transaction_id,
+ VM_PKT_COMP, 0);
+ if (ret == 0) {
+@@ -618,6 +646,7 @@ static void netvsc_receive_completion(void *context)
+ {
+ struct hv_netvsc_packet *packet = context;
+ struct hv_device *device = packet->device;
++ struct vmbus_channel *channel;
+ struct netvsc_device *net_device;
+ u64 transaction_id = 0;
+ bool fsend_receive_comp = false;
+@@ -649,6 +678,7 @@ static void netvsc_receive_completion(void *context)
+ */
+ if (packet->xfer_page_pkt->count == 0) {
+ fsend_receive_comp = true;
++ channel = packet->xfer_page_pkt->channel;
+ transaction_id = packet->completion.recv.recv_completion_tid;
+ status = packet->xfer_page_pkt->status;
+ list_add_tail(&packet->xfer_page_pkt->list_ent,
+@@ -662,12 +692,13 @@ static void netvsc_receive_completion(void *context)
+
+ /* Send a receive completion for the xfer page packet */
+ if (fsend_receive_comp)
+- netvsc_send_recv_completion(device, net_device, transaction_id,
+- status);
++ netvsc_send_recv_completion(device, channel, net_device,
++ transaction_id, status);
+
+ }
+
+ static void netvsc_receive(struct netvsc_device *net_device,
++ struct vmbus_channel *channel,
+ struct hv_device *device,
+ struct vmpacket_descriptor *packet)
+ {
+@@ -748,7 +779,7 @@ static void netvsc_receive(struct netvsc_device *net_device,
+ spin_unlock_irqrestore(&net_device->recv_pkt_list_lock,
+ flags);
+
+- netvsc_send_recv_completion(device, net_device,
++ netvsc_send_recv_completion(device, channel, net_device,
+ vmxferpage_packet->d.trans_id,
+ NVSP_STAT_FAIL);
+
+@@ -759,6 +790,7 @@ static void netvsc_receive(struct netvsc_device *net_device,
+ xferpage_packet = (struct xferpage_packet *)listHead.next;
+ list_del(&xferpage_packet->list_ent);
+ xferpage_packet->status = NVSP_STAT_SUCCESS;
++ xferpage_packet->channel = channel;
+
+ /* This is how much we can satisfy */
+ xferpage_packet->count = count - 1;
+@@ -800,10 +832,45 @@ static void netvsc_receive(struct netvsc_device *net_device,
+
+ }
+
+-static void netvsc_channel_cb(void *context)
++
++static void netvsc_send_table(struct hv_device *hdev,
++ struct vmpacket_descriptor *vmpkt)
++{
++ struct netvsc_device *nvscdev;
++ struct net_device *ndev;
++ struct nvsp_message *nvmsg;
++ int i;
++ u32 count, *tab;
++
++ nvscdev = get_outbound_net_device(hdev);
++ if (!nvscdev)
++ return;
++ ndev = nvscdev->ndev;
++
++ nvmsg = (struct nvsp_message *)((unsigned long)vmpkt +
++ (vmpkt->offset8 << 3));
++
++ if (nvmsg->hdr.msg_type != NVSP_MSG5_TYPE_SEND_INDIRECTION_TABLE)
++ return;
++
++ count = nvmsg->msg.v5_msg.send_table.count;
++ if (count != VRSS_SEND_TAB_SIZE) {
++ netdev_err(ndev, "Received wrong send-table size:%u\n", count);
++ return;
++ }
++
++ tab = (u32 *)((unsigned long)&nvmsg->msg.v5_msg.send_table +
++ nvmsg->msg.v5_msg.send_table.offset);
++
++ for (i = 0; i < count; i++)
++ nvscdev->send_table[i] = tab[i];
++}
++
++void netvsc_channel_cb(void *context)
+ {
+ int ret;
+- struct hv_device *device = context;
++ struct vmbus_channel *channel = (struct vmbus_channel *)context;
++ struct hv_device *device;
+ struct netvsc_device *net_device;
+ u32 bytes_recvd;
+ u64 request_id;
+@@ -812,14 +879,19 @@ static void netvsc_channel_cb(void *context)
+ int bufferlen = NETVSC_PACKET_SIZE;
+ struct net_device *ndev;
+
++ if (channel->primary_channel != NULL)
++ device = channel->primary_channel->device_obj;
++ else
++ device = channel->device_obj;
++
+ net_device = get_inbound_net_device(device);
+ if (!net_device)
+ return;
+ ndev = net_device->ndev;
+- buffer = net_device->cb_buffer;
++ buffer = get_per_channel_state(channel);
+
+ do {
+- ret = vmbus_recvpacket_raw(device->channel, buffer, bufferlen,
++ ret = vmbus_recvpacket_raw(channel, buffer, bufferlen,
+ &bytes_recvd, &request_id);
+ if (ret == 0) {
+ if (bytes_recvd > 0) {
+@@ -831,8 +903,12 @@ static void netvsc_channel_cb(void *context)
+ break;
+
+ case VM_PKT_DATA_USING_XFER_PAGES:
+- netvsc_receive(net_device,
+- device, desc);
++ netvsc_receive(net_device, channel,
++ device, desc);
++ break;
++
++ case VM_PKT_DATA_INBAND:
++ netvsc_send_table(device, desc);
+ break;
+
+ default:
+@@ -893,6 +969,8 @@ int netvsc_device_add(struct hv_device *device, void *additional_info)
+ goto cleanup;
+ }
+
++ net_device->ring_size = ring_size;
++
+ /*
+ * Coming into this function, struct net_device * is
+ * registered as the driver private data.
+@@ -917,10 +995,12 @@ int netvsc_device_add(struct hv_device *device, void *additional_info)
+ }
+ init_completion(&net_device->channel_init_wait);
+
++ set_per_channel_state(device->channel, net_device->cb_buffer);
++
+ /* Open the channel */
+ ret = vmbus_open(device->channel, ring_size * PAGE_SIZE,
+ ring_size * PAGE_SIZE, NULL, 0,
+- netvsc_channel_cb, device);
++ netvsc_channel_cb, device->channel);
+
+ if (ret != 0) {
+ netdev_err(ndev, "unable to open channel: %d\n", ret);
+@@ -930,6 +1010,8 @@ int netvsc_device_add(struct hv_device *device, void *additional_info)
+ /* Channel is opened */
+ pr_info("hv_netvsc channel opened successfully\n");
+
++ net_device->chn_table[0] = device->channel;
++
+ /* Connect with the NetVsp */
+ ret = netvsc_connect_vsp(device);
+ if (ret != 0) {
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 31e55fba7cad..093cf3fc46b8 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -101,7 +101,7 @@ static int netvsc_open(struct net_device *net)
+ return ret;
+ }
+
+- netif_start_queue(net);
++ netif_tx_start_all_queues(net);
+
+ nvdev = hv_get_drvdata(device_obj);
+ rdev = nvdev->extension;
+@@ -149,6 +149,88 @@ static void *init_ppi_data(struct rndis_message *msg, u32 ppi_size,
+ return ppi;
+ }
+
++union sub_key {
++ u64 k;
++ struct {
++ u8 pad[3];
++ u8 kb;
++ u32 ka;
++ };
++};
++
++/* Toeplitz hash function
++ * data: network byte order
++ * return: host byte order
++ */
++static u32 comp_hash(u8 *key, int klen, u8 *data, int dlen)
++{
++ union sub_key subk;
++ int k_next = 4;
++ u8 dt;
++ int i, j;
++ u32 ret = 0;
++
++ subk.k = 0;
++ subk.ka = ntohl(*(u32 *)key);
++
++ for (i = 0; i < dlen; i++) {
++ subk.kb = key[k_next];
++ k_next = (k_next + 1) % klen;
++ dt = data[i];
++ for (j = 0; j < 8; j++) {
++ if (dt & 0x80)
++ ret ^= subk.ka;
++ dt <<= 1;
++ subk.k <<= 1;
++ }
++ }
++
++ return ret;
++}
++
++static bool netvsc_set_hash(u32 *hash, struct sk_buff *skb)
++{
++ struct iphdr *iphdr;
++ int data_len;
++ bool ret = false;
++
++ if (eth_hdr(skb)->h_proto != htons(ETH_P_IP))
++ return false;
++
++ iphdr = ip_hdr(skb);
++
++ if (iphdr->version == 4) {
++ if (iphdr->protocol == IPPROTO_TCP)
++ data_len = 12;
++ else
++ data_len = 8;
++ *hash = comp_hash(netvsc_hash_key, HASH_KEYLEN,
++ (u8 *)&iphdr->saddr, data_len);
++ ret = true;
++ }
++
++ return ret;
++}
++
++static u16 netvsc_select_queue(struct net_device *ndev, struct sk_buff *skb,
++ void *accel_priv, select_queue_fallback_t fallback)
++{
++ struct net_device_context *net_device_ctx = netdev_priv(ndev);
++ struct hv_device *hdev = net_device_ctx->device_ctx;
++ struct netvsc_device *nvsc_dev = hv_get_drvdata(hdev);
++ u32 hash;
++ u16 q_idx = 0;
++
++ if (nvsc_dev == NULL || ndev->real_num_tx_queues <= 1)
++ return 0;
++
++ if (netvsc_set_hash(&hash, skb))
++ q_idx = nvsc_dev->send_table[hash % VRSS_SEND_TAB_SIZE] %
++ ndev->real_num_tx_queues;
++
++ return q_idx;
++}
++
+ static void netvsc_xmit_completion(void *context)
+ {
+ struct hv_netvsc_packet *packet = (struct hv_netvsc_packet *)context;
+@@ -333,6 +415,8 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+
+ packet->vlan_tci = skb->vlan_tci;
+
++ packet->q_idx = skb_get_queue_mapping(skb);
++
+ packet->is_data_pkt = true;
+ packet->total_data_buflen = skb->len;
+
+@@ -554,6 +638,10 @@ int netvsc_recv_callback(struct hv_device *device_obj,
+ __vlan_hwaccel_put_tag(skb, htons(ETH_P_8021Q),
+ packet->vlan_tci);
+
++ skb_record_rx_queue(skb, packet->xfer_page_pkt->channel->
++ offermsg.offer.sub_channel_index %
++ net->real_num_rx_queues);
++
+ net->stats.rx_packets++;
+ net->stats.rx_bytes += packet->total_data_buflen;
+
+@@ -602,7 +690,7 @@ static int netvsc_change_mtu(struct net_device *ndev, int mtu)
+ hv_set_drvdata(hdev, ndev);
+ device_info.ring_size = ring_size;
+ rndis_filter_device_add(hdev, &device_info);
+- netif_wake_queue(ndev);
++ netif_tx_wake_all_queues(ndev);
+
+ return 0;
+ }
+@@ -648,6 +736,7 @@ static const struct net_device_ops device_ops = {
+ .ndo_change_mtu = netvsc_change_mtu,
+ .ndo_validate_addr = eth_validate_addr,
+ .ndo_set_mac_address = netvsc_set_mac_addr,
++ .ndo_select_queue = netvsc_select_queue,
+ };
+
+ /*
+@@ -694,9 +783,11 @@ static int netvsc_probe(struct hv_device *dev,
+ struct net_device *net = NULL;
+ struct net_device_context *net_device_ctx;
+ struct netvsc_device_info device_info;
++ struct netvsc_device *nvdev;
+ int ret;
+
+- net = alloc_etherdev(sizeof(struct net_device_context));
++ net = alloc_etherdev_mq(sizeof(struct net_device_context),
++ num_online_cpus());
+ if (!net)
+ return -ENOMEM;
+
+@@ -729,6 +820,12 @@ static int netvsc_probe(struct hv_device *dev,
+ }
+ memcpy(net->dev_addr, device_info.mac_adr, ETH_ALEN);
+
++ nvdev = hv_get_drvdata(dev);
++ netif_set_real_num_tx_queues(net, nvdev->num_chn);
++ netif_set_real_num_rx_queues(net, nvdev->num_chn);
++ dev_info(&dev->device, "real num tx,rx queues:%u, %u\n",
++ net->real_num_tx_queues, net->real_num_rx_queues);
++
+ ret = register_netdev(net);
+ if (ret != 0) {
+ pr_err("Unable to register netdev.\n");
+diff --git a/drivers/net/hyperv/rndis_filter.c b/drivers/net/hyperv/rndis_filter.c
+index 143a98caf618..d92cfbe43410 100644
+--- a/drivers/net/hyperv/rndis_filter.c
++++ b/drivers/net/hyperv/rndis_filter.c
+@@ -31,7 +31,7 @@
+ #include "hyperv_net.h"
+
+
+-#define RNDIS_EXT_LEN 100
++#define RNDIS_EXT_LEN PAGE_SIZE
+ struct rndis_request {
+ struct list_head list_ent;
+ struct completion wait_event;
+@@ -94,6 +94,8 @@ static struct rndis_request *get_rndis_request(struct rndis_device *dev,
+ rndis_msg->ndis_msg_type = msg_type;
+ rndis_msg->msg_len = msg_len;
+
++ request->pkt.q_idx = 0;
++
+ /*
+ * Set the request id. This field is always after the rndis header for
+ * request/response packet types so we just used the SetRequest as a
+@@ -509,6 +511,19 @@ static int rndis_filter_query_device(struct rndis_device *dev, u32 oid,
+ query->info_buflen = 0;
+ query->dev_vc_handle = 0;
+
++ if (oid == OID_GEN_RECEIVE_SCALE_CAPABILITIES) {
++ struct ndis_recv_scale_cap *cap;
++
++ request->request_msg.msg_len +=
++ sizeof(struct ndis_recv_scale_cap);
++ query->info_buflen = sizeof(struct ndis_recv_scale_cap);
++ cap = (struct ndis_recv_scale_cap *)((unsigned long)query +
++ query->info_buf_offset);
++ cap->hdr.type = NDIS_OBJECT_TYPE_RSS_CAPABILITIES;
++ cap->hdr.rev = NDIS_RECEIVE_SCALE_CAPABILITIES_REVISION_2;
++ cap->hdr.size = sizeof(struct ndis_recv_scale_cap);
++ }
++
+ ret = rndis_filter_send_request(dev, request);
+ if (ret != 0)
+ goto cleanup;
+@@ -695,6 +710,89 @@ cleanup:
+ return ret;
+ }
+
++u8 netvsc_hash_key[HASH_KEYLEN] = {
++ 0x6d, 0x5a, 0x56, 0xda, 0x25, 0x5b, 0x0e, 0xc2,
++ 0x41, 0x67, 0x25, 0x3d, 0x43, 0xa3, 0x8f, 0xb0,
++ 0xd0, 0xca, 0x2b, 0xcb, 0xae, 0x7b, 0x30, 0xb4,
++ 0x77, 0xcb, 0x2d, 0xa3, 0x80, 0x30, 0xf2, 0x0c,
++ 0x6a, 0x42, 0xb7, 0x3b, 0xbe, 0xac, 0x01, 0xfa
++};
++
++int rndis_filter_set_rss_param(struct rndis_device *rdev, int num_queue)
++{
++ struct net_device *ndev = rdev->net_dev->ndev;
++ struct rndis_request *request;
++ struct rndis_set_request *set;
++ struct rndis_set_complete *set_complete;
++ u32 extlen = sizeof(struct ndis_recv_scale_param) +
++ 4*ITAB_NUM + HASH_KEYLEN;
++ struct ndis_recv_scale_param *rssp;
++ u32 *itab;
++ u8 *keyp;
++ int i, t, ret;
++
++ request = get_rndis_request(
++ rdev, RNDIS_MSG_SET,
++ RNDIS_MESSAGE_SIZE(struct rndis_set_request) + extlen);
++ if (!request)
++ return -ENOMEM;
++
++ set = &request->request_msg.msg.set_req;
++ set->oid = OID_GEN_RECEIVE_SCALE_PARAMETERS;
++ set->info_buflen = extlen;
++ set->info_buf_offset = sizeof(struct rndis_set_request);
++ set->dev_vc_handle = 0;
++
++ rssp = (struct ndis_recv_scale_param *)(set + 1);
++ rssp->hdr.type = NDIS_OBJECT_TYPE_RSS_PARAMETERS;
++ rssp->hdr.rev = NDIS_RECEIVE_SCALE_PARAMETERS_REVISION_2;
++ rssp->hdr.size = sizeof(struct ndis_recv_scale_param);
++ rssp->flag = 0;
++ rssp->hashinfo = NDIS_HASH_FUNC_TOEPLITZ | NDIS_HASH_IPV4 |
++ NDIS_HASH_TCP_IPV4;
++ rssp->indirect_tabsize = 4*ITAB_NUM;
++ rssp->indirect_taboffset = sizeof(struct ndis_recv_scale_param);
++ rssp->hashkey_size = HASH_KEYLEN;
++ rssp->kashkey_offset = rssp->indirect_taboffset +
++ rssp->indirect_tabsize;
++
++ /* Set indirection table entries */
++ itab = (u32 *)(rssp + 1);
++ for (i = 0; i < ITAB_NUM; i++)
++ itab[i] = i % num_queue;
++
++ /* Set hask key values */
++ keyp = (u8 *)((unsigned long)rssp + rssp->kashkey_offset);
++ for (i = 0; i < HASH_KEYLEN; i++)
++ keyp[i] = netvsc_hash_key[i];
++
++
++ ret = rndis_filter_send_request(rdev, request);
++ if (ret != 0)
++ goto cleanup;
++
++ t = wait_for_completion_timeout(&request->wait_event, 5*HZ);
++ if (t == 0) {
++ netdev_err(ndev, "timeout before we got a set response...\n");
++ /* can't put_rndis_request, since we may still receive a
++ * send-completion.
++ */
++ return -ETIMEDOUT;
++ } else {
++ set_complete = &request->response_msg.msg.set_complete;
++ if (set_complete->status != RNDIS_STATUS_SUCCESS) {
++ netdev_err(ndev, "Fail to set RSS parameters:0x%x\n",
++ set_complete->status);
++ ret = -EINVAL;
++ }
++ }
++
++cleanup:
++ put_rndis_request(rdev, request);
++ return ret;
++}
++
++
+ static int rndis_filter_query_device_link_status(struct rndis_device *dev)
+ {
+ u32 size = sizeof(u32);
+@@ -886,6 +984,28 @@ static int rndis_filter_close_device(struct rndis_device *dev)
+ return ret;
+ }
+
++static void netvsc_sc_open(struct vmbus_channel *new_sc)
++{
++ struct netvsc_device *nvscdev;
++ u16 chn_index = new_sc->offermsg.offer.sub_channel_index;
++ int ret;
++
++ nvscdev = hv_get_drvdata(new_sc->primary_channel->device_obj);
++
++ if (chn_index >= nvscdev->num_chn)
++ return;
++
++ set_per_channel_state(new_sc, nvscdev->sub_cb_buf + (chn_index - 1) *
++ NETVSC_PACKET_SIZE);
++
++ ret = vmbus_open(new_sc, nvscdev->ring_size * PAGE_SIZE,
++ nvscdev->ring_size * PAGE_SIZE, NULL, 0,
++ netvsc_channel_cb, new_sc);
++
++ if (ret == 0)
++ nvscdev->chn_table[chn_index] = new_sc;
++}
++
+ int rndis_filter_device_add(struct hv_device *dev,
+ void *additional_info)
+ {
+@@ -894,6 +1014,10 @@ int rndis_filter_device_add(struct hv_device *dev,
+ struct rndis_device *rndis_device;
+ struct netvsc_device_info *device_info = additional_info;
+ struct ndis_offload_params offloads;
++ struct nvsp_message *init_packet;
++ int t;
++ struct ndis_recv_scale_cap rsscap;
++ u32 rsscap_size = sizeof(struct ndis_recv_scale_cap);
+
+ rndis_device = get_rndis_device();
+ if (!rndis_device)
+@@ -913,6 +1037,7 @@ int rndis_filter_device_add(struct hv_device *dev,
+
+ /* Initialize the rndis device */
+ net_device = hv_get_drvdata(dev);
++ net_device->num_chn = 1;
+
+ net_device->extension = rndis_device;
+ rndis_device->net_dev = net_device;
+@@ -952,7 +1077,6 @@ int rndis_filter_device_add(struct hv_device *dev,
+ if (ret)
+ goto err_dev_remv;
+
+-
+ rndis_filter_query_device_link_status(rndis_device);
+
+ device_info->link_state = rndis_device->link_state;
+@@ -961,7 +1085,66 @@ int rndis_filter_device_add(struct hv_device *dev,
+ rndis_device->hw_mac_adr,
+ device_info->link_state ? "down" : "up");
+
+- return ret;
++ if (net_device->nvsp_version < NVSP_PROTOCOL_VERSION_5)
++ return 0;
++
++ /* vRSS setup */
++ memset(&rsscap, 0, rsscap_size);
++ ret = rndis_filter_query_device(rndis_device,
++ OID_GEN_RECEIVE_SCALE_CAPABILITIES,
++ &rsscap, &rsscap_size);
++ if (ret || rsscap.num_recv_que < 2)
++ goto out;
++
++ net_device->num_chn = (num_online_cpus() < rsscap.num_recv_que) ?
++ num_online_cpus() : rsscap.num_recv_que;
++ if (net_device->num_chn == 1)
++ goto out;
++
++ net_device->sub_cb_buf = vzalloc((net_device->num_chn - 1) *
++ NETVSC_PACKET_SIZE);
++ if (!net_device->sub_cb_buf) {
++ net_device->num_chn = 1;
++ dev_info(&dev->device, "No memory for subchannels.\n");
++ goto out;
++ }
++
++ vmbus_set_sc_create_callback(dev->channel, netvsc_sc_open);
++
++ init_packet = &net_device->channel_init_pkt;
++ memset(init_packet, 0, sizeof(struct nvsp_message));
++ init_packet->hdr.msg_type = NVSP_MSG5_TYPE_SUBCHANNEL;
++ init_packet->msg.v5_msg.subchn_req.op = NVSP_SUBCHANNEL_ALLOCATE;
++ init_packet->msg.v5_msg.subchn_req.num_subchannels =
++ net_device->num_chn - 1;
++ ret = vmbus_sendpacket(dev->channel, init_packet,
++ sizeof(struct nvsp_message),
++ (unsigned long)init_packet,
++ VM_PKT_DATA_INBAND,
++ VMBUS_DATA_PACKET_FLAG_COMPLETION_REQUESTED);
++ if (ret)
++ goto out;
++ t = wait_for_completion_timeout(&net_device->channel_init_wait, 5*HZ);
++ if (t == 0) {
++ ret = -ETIMEDOUT;
++ goto out;
++ }
++ if (init_packet->msg.v5_msg.subchn_comp.status !=
++ NVSP_STAT_SUCCESS) {
++ ret = -ENODEV;
++ goto out;
++ }
++ net_device->num_chn = 1 +
++ init_packet->msg.v5_msg.subchn_comp.num_subchannels;
++
++ vmbus_are_subchannels_present(dev->channel);
++
++ ret = rndis_filter_set_rss_param(rndis_device, net_device->num_chn);
++
++out:
++ if (ret)
++ net_device->num_chn = 1;
++ return 0; /* return 0 because primary channel can be used alone */
+
+ err_dev_remv:
+ rndis_filter_device_remove(dev);
+--
+2.4.3
+
--- /dev/null
+From 348a5d691d84759dda8cdd3cbf9f071115c1240e Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Sun, 16 Feb 2014 16:38:44 -0800
+Subject: [PATCH 02/25] Drivers: net: hyperv: Cleanup the receive path
+
+Make the receive path a little more efficient by parameterizing the
+required state rather than re-establishing that state.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/netvsc.c | 29 +++++++++++++----------------
+ 1 file changed, 13 insertions(+), 16 deletions(-)
+
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index 03a2c6e17158..7fa2bbade327 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -432,17 +432,14 @@ static inline u32 hv_ringbuf_avail_percent(
+ return avail_write * 100 / ring_info->ring_datasize;
+ }
+
+-static void netvsc_send_completion(struct hv_device *device,
++static void netvsc_send_completion(struct netvsc_device *net_device,
++ struct hv_device *device,
+ struct vmpacket_descriptor *packet)
+ {
+- struct netvsc_device *net_device;
+ struct nvsp_message *nvsp_packet;
+ struct hv_netvsc_packet *nvsc_packet;
+ struct net_device *ndev;
+
+- net_device = get_inbound_net_device(device);
+- if (!net_device)
+- return;
+ ndev = net_device->ndev;
+
+ nvsp_packet = (struct nvsp_message *)((unsigned long)packet +
+@@ -561,13 +558,13 @@ int netvsc_send(struct hv_device *device,
+ }
+
+ static void netvsc_send_recv_completion(struct hv_device *device,
++ struct netvsc_device *net_device,
+ u64 transaction_id, u32 status)
+ {
+ struct nvsp_message recvcompMessage;
+ int retries = 0;
+ int ret;
+ struct net_device *ndev;
+- struct netvsc_device *net_device = hv_get_drvdata(device);
+
+ ndev = net_device->ndev;
+
+@@ -653,14 +650,15 @@ static void netvsc_receive_completion(void *context)
+
+ /* Send a receive completion for the xfer page packet */
+ if (fsend_receive_comp)
+- netvsc_send_recv_completion(device, transaction_id, status);
++ netvsc_send_recv_completion(device, net_device, transaction_id,
++ status);
+
+ }
+
+-static void netvsc_receive(struct hv_device *device,
+- struct vmpacket_descriptor *packet)
++static void netvsc_receive(struct netvsc_device *net_device,
++ struct hv_device *device,
++ struct vmpacket_descriptor *packet)
+ {
+- struct netvsc_device *net_device;
+ struct vmtransfer_page_packet_header *vmxferpage_packet;
+ struct nvsp_message *nvsp_packet;
+ struct hv_netvsc_packet *netvsc_packet = NULL;
+@@ -673,9 +671,6 @@ static void netvsc_receive(struct hv_device *device,
+
+ LIST_HEAD(listHead);
+
+- net_device = get_inbound_net_device(device);
+- if (!net_device)
+- return;
+ ndev = net_device->ndev;
+
+ /*
+@@ -741,7 +736,7 @@ static void netvsc_receive(struct hv_device *device,
+ spin_unlock_irqrestore(&net_device->recv_pkt_list_lock,
+ flags);
+
+- netvsc_send_recv_completion(device,
++ netvsc_send_recv_completion(device, net_device,
+ vmxferpage_packet->d.trans_id,
+ NVSP_STAT_FAIL);
+
+@@ -825,11 +820,13 @@ static void netvsc_channel_cb(void *context)
+ desc = (struct vmpacket_descriptor *)buffer;
+ switch (desc->type) {
+ case VM_PKT_COMP:
+- netvsc_send_completion(device, desc);
++ netvsc_send_completion(net_device,
++ device, desc);
+ break;
+
+ case VM_PKT_DATA_USING_XFER_PAGES:
+- netvsc_receive(device, desc);
++ netvsc_receive(net_device,
++ device, desc);
+ break;
+
+ default:
+--
+2.4.3
+
--- /dev/null
+From 4baab26129e0540746744232022110dbe9e011e7 Mon Sep 17 00:00:00 2001
+From: Haiyang Zhang <haiyangz@microsoft.com>
+Date: Mon, 21 Apr 2014 14:54:43 -0700
+Subject: [PATCH 02/11] hyperv: Remove recv_pkt_list and lock
+
+Removed recv_pkt_list and lock, and updated related code, so that
+the locking overhead is reduced especially when multiple channels
+are in use.
+
+The recv_pkt_list isn't actually necessary because the packets are
+processed sequentially in each channel. It has been replaced by a
+local variable, and the related lock for this list is also removed.
+The is_data_pkt field is not used in receive path, so its assignment
+is cleaned up.
+
+Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
+Reviewed-by: K. Y. Srinivasan <kys@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 33 --------
+ drivers/net/hyperv/netvsc.c | 174 +++-----------------------------------
+ drivers/net/hyperv/netvsc_drv.c | 2 +-
+ drivers/net/hyperv/rndis_filter.c | 2 -
+ 4 files changed, 13 insertions(+), 198 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index 57eb3f906d64..a1af0f7711e2 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -119,27 +119,14 @@ struct ndis_recv_scale_param { /* NDIS_RECEIVE_SCALE_PARAMETERS */
+ };
+
+ /* Fwd declaration */
+-struct hv_netvsc_packet;
+ struct ndis_tcp_ip_checksum_info;
+
+-/* Represent the xfer page packet which contains 1 or more netvsc packet */
+-struct xferpage_packet {
+- struct list_head list_ent;
+- u32 status;
+-
+- /* # of netvsc packets this xfer packet contains */
+- u32 count;
+-
+- struct vmbus_channel *channel;
+-};
+-
+ /*
+ * Represent netvsc packet which contains 1 RNDIS and 1 ethernet frame
+ * within the RNDIS
+ */
+ struct hv_netvsc_packet {
+ /* Bookkeeping stuff */
+- struct list_head list_ent;
+ u32 status;
+
+ struct hv_device *device;
+@@ -149,19 +136,8 @@ struct hv_netvsc_packet {
+ u16 q_idx;
+ struct vmbus_channel *channel;
+
+- /*
+- * Valid only for receives when we break a xfer page packet
+- * into multiple netvsc packets
+- */
+- struct xferpage_packet *xfer_page_pkt;
+-
+ union {
+ struct {
+- u64 recv_completion_tid;
+- void *recv_completion_ctx;
+- void (*recv_completion)(void *context);
+- } recv;
+- struct {
+ u64 send_completion_tid;
+ void *send_completion_ctx;
+ void (*send_completion)(void *context);
+@@ -613,9 +589,6 @@ struct nvsp_message {
+
+ #define NETVSC_RECEIVE_BUFFER_ID 0xcafe
+
+-/* Preallocated receive packets */
+-#define NETVSC_RECEIVE_PACKETLIST_COUNT 256
+-
+ #define NETVSC_PACKET_SIZE 2048
+
+ #define VRSS_SEND_TAB_SIZE 16
+@@ -630,12 +603,6 @@ struct netvsc_device {
+ wait_queue_head_t wait_drain;
+ bool start_remove;
+ bool destroy;
+- /*
+- * List of free preallocated hv_netvsc_packet to represent receive
+- * packet
+- */
+- struct list_head recv_pkt_list;
+- spinlock_t recv_pkt_list_lock;
+
+ /* Receive buffer allocated by us but manages by NetVSP */
+ void *recv_buf;
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index e7e77f12bc38..b10334773b32 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -387,7 +387,6 @@ static void netvsc_disconnect_vsp(struct netvsc_device *net_device)
+ int netvsc_device_remove(struct hv_device *device)
+ {
+ struct netvsc_device *net_device;
+- struct hv_netvsc_packet *netvsc_packet, *pos;
+ unsigned long flags;
+
+ net_device = hv_get_drvdata(device);
+@@ -416,12 +415,6 @@ int netvsc_device_remove(struct hv_device *device)
+ vmbus_close(device->channel);
+
+ /* Release all resources */
+- list_for_each_entry_safe(netvsc_packet, pos,
+- &net_device->recv_pkt_list, list_ent) {
+- list_del(&netvsc_packet->list_ent);
+- kfree(netvsc_packet);
+- }
+-
+ if (net_device->sub_cb_buf)
+ vfree(net_device->sub_cb_buf);
+
+@@ -641,62 +634,6 @@ retry_send_cmplt:
+ }
+ }
+
+-/* Send a receive completion packet to RNDIS device (ie NetVsp) */
+-static void netvsc_receive_completion(void *context)
+-{
+- struct hv_netvsc_packet *packet = context;
+- struct hv_device *device = packet->device;
+- struct vmbus_channel *channel;
+- struct netvsc_device *net_device;
+- u64 transaction_id = 0;
+- bool fsend_receive_comp = false;
+- unsigned long flags;
+- struct net_device *ndev;
+- u32 status = NVSP_STAT_NONE;
+-
+- /*
+- * Even though it seems logical to do a GetOutboundNetDevice() here to
+- * send out receive completion, we are using GetInboundNetDevice()
+- * since we may have disable outbound traffic already.
+- */
+- net_device = get_inbound_net_device(device);
+- if (!net_device)
+- return;
+- ndev = net_device->ndev;
+-
+- /* Overloading use of the lock. */
+- spin_lock_irqsave(&net_device->recv_pkt_list_lock, flags);
+-
+- if (packet->status != NVSP_STAT_SUCCESS)
+- packet->xfer_page_pkt->status = NVSP_STAT_FAIL;
+-
+- packet->xfer_page_pkt->count--;
+-
+- /*
+- * Last one in the line that represent 1 xfer page packet.
+- * Return the xfer page packet itself to the freelist
+- */
+- if (packet->xfer_page_pkt->count == 0) {
+- fsend_receive_comp = true;
+- channel = packet->xfer_page_pkt->channel;
+- transaction_id = packet->completion.recv.recv_completion_tid;
+- status = packet->xfer_page_pkt->status;
+- list_add_tail(&packet->xfer_page_pkt->list_ent,
+- &net_device->recv_pkt_list);
+-
+- }
+-
+- /* Put the packet back */
+- list_add_tail(&packet->list_ent, &net_device->recv_pkt_list);
+- spin_unlock_irqrestore(&net_device->recv_pkt_list_lock, flags);
+-
+- /* Send a receive completion for the xfer page packet */
+- if (fsend_receive_comp)
+- netvsc_send_recv_completion(device, channel, net_device,
+- transaction_id, status);
+-
+-}
+-
+ static void netvsc_receive(struct netvsc_device *net_device,
+ struct vmbus_channel *channel,
+ struct hv_device *device,
+@@ -704,16 +641,13 @@ static void netvsc_receive(struct netvsc_device *net_device,
+ {
+ struct vmtransfer_page_packet_header *vmxferpage_packet;
+ struct nvsp_message *nvsp_packet;
+- struct hv_netvsc_packet *netvsc_packet = NULL;
+- /* struct netvsc_driver *netvscDriver; */
+- struct xferpage_packet *xferpage_packet = NULL;
++ struct hv_netvsc_packet nv_pkt;
++ struct hv_netvsc_packet *netvsc_packet = &nv_pkt;
++ u32 status = NVSP_STAT_SUCCESS;
+ int i;
+ int count = 0;
+- unsigned long flags;
+ struct net_device *ndev;
+
+- LIST_HEAD(listHead);
+-
+ ndev = net_device->ndev;
+
+ /*
+@@ -746,78 +680,14 @@ static void netvsc_receive(struct netvsc_device *net_device,
+ return;
+ }
+
+- /*
+- * Grab free packets (range count + 1) to represent this xfer
+- * page packet. +1 to represent the xfer page packet itself.
+- * We grab it here so that we know exactly how many we can
+- * fulfil
+- */
+- spin_lock_irqsave(&net_device->recv_pkt_list_lock, flags);
+- while (!list_empty(&net_device->recv_pkt_list)) {
+- list_move_tail(net_device->recv_pkt_list.next, &listHead);
+- if (++count == vmxferpage_packet->range_cnt + 1)
+- break;
+- }
+- spin_unlock_irqrestore(&net_device->recv_pkt_list_lock, flags);
+-
+- /*
+- * We need at least 2 netvsc pkts (1 to represent the xfer
+- * page and at least 1 for the range) i.e. we can handled
+- * some of the xfer page packet ranges...
+- */
+- if (count < 2) {
+- netdev_err(ndev, "Got only %d netvsc pkt...needed "
+- "%d pkts. Dropping this xfer page packet completely!\n",
+- count, vmxferpage_packet->range_cnt + 1);
+-
+- /* Return it to the freelist */
+- spin_lock_irqsave(&net_device->recv_pkt_list_lock, flags);
+- for (i = count; i != 0; i--) {
+- list_move_tail(listHead.next,
+- &net_device->recv_pkt_list);
+- }
+- spin_unlock_irqrestore(&net_device->recv_pkt_list_lock,
+- flags);
+-
+- netvsc_send_recv_completion(device, channel, net_device,
+- vmxferpage_packet->d.trans_id,
+- NVSP_STAT_FAIL);
+-
+- return;
+- }
+-
+- /* Remove the 1st packet to represent the xfer page packet itself */
+- xferpage_packet = (struct xferpage_packet *)listHead.next;
+- list_del(&xferpage_packet->list_ent);
+- xferpage_packet->status = NVSP_STAT_SUCCESS;
+- xferpage_packet->channel = channel;
+-
+- /* This is how much we can satisfy */
+- xferpage_packet->count = count - 1;
+-
+- if (xferpage_packet->count != vmxferpage_packet->range_cnt) {
+- netdev_err(ndev, "Needed %d netvsc pkts to satisfy "
+- "this xfer page...got %d\n",
+- vmxferpage_packet->range_cnt, xferpage_packet->count);
+- }
++ count = vmxferpage_packet->range_cnt;
++ netvsc_packet->device = device;
++ netvsc_packet->channel = channel;
+
+ /* Each range represents 1 RNDIS pkt that contains 1 ethernet frame */
+- for (i = 0; i < (count - 1); i++) {
+- netvsc_packet = (struct hv_netvsc_packet *)listHead.next;
+- list_del(&netvsc_packet->list_ent);
+-
++ for (i = 0; i < count; i++) {
+ /* Initialize the netvsc packet */
+ netvsc_packet->status = NVSP_STAT_SUCCESS;
+- netvsc_packet->xfer_page_pkt = xferpage_packet;
+- netvsc_packet->completion.recv.recv_completion =
+- netvsc_receive_completion;
+- netvsc_packet->completion.recv.recv_completion_ctx =
+- netvsc_packet;
+- netvsc_packet->device = device;
+- /* Save this so that we can send it back */
+- netvsc_packet->completion.recv.recv_completion_tid =
+- vmxferpage_packet->d.trans_id;
+-
+ netvsc_packet->data = (void *)((unsigned long)net_device->
+ recv_buf + vmxferpage_packet->ranges[i].byte_offset);
+ netvsc_packet->total_data_buflen =
+@@ -826,10 +696,12 @@ static void netvsc_receive(struct netvsc_device *net_device,
+ /* Pass it to the upper layer */
+ rndis_filter_receive(device, netvsc_packet);
+
+- netvsc_receive_completion(netvsc_packet->
+- completion.recv.recv_completion_ctx);
++ if (netvsc_packet->status != NVSP_STAT_SUCCESS)
++ status = NVSP_STAT_FAIL;
+ }
+
++ netvsc_send_recv_completion(device, channel, net_device,
++ vmxferpage_packet->d.trans_id, status);
+ }
+
+
+@@ -956,11 +828,9 @@ void netvsc_channel_cb(void *context)
+ int netvsc_device_add(struct hv_device *device, void *additional_info)
+ {
+ int ret = 0;
+- int i;
+ int ring_size =
+ ((struct netvsc_device_info *)additional_info)->ring_size;
+ struct netvsc_device *net_device;
+- struct hv_netvsc_packet *packet, *pos;
+ struct net_device *ndev;
+
+ net_device = alloc_net_device(device);
+@@ -981,18 +851,6 @@ int netvsc_device_add(struct hv_device *device, void *additional_info)
+ ndev = net_device->ndev;
+
+ /* Initialize the NetVSC channel extension */
+- spin_lock_init(&net_device->recv_pkt_list_lock);
+-
+- INIT_LIST_HEAD(&net_device->recv_pkt_list);
+-
+- for (i = 0; i < NETVSC_RECEIVE_PACKETLIST_COUNT; i++) {
+- packet = kzalloc(sizeof(struct hv_netvsc_packet), GFP_KERNEL);
+- if (!packet)
+- break;
+-
+- list_add_tail(&packet->list_ent,
+- &net_device->recv_pkt_list);
+- }
+ init_completion(&net_device->channel_init_wait);
+
+ set_per_channel_state(device->channel, net_device->cb_buffer);
+@@ -1028,16 +886,8 @@ close:
+
+ cleanup:
+
+- if (net_device) {
+- list_for_each_entry_safe(packet, pos,
+- &net_device->recv_pkt_list,
+- list_ent) {
+- list_del(&packet->list_ent);
+- kfree(packet);
+- }
+-
++ if (net_device)
+ kfree(net_device);
+- }
+
+ return ret;
+ }
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 093cf3fc46b8..8f6d53a2ed95 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -638,7 +638,7 @@ int netvsc_recv_callback(struct hv_device *device_obj,
+ __vlan_hwaccel_put_tag(skb, htons(ETH_P_8021Q),
+ packet->vlan_tci);
+
+- skb_record_rx_queue(skb, packet->xfer_page_pkt->channel->
++ skb_record_rx_queue(skb, packet->channel->
+ offermsg.offer.sub_channel_index %
+ net->real_num_rx_queues);
+
+diff --git a/drivers/net/hyperv/rndis_filter.c b/drivers/net/hyperv/rndis_filter.c
+index d92cfbe43410..48f5a0fbd674 100644
+--- a/drivers/net/hyperv/rndis_filter.c
++++ b/drivers/net/hyperv/rndis_filter.c
+@@ -401,8 +401,6 @@ static void rndis_filter_receive_data(struct rndis_device *dev,
+ pkt->total_data_buflen = rndis_pkt->data_len;
+ pkt->data = (void *)((unsigned long)pkt->data + data_offset);
+
+- pkt->is_data_pkt = true;
+-
+ vlan = rndis_get_ppi(rndis_pkt, IEEE_8021Q_INFO);
+ if (vlan) {
+ pkt->vlan_tci = VLAN_TAG_PRESENT | vlan->vlanid |
+--
+2.4.3
+
--- /dev/null
+From c9f2db35ac4f789930522d9d36200cb71b442bed Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Sun, 16 Feb 2014 16:38:45 -0800
+Subject: [PATCH 03/25] Drivers: net: hyperv: Cleanup the netvsc receive
+ callback functio
+
+Get rid of the buffer allocation in the receive path for normal packets.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 2 ++
+ drivers/net/hyperv/netvsc.c | 33 ++++++++++-----------------------
+ 2 files changed, 12 insertions(+), 23 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index 7645ba38bde8..01a16ea77a5a 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -506,6 +506,8 @@ struct netvsc_device {
+
+ /* Holds rndis device info */
+ void *extension;
++ /* The recive buffer for this device */
++ unsigned char cb_buffer[NETVSC_PACKET_SIZE];
+ };
+
+ /* NdisInitialize message */
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index 7fa2bbade327..9a0e9c6f1414 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -795,22 +795,16 @@ static void netvsc_channel_cb(void *context)
+ struct netvsc_device *net_device;
+ u32 bytes_recvd;
+ u64 request_id;
+- unsigned char *packet;
+ struct vmpacket_descriptor *desc;
+ unsigned char *buffer;
+ int bufferlen = NETVSC_PACKET_SIZE;
+ struct net_device *ndev;
+
+- packet = kzalloc(NETVSC_PACKET_SIZE * sizeof(unsigned char),
+- GFP_ATOMIC);
+- if (!packet)
+- return;
+- buffer = packet;
+-
+ net_device = get_inbound_net_device(device);
+ if (!net_device)
+- goto out;
++ return;
+ ndev = net_device->ndev;
++ buffer = net_device->cb_buffer;
+
+ do {
+ ret = vmbus_recvpacket_raw(device->channel, buffer, bufferlen,
+@@ -838,23 +832,16 @@ static void netvsc_channel_cb(void *context)
+ break;
+ }
+
+- /* reset */
+- if (bufferlen > NETVSC_PACKET_SIZE) {
+- kfree(buffer);
+- buffer = packet;
+- bufferlen = NETVSC_PACKET_SIZE;
+- }
+ } else {
+- /* reset */
+- if (bufferlen > NETVSC_PACKET_SIZE) {
+- kfree(buffer);
+- buffer = packet;
+- bufferlen = NETVSC_PACKET_SIZE;
+- }
+-
++ /*
++ * We are done for this pass.
++ */
+ break;
+ }
++
+ } else if (ret == -ENOBUFS) {
++ if (bufferlen > NETVSC_PACKET_SIZE)
++ kfree(buffer);
+ /* Handle large packet */
+ buffer = kmalloc(bytes_recvd, GFP_ATOMIC);
+ if (buffer == NULL) {
+@@ -869,8 +856,8 @@ static void netvsc_channel_cb(void *context)
+ }
+ } while (1);
+
+-out:
+- kfree(buffer);
++ if (bufferlen > NETVSC_PACKET_SIZE)
++ kfree(buffer);
+ return;
+ }
+
+--
+2.4.3
+
--- /dev/null
+From 893f66277799cd46bdf97429cc5d16a815a51273 Mon Sep 17 00:00:00 2001
+From: Haiyang Zhang <haiyangz@microsoft.com>
+Date: Mon, 21 Apr 2014 14:54:44 -0700
+Subject: [PATCH 03/11] hyperv: Simplify the send_completion variables
+
+The union contains only one member now, so we use the variables in it directly.
+
+Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
+Reviewed-by: K. Y. Srinivasan <kys@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 10 +++-------
+ drivers/net/hyperv/netvsc.c | 7 +++----
+ drivers/net/hyperv/netvsc_drv.c | 8 ++++----
+ drivers/net/hyperv/rndis_filter.c | 2 +-
+ 4 files changed, 11 insertions(+), 16 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index a1af0f7711e2..d1f7826aa75f 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -136,13 +136,9 @@ struct hv_netvsc_packet {
+ u16 q_idx;
+ struct vmbus_channel *channel;
+
+- union {
+- struct {
+- u64 send_completion_tid;
+- void *send_completion_ctx;
+- void (*send_completion)(void *context);
+- } send;
+- } completion;
++ u64 send_completion_tid;
++ void *send_completion_ctx;
++ void (*send_completion)(void *context);
+
+ /* This points to the memory after page_buf */
+ struct rndis_message *rndis_msg;
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index b10334773b32..bbee44635035 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -479,9 +479,8 @@ static void netvsc_send_completion(struct netvsc_device *net_device,
+ if (nvsc_packet) {
+ q_idx = nvsc_packet->q_idx;
+ channel = nvsc_packet->channel;
+- nvsc_packet->completion.send.send_completion(
+- nvsc_packet->completion.send.
+- send_completion_ctx);
++ nvsc_packet->send_completion(nvsc_packet->
++ send_completion_ctx);
+ }
+
+ num_outstanding_sends =
+@@ -534,7 +533,7 @@ int netvsc_send(struct hv_device *device,
+ 0xFFFFFFFF;
+ sendMessage.msg.v1_msg.send_rndis_pkt.send_buf_section_size = 0;
+
+- if (packet->completion.send.send_completion)
++ if (packet->send_completion)
+ req_id = (ulong)packet;
+ else
+ req_id = 0;
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 8f6d53a2ed95..c76b66515e92 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -235,7 +235,7 @@ static void netvsc_xmit_completion(void *context)
+ {
+ struct hv_netvsc_packet *packet = (struct hv_netvsc_packet *)context;
+ struct sk_buff *skb = (struct sk_buff *)
+- (unsigned long)packet->completion.send.send_completion_tid;
++ (unsigned long)packet->send_completion_tid;
+
+ kfree(packet);
+
+@@ -425,9 +425,9 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ (num_data_pgs * sizeof(struct hv_page_buffer)));
+
+ /* Set the completion routine */
+- packet->completion.send.send_completion = netvsc_xmit_completion;
+- packet->completion.send.send_completion_ctx = packet;
+- packet->completion.send.send_completion_tid = (unsigned long)skb;
++ packet->send_completion = netvsc_xmit_completion;
++ packet->send_completion_ctx = packet;
++ packet->send_completion_tid = (unsigned long)skb;
+
+ isvlan = packet->vlan_tci & VLAN_TAG_PRESENT;
+
+diff --git a/drivers/net/hyperv/rndis_filter.c b/drivers/net/hyperv/rndis_filter.c
+index 48f5a0fbd674..99c527adae5b 100644
+--- a/drivers/net/hyperv/rndis_filter.c
++++ b/drivers/net/hyperv/rndis_filter.c
+@@ -236,7 +236,7 @@ static int rndis_filter_send_request(struct rndis_device *dev,
+ packet->page_buf[0].len;
+ }
+
+- packet->completion.send.send_completion = NULL;
++ packet->send_completion = NULL;
+
+ ret = netvsc_send(dev->net_dev->dev, packet);
+ return ret;
+--
+2.4.3
+
--- /dev/null
+From 3c2a271d9681cc017947c5e027acc64707c30dee Mon Sep 17 00:00:00 2001
+From: Haiyang Zhang <haiyangz@microsoft.com>
+Date: Wed, 19 Feb 2014 15:49:45 -0800
+Subject: [PATCH 04/25] hyperv: Add latest NetVSP versions to auto negotiation
+
+It auto negotiates the highest NetVSP version supported by both guest and host.
+
+Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
+Reviewed-by: K. Y. Srinivasan <kys@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 53 +++++++++++++++++++++++++++++++++++++++++
+ drivers/net/hyperv/netvsc.c | 25 ++++++++++++-------
+ drivers/net/hyperv/netvsc_drv.c | 2 +-
+ 3 files changed, 70 insertions(+), 10 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index 01a16ea77a5a..39fc230f5c20 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -139,6 +139,8 @@ int rndis_filter_set_device_mac(struct hv_device *hdev, char *mac);
+
+ #define NVSP_PROTOCOL_VERSION_1 2
+ #define NVSP_PROTOCOL_VERSION_2 0x30002
++#define NVSP_PROTOCOL_VERSION_4 0x40000
++#define NVSP_PROTOCOL_VERSION_5 0x50000
+
+ enum {
+ NVSP_MSG_TYPE_NONE = 0,
+@@ -193,6 +195,23 @@ enum {
+
+ NVSP_MSG2_TYPE_ALLOC_CHIMNEY_HANDLE,
+ NVSP_MSG2_TYPE_ALLOC_CHIMNEY_HANDLE_COMP,
++
++ NVSP_MSG2_MAX = NVSP_MSG2_TYPE_ALLOC_CHIMNEY_HANDLE_COMP,
++
++ /* Version 4 messages */
++ NVSP_MSG4_TYPE_SEND_VF_ASSOCIATION,
++ NVSP_MSG4_TYPE_SWITCH_DATA_PATH,
++ NVSP_MSG4_TYPE_UPLINK_CONNECT_STATE_DEPRECATED,
++
++ NVSP_MSG4_MAX = NVSP_MSG4_TYPE_UPLINK_CONNECT_STATE_DEPRECATED,
++
++ /* Version 5 messages */
++ NVSP_MSG5_TYPE_OID_QUERY_EX,
++ NVSP_MSG5_TYPE_OID_QUERY_EX_COMP,
++ NVSP_MSG5_TYPE_SUBCHANNEL,
++ NVSP_MSG5_TYPE_SEND_INDIRECTION_TABLE,
++
++ NVSP_MSG5_MAX = NVSP_MSG5_TYPE_SEND_INDIRECTION_TABLE,
+ };
+
+ enum {
+@@ -447,10 +466,44 @@ union nvsp_2_message_uber {
+ struct nvsp_2_free_rxbuf free_rxbuf;
+ } __packed;
+
++enum nvsp_subchannel_operation {
++ NVSP_SUBCHANNEL_NONE = 0,
++ NVSP_SUBCHANNEL_ALLOCATE,
++ NVSP_SUBCHANNEL_MAX
++};
++
++struct nvsp_5_subchannel_request {
++ u32 op;
++ u32 num_subchannels;
++} __packed;
++
++struct nvsp_5_subchannel_complete {
++ u32 status;
++ u32 num_subchannels; /* Actual number of subchannels allocated */
++} __packed;
++
++struct nvsp_5_send_indirect_table {
++ /* The number of entries in the send indirection table */
++ u32 count;
++
++ /* The offset of the send indireciton table from top of this struct.
++ * The send indirection table tells which channel to put the send
++ * traffic on. Each entry is a channel number.
++ */
++ u32 offset;
++} __packed;
++
++union nvsp_5_message_uber {
++ struct nvsp_5_subchannel_request subchn_req;
++ struct nvsp_5_subchannel_complete subchn_comp;
++ struct nvsp_5_send_indirect_table send_table;
++} __packed;
++
+ union nvsp_all_messages {
+ union nvsp_message_init_uber init_msg;
+ union nvsp_1_message_uber v1_msg;
+ union nvsp_2_message_uber v2_msg;
++ union nvsp_5_message_uber v5_msg;
+ } __packed;
+
+ /* ALL Messages */
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index 9a0e9c6f1414..1a0280dcba7e 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -290,7 +290,7 @@ static int negotiate_nvsp_ver(struct hv_device *device,
+ NVSP_STAT_SUCCESS)
+ return -EINVAL;
+
+- if (nvsp_ver != NVSP_PROTOCOL_VERSION_2)
++ if (nvsp_ver == NVSP_PROTOCOL_VERSION_1)
+ return 0;
+
+ /* NVSPv2 only: Send NDIS config */
+@@ -314,6 +314,9 @@ static int netvsc_connect_vsp(struct hv_device *device)
+ struct nvsp_message *init_packet;
+ int ndis_version;
+ struct net_device *ndev;
++ u32 ver_list[] = { NVSP_PROTOCOL_VERSION_1, NVSP_PROTOCOL_VERSION_2,
++ NVSP_PROTOCOL_VERSION_4, NVSP_PROTOCOL_VERSION_5 };
++ int i, num_ver = 4; /* number of different NVSP versions */
+
+ net_device = get_outbound_net_device(device);
+ if (!net_device)
+@@ -323,13 +326,14 @@ static int netvsc_connect_vsp(struct hv_device *device)
+ init_packet = &net_device->channel_init_pkt;
+
+ /* Negotiate the latest NVSP protocol supported */
+- if (negotiate_nvsp_ver(device, net_device, init_packet,
+- NVSP_PROTOCOL_VERSION_2) == 0) {
+- net_device->nvsp_version = NVSP_PROTOCOL_VERSION_2;
+- } else if (negotiate_nvsp_ver(device, net_device, init_packet,
+- NVSP_PROTOCOL_VERSION_1) == 0) {
+- net_device->nvsp_version = NVSP_PROTOCOL_VERSION_1;
+- } else {
++ for (i = num_ver - 1; i >= 0; i--)
++ if (negotiate_nvsp_ver(device, net_device, init_packet,
++ ver_list[i]) == 0) {
++ net_device->nvsp_version = ver_list[i];
++ break;
++ }
++
++ if (i < 0) {
+ ret = -EPROTO;
+ goto cleanup;
+ }
+@@ -339,7 +343,10 @@ static int netvsc_connect_vsp(struct hv_device *device)
+ /* Send the ndis version */
+ memset(init_packet, 0, sizeof(struct nvsp_message));
+
+- ndis_version = 0x00050001;
++ if (net_device->nvsp_version <= NVSP_PROTOCOL_VERSION_4)
++ ndis_version = 0x00050001;
++ else
++ ndis_version = 0x0006001e;
+
+ init_packet->hdr.msg_type = NVSP_MSG1_TYPE_SEND_NDIS_VER;
+ init_packet->msg.v1_msg.
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 28020f83ba6f..8e3a0b00099b 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -328,7 +328,7 @@ static int netvsc_change_mtu(struct net_device *ndev, int mtu)
+ if (nvdev == NULL || nvdev->destroy)
+ return -ENODEV;
+
+- if (nvdev->nvsp_version == NVSP_PROTOCOL_VERSION_2)
++ if (nvdev->nvsp_version >= NVSP_PROTOCOL_VERSION_2)
+ limit = NETVSC_MTU;
+
+ if (mtu < 68 || mtu > limit)
+--
+2.4.3
+
--- /dev/null
+From c25aaf814a63f9d9c4e45416f13d70ef0aa0be2e Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Wed, 30 Apr 2014 10:14:31 -0700
+Subject: [PATCH 04/11] hyperv: Enable sendbuf mechanism on the send path
+
+We send packets using a copy-free mechanism (this is the Guest to Host transport
+via VMBUS). While this is obviously optimal for large packets,
+it may not be optimal for small packets. Hyper-V host supports
+a second mechanism for sending packets that is "copy based". We implement that
+mechanism in this patch.
+
+In this version of the patch I have addressed a comment from David Miller.
+
+With this patch (and all of the other offload and VRSS patches), we are now able
+to almost saturate a 10G interface between Linux VMs on Hyper-V
+on different hosts - close to 9 Gbps as measured via iperf.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 14 +++
+ drivers/net/hyperv/netvsc.c | 226 ++++++++++++++++++++++++++++++++++++++--
+ drivers/net/hyperv/netvsc_drv.c | 3 +-
+ 3 files changed, 234 insertions(+), 9 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index d1f7826aa75f..4b7df5a5c966 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -140,6 +140,8 @@ struct hv_netvsc_packet {
+ void *send_completion_ctx;
+ void (*send_completion)(void *context);
+
++ u32 send_buf_index;
++
+ /* This points to the memory after page_buf */
+ struct rndis_message *rndis_msg;
+
+@@ -582,6 +584,9 @@ struct nvsp_message {
+
+ #define NETVSC_RECEIVE_BUFFER_SIZE (1024*1024*16) /* 16MB */
+ #define NETVSC_RECEIVE_BUFFER_SIZE_LEGACY (1024*1024*15) /* 15MB */
++#define NETVSC_SEND_BUFFER_SIZE (1024 * 1024) /* 1MB */
++#define NETVSC_INVALID_INDEX -1
++
+
+ #define NETVSC_RECEIVE_BUFFER_ID 0xcafe
+
+@@ -607,6 +612,15 @@ struct netvsc_device {
+ u32 recv_section_cnt;
+ struct nvsp_1_receive_buffer_section *recv_section;
+
++ /* Send buffer allocated by us */
++ void *send_buf;
++ u32 send_buf_size;
++ u32 send_buf_gpadl_handle;
++ u32 send_section_cnt;
++ u32 send_section_size;
++ unsigned long *send_section_map;
++ int map_words;
++
+ /* Used for NetVSP initialization protocol */
+ struct completion channel_init_wait;
+ struct nvsp_message channel_init_pkt;
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index bbee44635035..c041f63a6d30 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -28,6 +28,7 @@
+ #include <linux/slab.h>
+ #include <linux/netdevice.h>
+ #include <linux/if_ether.h>
++#include <asm/sync_bitops.h>
+
+ #include "hyperv_net.h"
+
+@@ -80,7 +81,7 @@ get_in_err:
+ }
+
+
+-static int netvsc_destroy_recv_buf(struct netvsc_device *net_device)
++static int netvsc_destroy_buf(struct netvsc_device *net_device)
+ {
+ struct nvsp_message *revoke_packet;
+ int ret = 0;
+@@ -146,10 +147,62 @@ static int netvsc_destroy_recv_buf(struct netvsc_device *net_device)
+ net_device->recv_section = NULL;
+ }
+
++ /* Deal with the send buffer we may have setup.
++ * If we got a send section size, it means we received a
++ * SendsendBufferComplete msg (ie sent
++ * NvspMessage1TypeSendReceiveBuffer msg) therefore, we need
++ * to send a revoke msg here
++ */
++ if (net_device->send_section_size) {
++ /* Send the revoke receive buffer */
++ revoke_packet = &net_device->revoke_packet;
++ memset(revoke_packet, 0, sizeof(struct nvsp_message));
++
++ revoke_packet->hdr.msg_type =
++ NVSP_MSG1_TYPE_REVOKE_SEND_BUF;
++ revoke_packet->msg.v1_msg.revoke_recv_buf.id = 0;
++
++ ret = vmbus_sendpacket(net_device->dev->channel,
++ revoke_packet,
++ sizeof(struct nvsp_message),
++ (unsigned long)revoke_packet,
++ VM_PKT_DATA_INBAND, 0);
++ /* If we failed here, we might as well return and
++ * have a leak rather than continue and a bugchk
++ */
++ if (ret != 0) {
++ netdev_err(ndev, "unable to send "
++ "revoke send buffer to netvsp\n");
++ return ret;
++ }
++ }
++ /* Teardown the gpadl on the vsp end */
++ if (net_device->send_buf_gpadl_handle) {
++ ret = vmbus_teardown_gpadl(net_device->dev->channel,
++ net_device->send_buf_gpadl_handle);
++
++ /* If we failed here, we might as well return and have a leak
++ * rather than continue and a bugchk
++ */
++ if (ret != 0) {
++ netdev_err(ndev,
++ "unable to teardown send buffer's gpadl\n");
++ return ret;
++ }
++ net_device->recv_buf_gpadl_handle = 0;
++ }
++ if (net_device->send_buf) {
++ /* Free up the receive buffer */
++ free_pages((unsigned long)net_device->send_buf,
++ get_order(net_device->send_buf_size));
++ net_device->send_buf = NULL;
++ }
++ kfree(net_device->send_section_map);
++
+ return ret;
+ }
+
+-static int netvsc_init_recv_buf(struct hv_device *device)
++static int netvsc_init_buf(struct hv_device *device)
+ {
+ int ret = 0;
+ int t;
+@@ -248,10 +301,90 @@ static int netvsc_init_recv_buf(struct hv_device *device)
+ goto cleanup;
+ }
+
++ /* Now setup the send buffer.
++ */
++ net_device->send_buf =
++ (void *)__get_free_pages(GFP_KERNEL|__GFP_ZERO,
++ get_order(net_device->send_buf_size));
++ if (!net_device->send_buf) {
++ netdev_err(ndev, "unable to allocate send "
++ "buffer of size %d\n", net_device->send_buf_size);
++ ret = -ENOMEM;
++ goto cleanup;
++ }
++
++ /* Establish the gpadl handle for this buffer on this
++ * channel. Note: This call uses the vmbus connection rather
++ * than the channel to establish the gpadl handle.
++ */
++ ret = vmbus_establish_gpadl(device->channel, net_device->send_buf,
++ net_device->send_buf_size,
++ &net_device->send_buf_gpadl_handle);
++ if (ret != 0) {
++ netdev_err(ndev,
++ "unable to establish send buffer's gpadl\n");
++ goto cleanup;
++ }
++
++ /* Notify the NetVsp of the gpadl handle */
++ init_packet = &net_device->channel_init_pkt;
++ memset(init_packet, 0, sizeof(struct nvsp_message));
++ init_packet->hdr.msg_type = NVSP_MSG1_TYPE_SEND_SEND_BUF;
++ init_packet->msg.v1_msg.send_recv_buf.gpadl_handle =
++ net_device->send_buf_gpadl_handle;
++ init_packet->msg.v1_msg.send_recv_buf.id = 0;
++
++ /* Send the gpadl notification request */
++ ret = vmbus_sendpacket(device->channel, init_packet,
++ sizeof(struct nvsp_message),
++ (unsigned long)init_packet,
++ VM_PKT_DATA_INBAND,
++ VMBUS_DATA_PACKET_FLAG_COMPLETION_REQUESTED);
++ if (ret != 0) {
++ netdev_err(ndev,
++ "unable to send send buffer's gpadl to netvsp\n");
++ goto cleanup;
++ }
++
++ t = wait_for_completion_timeout(&net_device->channel_init_wait, 5*HZ);
++ BUG_ON(t == 0);
++
++ /* Check the response */
++ if (init_packet->msg.v1_msg.
++ send_send_buf_complete.status != NVSP_STAT_SUCCESS) {
++ netdev_err(ndev, "Unable to complete send buffer "
++ "initialization with NetVsp - status %d\n",
++ init_packet->msg.v1_msg.
++ send_recv_buf_complete.status);
++ ret = -EINVAL;
++ goto cleanup;
++ }
++
++ /* Parse the response */
++ net_device->send_section_size = init_packet->msg.
++ v1_msg.send_send_buf_complete.section_size;
++
++ /* Section count is simply the size divided by the section size.
++ */
++ net_device->send_section_cnt =
++ net_device->send_buf_size/net_device->send_section_size;
++
++ dev_info(&device->device, "Send section size: %d, Section count:%d\n",
++ net_device->send_section_size, net_device->send_section_cnt);
++
++ /* Setup state for managing the send buffer. */
++ net_device->map_words = DIV_ROUND_UP(net_device->send_section_cnt,
++ BITS_PER_LONG);
++
++ net_device->send_section_map =
++ kzalloc(net_device->map_words * sizeof(ulong), GFP_KERNEL);
++ if (net_device->send_section_map == NULL)
++ goto cleanup;
++
+ goto exit;
+
+ cleanup:
+- netvsc_destroy_recv_buf(net_device);
++ netvsc_destroy_buf(net_device);
+
+ exit:
+ return ret;
+@@ -369,8 +502,9 @@ static int netvsc_connect_vsp(struct hv_device *device)
+ net_device->recv_buf_size = NETVSC_RECEIVE_BUFFER_SIZE_LEGACY;
+ else
+ net_device->recv_buf_size = NETVSC_RECEIVE_BUFFER_SIZE;
++ net_device->send_buf_size = NETVSC_SEND_BUFFER_SIZE;
+
+- ret = netvsc_init_recv_buf(device);
++ ret = netvsc_init_buf(device);
+
+ cleanup:
+ return ret;
+@@ -378,7 +512,7 @@ cleanup:
+
+ static void netvsc_disconnect_vsp(struct netvsc_device *net_device)
+ {
+- netvsc_destroy_recv_buf(net_device);
++ netvsc_destroy_buf(net_device);
+ }
+
+ /*
+@@ -440,6 +574,12 @@ static inline u32 hv_ringbuf_avail_percent(
+ return avail_write * 100 / ring_info->ring_datasize;
+ }
+
++static inline void netvsc_free_send_slot(struct netvsc_device *net_device,
++ u32 index)
++{
++ sync_change_bit(index, net_device->send_section_map);
++}
++
+ static void netvsc_send_completion(struct netvsc_device *net_device,
+ struct hv_device *device,
+ struct vmpacket_descriptor *packet)
+@@ -447,6 +587,7 @@ static void netvsc_send_completion(struct netvsc_device *net_device,
+ struct nvsp_message *nvsp_packet;
+ struct hv_netvsc_packet *nvsc_packet;
+ struct net_device *ndev;
++ u32 send_index;
+
+ ndev = net_device->ndev;
+
+@@ -477,6 +618,9 @@ static void netvsc_send_completion(struct netvsc_device *net_device,
+
+ /* Notify the layer above us */
+ if (nvsc_packet) {
++ send_index = nvsc_packet->send_buf_index;
++ if (send_index != NETVSC_INVALID_INDEX)
++ netvsc_free_send_slot(net_device, send_index);
+ q_idx = nvsc_packet->q_idx;
+ channel = nvsc_packet->channel;
+ nvsc_packet->send_completion(nvsc_packet->
+@@ -504,6 +648,52 @@ static void netvsc_send_completion(struct netvsc_device *net_device,
+
+ }
+
++static u32 netvsc_get_next_send_section(struct netvsc_device *net_device)
++{
++ unsigned long index;
++ u32 max_words = net_device->map_words;
++ unsigned long *map_addr = (unsigned long *)net_device->send_section_map;
++ u32 section_cnt = net_device->send_section_cnt;
++ int ret_val = NETVSC_INVALID_INDEX;
++ int i;
++ int prev_val;
++
++ for (i = 0; i < max_words; i++) {
++ if (!~(map_addr[i]))
++ continue;
++ index = ffz(map_addr[i]);
++ prev_val = sync_test_and_set_bit(index, &map_addr[i]);
++ if (prev_val)
++ continue;
++ if ((index + (i * BITS_PER_LONG)) >= section_cnt)
++ break;
++ ret_val = (index + (i * BITS_PER_LONG));
++ break;
++ }
++ return ret_val;
++}
++
++u32 netvsc_copy_to_send_buf(struct netvsc_device *net_device,
++ unsigned int section_index,
++ struct hv_netvsc_packet *packet)
++{
++ char *start = net_device->send_buf;
++ char *dest = (start + (section_index * net_device->send_section_size));
++ int i;
++ u32 msg_size = 0;
++
++ for (i = 0; i < packet->page_buf_cnt; i++) {
++ char *src = phys_to_virt(packet->page_buf[i].pfn << PAGE_SHIFT);
++ u32 offset = packet->page_buf[i].offset;
++ u32 len = packet->page_buf[i].len;
++
++ memcpy(dest, (src + offset), len);
++ msg_size += len;
++ dest += len;
++ }
++ return msg_size;
++}
++
+ int netvsc_send(struct hv_device *device,
+ struct hv_netvsc_packet *packet)
+ {
+@@ -513,6 +703,10 @@ int netvsc_send(struct hv_device *device,
+ struct net_device *ndev;
+ struct vmbus_channel *out_channel = NULL;
+ u64 req_id;
++ unsigned int section_index = NETVSC_INVALID_INDEX;
++ u32 msg_size = 0;
++ struct sk_buff *skb;
++
+
+ net_device = get_outbound_net_device(device);
+ if (!net_device)
+@@ -528,10 +722,26 @@ int netvsc_send(struct hv_device *device,
+ sendMessage.msg.v1_msg.send_rndis_pkt.channel_type = 1;
+ }
+
+- /* Not using send buffer section */
++ /* Attempt to send via sendbuf */
++ if (packet->total_data_buflen < net_device->send_section_size) {
++ section_index = netvsc_get_next_send_section(net_device);
++ if (section_index != NETVSC_INVALID_INDEX) {
++ msg_size = netvsc_copy_to_send_buf(net_device,
++ section_index,
++ packet);
++ skb = (struct sk_buff *)
++ (unsigned long)packet->send_completion_tid;
++ if (skb)
++ dev_kfree_skb_any(skb);
++ packet->page_buf_cnt = 0;
++ }
++ }
++ packet->send_buf_index = section_index;
++
++
+ sendMessage.msg.v1_msg.send_rndis_pkt.send_buf_section_index =
+- 0xFFFFFFFF;
+- sendMessage.msg.v1_msg.send_rndis_pkt.send_buf_section_size = 0;
++ section_index;
++ sendMessage.msg.v1_msg.send_rndis_pkt.send_buf_section_size = msg_size;
+
+ if (packet->send_completion)
+ req_id = (ulong)packet;
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index c76b66515e92..939e3af60ec4 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -236,10 +236,11 @@ static void netvsc_xmit_completion(void *context)
+ struct hv_netvsc_packet *packet = (struct hv_netvsc_packet *)context;
+ struct sk_buff *skb = (struct sk_buff *)
+ (unsigned long)packet->send_completion_tid;
++ u32 index = packet->send_buf_index;
+
+ kfree(packet);
+
+- if (skb)
++ if (skb && (index == NETVSC_INVALID_INDEX))
+ dev_kfree_skb_any(skb);
+ }
+
+--
+2.4.3
+
--- /dev/null
+From e565e803d437b36c4fb4ced5e346827981183284 Mon Sep 17 00:00:00 2001
+From: Haiyang Zhang <haiyangz@microsoft.com>
+Date: Thu, 8 May 2014 15:14:10 -0700
+Subject: [PATCH 05/11] Add support for netvsc build without CONFIG_SYSFS flag
+
+This change ensures the driver can be built successfully without the
+CONFIG_SYSFS flag.
+MS-TFS: 182270
+
+Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
+Reviewed-by: K. Y. Srinivasan <kys@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/netvsc_drv.c | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 939e3af60ec4..083d084396d3 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -640,8 +640,7 @@ int netvsc_recv_callback(struct hv_device *device_obj,
+ packet->vlan_tci);
+
+ skb_record_rx_queue(skb, packet->channel->
+- offermsg.offer.sub_channel_index %
+- net->real_num_rx_queues);
++ offermsg.offer.sub_channel_index);
+
+ net->stats.rx_packets++;
+ net->stats.rx_bytes += packet->total_data_buflen;
+@@ -824,8 +823,6 @@ static int netvsc_probe(struct hv_device *dev,
+ nvdev = hv_get_drvdata(dev);
+ netif_set_real_num_tx_queues(net, nvdev->num_chn);
+ netif_set_real_num_rx_queues(net, nvdev->num_chn);
+- dev_info(&dev->device, "real num tx,rx queues:%u, %u\n",
+- net->real_num_tx_queues, net->real_num_rx_queues);
+
+ ret = register_netdev(net);
+ if (ret != 0) {
+--
+2.4.3
+
--- /dev/null
+From 4c06034001e20ff9f6e2a1a3dfa155bf3f31440c Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Sat, 8 Mar 2014 19:23:13 -0800
+Subject: [PATCH 05/25] Drivers: net: hyperv: Enable scatter gather I/O
+
+Cleanup the code and enable scatter gather I/O.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/netvsc_drv.c | 153 ++++++++++++++++++++++++++++++----------
+ 1 file changed, 114 insertions(+), 39 deletions(-)
+
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 8e3a0b00099b..72961741be54 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -140,22 +140,124 @@ static void netvsc_xmit_completion(void *context)
+ dev_kfree_skb_any(skb);
+ }
+
++static u32 fill_pg_buf(struct page *page, u32 offset, u32 len,
++ struct hv_page_buffer *pb)
++{
++ int j = 0;
++
++ /* Deal with compund pages by ignoring unused part
++ * of the page.
++ */
++ page += (offset >> PAGE_SHIFT);
++ offset &= ~PAGE_MASK;
++
++ while (len > 0) {
++ unsigned long bytes;
++
++ bytes = PAGE_SIZE - offset;
++ if (bytes > len)
++ bytes = len;
++ pb[j].pfn = page_to_pfn(page);
++ pb[j].offset = offset;
++ pb[j].len = bytes;
++
++ offset += bytes;
++ len -= bytes;
++
++ if (offset == PAGE_SIZE && len) {
++ page++;
++ offset = 0;
++ j++;
++ }
++ }
++
++ return j + 1;
++}
++
++static void init_page_array(void *hdr, u32 len, struct sk_buff *skb,
++ struct hv_page_buffer *pb)
++{
++ u32 slots_used = 0;
++ char *data = skb->data;
++ int frags = skb_shinfo(skb)->nr_frags;
++ int i;
++
++ /* The packet is laid out thus:
++ * 1. hdr
++ * 2. skb linear data
++ * 3. skb fragment data
++ */
++ if (hdr != NULL)
++ slots_used += fill_pg_buf(virt_to_page(hdr),
++ offset_in_page(hdr),
++ len, &pb[slots_used]);
++
++ slots_used += fill_pg_buf(virt_to_page(data),
++ offset_in_page(data),
++ skb_headlen(skb), &pb[slots_used]);
++
++ for (i = 0; i < frags; i++) {
++ skb_frag_t *frag = skb_shinfo(skb)->frags + i;
++
++ slots_used += fill_pg_buf(skb_frag_page(frag),
++ frag->page_offset,
++ skb_frag_size(frag), &pb[slots_used]);
++ }
++}
++
++static int count_skb_frag_slots(struct sk_buff *skb)
++{
++ int i, frags = skb_shinfo(skb)->nr_frags;
++ int pages = 0;
++
++ for (i = 0; i < frags; i++) {
++ skb_frag_t *frag = skb_shinfo(skb)->frags + i;
++ unsigned long size = skb_frag_size(frag);
++ unsigned long offset = frag->page_offset;
++
++ /* Skip unused frames from start of page */
++ offset &= ~PAGE_MASK;
++ pages += PFN_UP(offset + size);
++ }
++ return pages;
++}
++
++static int netvsc_get_slots(struct sk_buff *skb)
++{
++ char *data = skb->data;
++ unsigned int offset = offset_in_page(data);
++ unsigned int len = skb_headlen(skb);
++ int slots;
++ int frag_slots;
++
++ slots = DIV_ROUND_UP(offset + len, PAGE_SIZE);
++ frag_slots = count_skb_frag_slots(skb);
++ return slots + frag_slots;
++}
++
+ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ {
+ struct net_device_context *net_device_ctx = netdev_priv(net);
+ struct hv_netvsc_packet *packet;
+ int ret;
+- unsigned int i, num_pages, npg_data;
++ unsigned int num_data_pages;
+ u32 skb_length = skb->len;
+
+- /* Add multipages for skb->data and additional 2 for RNDIS */
+- npg_data = (((unsigned long)skb->data + skb_headlen(skb) - 1)
+- >> PAGE_SHIFT) - ((unsigned long)skb->data >> PAGE_SHIFT) + 1;
+- num_pages = skb_shinfo(skb)->nr_frags + npg_data + 2;
++ /* We will atmost need two pages to describe the rndis
++ * header. We can only transmit MAX_PAGE_BUFFER_COUNT number
++ * of pages in a single packet.
++ */
++ num_data_pages = netvsc_get_slots(skb) + 2;
++ if (num_data_pages > MAX_PAGE_BUFFER_COUNT) {
++ netdev_err(net, "Packet too big: %u\n", skb->len);
++ dev_kfree_skb(skb);
++ net->stats.tx_dropped++;
++ return NETDEV_TX_OK;
++ }
+
+ /* Allocate a netvsc packet based on # of frags. */
+ packet = kzalloc(sizeof(struct hv_netvsc_packet) +
+- (num_pages * sizeof(struct hv_page_buffer)) +
++ (num_data_pages * sizeof(struct hv_page_buffer)) +
+ sizeof(struct rndis_message) +
+ NDIS_VLAN_PPI_SIZE, GFP_ATOMIC);
+ if (!packet) {
+@@ -170,44 +272,17 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ packet->vlan_tci = skb->vlan_tci;
+
+ packet->extension = (void *)(unsigned long)packet +
+- sizeof(struct hv_netvsc_packet) +
+- (num_pages * sizeof(struct hv_page_buffer));
++ sizeof(struct hv_netvsc_packet) +
++ (num_data_pages * sizeof(struct hv_page_buffer));
+
+ /* If the rndis msg goes beyond 1 page, we will add 1 later */
+- packet->page_buf_cnt = num_pages - 1;
++ packet->page_buf_cnt = num_data_pages - 1;
+
+ /* Initialize it from the skb */
+ packet->total_data_buflen = skb->len;
+
+ /* Start filling in the page buffers starting after RNDIS buffer. */
+- packet->page_buf[1].pfn = virt_to_phys(skb->data) >> PAGE_SHIFT;
+- packet->page_buf[1].offset
+- = (unsigned long)skb->data & (PAGE_SIZE - 1);
+- if (npg_data == 1)
+- packet->page_buf[1].len = skb_headlen(skb);
+- else
+- packet->page_buf[1].len = PAGE_SIZE
+- - packet->page_buf[1].offset;
+-
+- for (i = 2; i <= npg_data; i++) {
+- packet->page_buf[i].pfn = virt_to_phys(skb->data
+- + PAGE_SIZE * (i-1)) >> PAGE_SHIFT;
+- packet->page_buf[i].offset = 0;
+- packet->page_buf[i].len = PAGE_SIZE;
+- }
+- if (npg_data > 1)
+- packet->page_buf[npg_data].len = (((unsigned long)skb->data
+- + skb_headlen(skb) - 1) & (PAGE_SIZE - 1)) + 1;
+-
+- /* Additional fragments are after SKB data */
+- for (i = 0; i < skb_shinfo(skb)->nr_frags; i++) {
+- const skb_frag_t *f = &skb_shinfo(skb)->frags[i];
+-
+- packet->page_buf[i+npg_data+1].pfn =
+- page_to_pfn(skb_frag_page(f));
+- packet->page_buf[i+npg_data+1].offset = f->page_offset;
+- packet->page_buf[i+npg_data+1].len = skb_frag_size(f);
+- }
++ init_page_array(NULL, 0, skb, &packet->page_buf[1]);
+
+ /* Set the completion routine */
+ packet->completion.send.send_completion = netvsc_xmit_completion;
+@@ -454,8 +529,8 @@ static int netvsc_probe(struct hv_device *dev,
+ net->netdev_ops = &device_ops;
+
+ /* TODO: Add GSO and Checksum offload */
+- net->hw_features = 0;
+- net->features = NETIF_F_HW_VLAN_CTAG_TX;
++ net->hw_features = NETIF_F_SG;
++ net->features = NETIF_F_HW_VLAN_CTAG_TX | NETIF_F_SG;
+
+ SET_ETHTOOL_OPS(net, ðtool_ops);
+ SET_NETDEV_DEV(net, &dev->device);
+--
+2.4.3
+
--- /dev/null
+From d972eb71fb95660fe74616901b55b0d7a336daed Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Sat, 8 Mar 2014 19:23:14 -0800
+Subject: [PATCH 06/25] Drivers: net: hyperv: Cleanup the send path
+
+In preparation for enabling offloads, cleanup the send path.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 7 +---
+ drivers/net/hyperv/netvsc_drv.c | 88 +++++++++++++++++++++++++++++++--------
+ drivers/net/hyperv/rndis_filter.c | 66 -----------------------------
+ 3 files changed, 71 insertions(+), 90 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index 39fc230f5c20..694bf7cada90 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -73,7 +73,7 @@ struct hv_netvsc_packet {
+ } completion;
+
+ /* This points to the memory after page_buf */
+- void *extension;
++ struct rndis_message *rndis_msg;
+
+ u32 total_data_buflen;
+ /* Points to the send/receive buffer where the ethernet frame is */
+@@ -126,11 +126,6 @@ void rndis_filter_device_remove(struct hv_device *dev);
+ int rndis_filter_receive(struct hv_device *dev,
+ struct hv_netvsc_packet *pkt);
+
+-
+-
+-int rndis_filter_send(struct hv_device *dev,
+- struct hv_netvsc_packet *pkt);
+-
+ int rndis_filter_set_packet_filter(struct rndis_device *dev, u32 new_filter);
+ int rndis_filter_set_device_mac(struct hv_device *hdev, char *mac);
+
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 72961741be54..87293a15e470 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -128,6 +128,27 @@ static int netvsc_close(struct net_device *net)
+ return ret;
+ }
+
++static void *init_ppi_data(struct rndis_message *msg, u32 ppi_size,
++ int pkt_type)
++{
++ struct rndis_packet *rndis_pkt;
++ struct rndis_per_packet_info *ppi;
++
++ rndis_pkt = &msg->msg.pkt;
++ rndis_pkt->data_offset += ppi_size;
++
++ ppi = (struct rndis_per_packet_info *)((void *)rndis_pkt +
++ rndis_pkt->per_pkt_info_offset + rndis_pkt->per_pkt_info_len);
++
++ ppi->size = ppi_size;
++ ppi->type = pkt_type;
++ ppi->ppi_offset = sizeof(struct rndis_per_packet_info);
++
++ rndis_pkt->per_pkt_info_len += ppi_size;
++
++ return ppi;
++}
++
+ static void netvsc_xmit_completion(void *context)
+ {
+ struct hv_netvsc_packet *packet = (struct hv_netvsc_packet *)context;
+@@ -174,8 +195,8 @@ static u32 fill_pg_buf(struct page *page, u32 offset, u32 len,
+ return j + 1;
+ }
+
+-static void init_page_array(void *hdr, u32 len, struct sk_buff *skb,
+- struct hv_page_buffer *pb)
++static u32 init_page_array(void *hdr, u32 len, struct sk_buff *skb,
++ struct hv_page_buffer *pb)
+ {
+ u32 slots_used = 0;
+ char *data = skb->data;
+@@ -203,6 +224,7 @@ static void init_page_array(void *hdr, u32 len, struct sk_buff *skb,
+ frag->page_offset,
+ skb_frag_size(frag), &pb[slots_used]);
+ }
++ return slots_used;
+ }
+
+ static int count_skb_frag_slots(struct sk_buff *skb)
+@@ -240,15 +262,20 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ struct net_device_context *net_device_ctx = netdev_priv(net);
+ struct hv_netvsc_packet *packet;
+ int ret;
+- unsigned int num_data_pages;
+ u32 skb_length = skb->len;
++ unsigned int num_data_pgs;
++ struct rndis_message *rndis_msg;
++ struct rndis_packet *rndis_pkt;
++ u32 rndis_msg_size;
++ bool isvlan;
++ struct rndis_per_packet_info *ppi;
+
+ /* We will atmost need two pages to describe the rndis
+ * header. We can only transmit MAX_PAGE_BUFFER_COUNT number
+ * of pages in a single packet.
+ */
+- num_data_pages = netvsc_get_slots(skb) + 2;
+- if (num_data_pages > MAX_PAGE_BUFFER_COUNT) {
++ num_data_pgs = netvsc_get_slots(skb) + 2;
++ if (num_data_pgs > MAX_PAGE_BUFFER_COUNT) {
+ netdev_err(net, "Packet too big: %u\n", skb->len);
+ dev_kfree_skb(skb);
+ net->stats.tx_dropped++;
+@@ -257,7 +284,7 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+
+ /* Allocate a netvsc packet based on # of frags. */
+ packet = kzalloc(sizeof(struct hv_netvsc_packet) +
+- (num_data_pages * sizeof(struct hv_page_buffer)) +
++ (num_data_pgs * sizeof(struct hv_page_buffer)) +
+ sizeof(struct rndis_message) +
+ NDIS_VLAN_PPI_SIZE, GFP_ATOMIC);
+ if (!packet) {
+@@ -271,26 +298,51 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+
+ packet->vlan_tci = skb->vlan_tci;
+
+- packet->extension = (void *)(unsigned long)packet +
+- sizeof(struct hv_netvsc_packet) +
+- (num_data_pages * sizeof(struct hv_page_buffer));
+-
+- /* If the rndis msg goes beyond 1 page, we will add 1 later */
+- packet->page_buf_cnt = num_data_pages - 1;
+-
+- /* Initialize it from the skb */
++ packet->is_data_pkt = true;
+ packet->total_data_buflen = skb->len;
+
+- /* Start filling in the page buffers starting after RNDIS buffer. */
+- init_page_array(NULL, 0, skb, &packet->page_buf[1]);
++ packet->rndis_msg = (struct rndis_message *)((unsigned long)packet +
++ sizeof(struct hv_netvsc_packet) +
++ (num_data_pgs * sizeof(struct hv_page_buffer)));
+
+ /* Set the completion routine */
+ packet->completion.send.send_completion = netvsc_xmit_completion;
+ packet->completion.send.send_completion_ctx = packet;
+ packet->completion.send.send_completion_tid = (unsigned long)skb;
+
+- ret = rndis_filter_send(net_device_ctx->device_ctx,
+- packet);
++ isvlan = packet->vlan_tci & VLAN_TAG_PRESENT;
++
++ /* Add the rndis header */
++ rndis_msg = packet->rndis_msg;
++ rndis_msg->ndis_msg_type = RNDIS_MSG_PACKET;
++ rndis_msg->msg_len = packet->total_data_buflen;
++ rndis_pkt = &rndis_msg->msg.pkt;
++ rndis_pkt->data_offset = sizeof(struct rndis_packet);
++ rndis_pkt->data_len = packet->total_data_buflen;
++ rndis_pkt->per_pkt_info_offset = sizeof(struct rndis_packet);
++
++ rndis_msg_size = RNDIS_MESSAGE_SIZE(struct rndis_packet);
++
++ if (isvlan) {
++ struct ndis_pkt_8021q_info *vlan;
++
++ rndis_msg_size += NDIS_VLAN_PPI_SIZE;
++ ppi = init_ppi_data(rndis_msg, NDIS_VLAN_PPI_SIZE,
++ IEEE_8021Q_INFO);
++ vlan = (struct ndis_pkt_8021q_info *)((void *)ppi +
++ ppi->ppi_offset);
++ vlan->vlanid = packet->vlan_tci & VLAN_VID_MASK;
++ vlan->pri = (packet->vlan_tci & VLAN_PRIO_MASK) >>
++ VLAN_PRIO_SHIFT;
++ }
++
++ /* Start filling in the page buffers with the rndis hdr */
++ rndis_msg->msg_len += rndis_msg_size;
++ packet->page_buf_cnt = init_page_array(rndis_msg, rndis_msg_size,
++ skb, &packet->page_buf[0]);
++
++ ret = netvsc_send(net_device_ctx->device_ctx, packet);
++
+ if (ret == 0) {
+ net->stats.tx_bytes += skb_length;
+ net->stats.tx_packets++;
+diff --git a/drivers/net/hyperv/rndis_filter.c b/drivers/net/hyperv/rndis_filter.c
+index 6a9f6021f09c..dcbf144ea7da 100644
+--- a/drivers/net/hyperv/rndis_filter.c
++++ b/drivers/net/hyperv/rndis_filter.c
+@@ -910,69 +910,3 @@ int rndis_filter_close(struct hv_device *dev)
+
+ return rndis_filter_close_device(nvdev->extension);
+ }
+-
+-int rndis_filter_send(struct hv_device *dev,
+- struct hv_netvsc_packet *pkt)
+-{
+- struct rndis_message *rndis_msg;
+- struct rndis_packet *rndis_pkt;
+- u32 rndis_msg_size;
+- bool isvlan = pkt->vlan_tci & VLAN_TAG_PRESENT;
+-
+- /* Add the rndis header */
+- rndis_msg = (struct rndis_message *)pkt->extension;
+-
+- rndis_msg_size = RNDIS_MESSAGE_SIZE(struct rndis_packet);
+- if (isvlan)
+- rndis_msg_size += NDIS_VLAN_PPI_SIZE;
+-
+- rndis_msg->ndis_msg_type = RNDIS_MSG_PACKET;
+- rndis_msg->msg_len = pkt->total_data_buflen +
+- rndis_msg_size;
+-
+- rndis_pkt = &rndis_msg->msg.pkt;
+- rndis_pkt->data_offset = sizeof(struct rndis_packet);
+- if (isvlan)
+- rndis_pkt->data_offset += NDIS_VLAN_PPI_SIZE;
+- rndis_pkt->data_len = pkt->total_data_buflen;
+-
+- if (isvlan) {
+- struct rndis_per_packet_info *ppi;
+- struct ndis_pkt_8021q_info *vlan;
+-
+- rndis_pkt->per_pkt_info_offset = sizeof(struct rndis_packet);
+- rndis_pkt->per_pkt_info_len = NDIS_VLAN_PPI_SIZE;
+-
+- ppi = (struct rndis_per_packet_info *)((ulong)rndis_pkt +
+- rndis_pkt->per_pkt_info_offset);
+- ppi->size = NDIS_VLAN_PPI_SIZE;
+- ppi->type = IEEE_8021Q_INFO;
+- ppi->ppi_offset = sizeof(struct rndis_per_packet_info);
+-
+- vlan = (struct ndis_pkt_8021q_info *)((ulong)ppi +
+- ppi->ppi_offset);
+- vlan->vlanid = pkt->vlan_tci & VLAN_VID_MASK;
+- vlan->pri = (pkt->vlan_tci & VLAN_PRIO_MASK) >> VLAN_PRIO_SHIFT;
+- }
+-
+- pkt->is_data_pkt = true;
+- pkt->page_buf[0].pfn = virt_to_phys(rndis_msg) >> PAGE_SHIFT;
+- pkt->page_buf[0].offset =
+- (unsigned long)rndis_msg & (PAGE_SIZE-1);
+- pkt->page_buf[0].len = rndis_msg_size;
+-
+- /* Add one page_buf if the rndis msg goes beyond page boundary */
+- if (pkt->page_buf[0].offset + rndis_msg_size > PAGE_SIZE) {
+- int i;
+- for (i = pkt->page_buf_cnt; i > 1; i--)
+- pkt->page_buf[i] = pkt->page_buf[i-1];
+- pkt->page_buf_cnt++;
+- pkt->page_buf[0].len = PAGE_SIZE - pkt->page_buf[0].offset;
+- pkt->page_buf[1].pfn = virt_to_phys((void *)((ulong)
+- rndis_msg + pkt->page_buf[0].len)) >> PAGE_SHIFT;
+- pkt->page_buf[1].offset = 0;
+- pkt->page_buf[1].len = rndis_msg_size - pkt->page_buf[0].len;
+- }
+-
+- return netvsc_send(dev, pkt);
+-}
+--
+2.4.3
+
--- /dev/null
+From 7ad24ea4bf620a32631d7b3069c3e30c078b0c3e Mon Sep 17 00:00:00 2001
+From: Wilfried Klaebe <w-lkml@lebenslange-mailadresse.de>
+Date: Sun, 11 May 2014 00:12:32 +0000
+Subject: [PATCH 06/11] net: get rid of SET_ETHTOOL_OPS
+
+net: get rid of SET_ETHTOOL_OPS
+
+Dave Miller mentioned he'd like to see SET_ETHTOOL_OPS gone.
+This does that.
+
+Mostly done via coccinelle script:
+@@
+struct ethtool_ops *ops;
+struct net_device *dev;
+@@
+- SET_ETHTOOL_OPS(dev, ops);
++ dev->ethtool_ops = ops;
+
+Compile tested only, but I'd seriously wonder if this broke anything.
+
+Suggested-by: Dave Miller <davem@davemloft.net>
+Signed-off-by: Wilfried Klaebe <w-lkml@lebenslange-mailadresse.de>
+Acked-by: Felipe Balbi <balbi@ti.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/netvsc_drv.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 1de3ef5dd5d2..2e967a7bdb33 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -810,7 +810,7 @@ static int netvsc_probe(struct hv_device *dev,
+ net->features = NETIF_F_HW_VLAN_CTAG_TX | NETIF_F_SG | NETIF_F_RXCSUM |
+ NETIF_F_IP_CSUM | NETIF_F_TSO;
+
+- SET_ETHTOOL_OPS(net, ðtool_ops);
++ net->ethtool_ops = ðtool_ops;
+ SET_NETDEV_DEV(net, &dev->device);
+
+ /* Notify the netvsc driver of the new device */
+--
+2.4.3
+
--- /dev/null
+From 6b15b5f37e976a5f3840c7ea59560e10c6251250 Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Sat, 8 Mar 2014 19:23:15 -0800
+Subject: [PATCH 07/25] Drivers: net: hyperv: Enable offloads on the host
+
+Prior to enabling guest side offloads, enable the offloads on the host.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 55 +++++++++++++++++++++++++++
+ drivers/net/hyperv/rndis_filter.c | 80 +++++++++++++++++++++++++++++++++++++++
+ 2 files changed, 135 insertions(+)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index 694bf7cada90..8bc4e766589b 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -721,6 +721,61 @@ struct ndis_pkt_8021q_info {
+ };
+ };
+
++struct ndis_oject_header {
++ u8 type;
++ u8 revision;
++ u16 size;
++};
++
++#define NDIS_OBJECT_TYPE_DEFAULT 0x80
++#define NDIS_OFFLOAD_PARAMETERS_REVISION_3 3
++#define NDIS_OFFLOAD_PARAMETERS_NO_CHANGE 0
++#define NDIS_OFFLOAD_PARAMETERS_LSOV2_DISABLED 1
++#define NDIS_OFFLOAD_PARAMETERS_LSOV2_ENABLED 2
++#define NDIS_OFFLOAD_PARAMETERS_LSOV1_ENABLED 2
++#define NDIS_OFFLOAD_PARAMETERS_RSC_DISABLED 1
++#define NDIS_OFFLOAD_PARAMETERS_RSC_ENABLED 2
++#define NDIS_OFFLOAD_PARAMETERS_TX_RX_DISABLED 1
++#define NDIS_OFFLOAD_PARAMETERS_TX_ENABLED_RX_DISABLED 2
++#define NDIS_OFFLOAD_PARAMETERS_RX_ENABLED_TX_DISABLED 3
++#define NDIS_OFFLOAD_PARAMETERS_TX_RX_ENABLED 4
++
++/*
++ * New offload OIDs for NDIS 6
++ */
++#define OID_TCP_OFFLOAD_CURRENT_CONFIG 0xFC01020B /* query only */
++#define OID_TCP_OFFLOAD_PARAMETERS 0xFC01020C /* set only */
++#define OID_TCP_OFFLOAD_HARDWARE_CAPABILITIES 0xFC01020D/* query only */
++#define OID_TCP_CONNECTION_OFFLOAD_CURRENT_CONFIG 0xFC01020E /* query only */
++#define OID_TCP_CONNECTION_OFFLOAD_HARDWARE_CAPABILITIES 0xFC01020F /* query */
++#define OID_OFFLOAD_ENCAPSULATION 0x0101010A /* set/query */
++
++struct ndis_offload_params {
++ struct ndis_oject_header header;
++ u8 ip_v4_csum;
++ u8 tcp_ip_v4_csum;
++ u8 udp_ip_v4_csum;
++ u8 tcp_ip_v6_csum;
++ u8 udp_ip_v6_csum;
++ u8 lso_v1;
++ u8 ip_sec_v1;
++ u8 lso_v2_ipv4;
++ u8 lso_v2_ipv6;
++ u8 tcp_connection_ip_v4;
++ u8 tcp_connection_ip_v6;
++ u32 flags;
++ u8 ip_sec_v2;
++ u8 ip_sec_v2_ip_v4;
++ struct {
++ u8 rsc_ip_v4;
++ u8 rsc_ip_v6;
++ };
++ struct {
++ u8 encapsulated_packet_task_offload;
++ u8 encapsulation_types;
++ };
++};
++
+ #define NDIS_VLAN_PPI_SIZE (sizeof(struct rndis_per_packet_info) + \
+ sizeof(struct ndis_pkt_8021q_info))
+
+diff --git a/drivers/net/hyperv/rndis_filter.c b/drivers/net/hyperv/rndis_filter.c
+index dcbf144ea7da..9b02f21097a7 100644
+--- a/drivers/net/hyperv/rndis_filter.c
++++ b/drivers/net/hyperv/rndis_filter.c
+@@ -627,6 +627,61 @@ cleanup:
+ return ret;
+ }
+
++int rndis_filter_set_offload_params(struct hv_device *hdev,
++ struct ndis_offload_params *req_offloads)
++{
++ struct netvsc_device *nvdev = hv_get_drvdata(hdev);
++ struct rndis_device *rdev = nvdev->extension;
++ struct net_device *ndev = nvdev->ndev;
++ struct rndis_request *request;
++ struct rndis_set_request *set;
++ struct ndis_offload_params *offload_params;
++ struct rndis_set_complete *set_complete;
++ u32 extlen = sizeof(struct ndis_offload_params);
++ int ret, t;
++
++ request = get_rndis_request(rdev, RNDIS_MSG_SET,
++ RNDIS_MESSAGE_SIZE(struct rndis_set_request) + extlen);
++ if (!request)
++ return -ENOMEM;
++
++ set = &request->request_msg.msg.set_req;
++ set->oid = OID_TCP_OFFLOAD_PARAMETERS;
++ set->info_buflen = extlen;
++ set->info_buf_offset = sizeof(struct rndis_set_request);
++ set->dev_vc_handle = 0;
++
++ offload_params = (struct ndis_offload_params *)((ulong)set +
++ set->info_buf_offset);
++ *offload_params = *req_offloads;
++ offload_params->header.type = NDIS_OBJECT_TYPE_DEFAULT;
++ offload_params->header.revision = NDIS_OFFLOAD_PARAMETERS_REVISION_3;
++ offload_params->header.size = extlen;
++
++ ret = rndis_filter_send_request(rdev, request);
++ if (ret != 0)
++ goto cleanup;
++
++ t = wait_for_completion_timeout(&request->wait_event, 5*HZ);
++ if (t == 0) {
++ netdev_err(ndev, "timeout before we got aOFFLOAD set response...\n");
++ /* can't put_rndis_request, since we may still receive a
++ * send-completion.
++ */
++ return -EBUSY;
++ } else {
++ set_complete = &request->response_msg.msg.set_complete;
++ if (set_complete->status != RNDIS_STATUS_SUCCESS) {
++ netdev_err(ndev, "Fail to set MAC on host side:0x%x\n",
++ set_complete->status);
++ ret = -EINVAL;
++ }
++ }
++
++cleanup:
++ put_rndis_request(rdev, request);
++ return ret;
++}
+
+ static int rndis_filter_query_device_link_status(struct rndis_device *dev)
+ {
+@@ -826,6 +881,7 @@ int rndis_filter_device_add(struct hv_device *dev,
+ struct netvsc_device *net_device;
+ struct rndis_device *rndis_device;
+ struct netvsc_device_info *device_info = additional_info;
++ struct ndis_offload_params offloads;
+
+ rndis_device = get_rndis_device();
+ if (!rndis_device)
+@@ -865,6 +921,26 @@ int rndis_filter_device_add(struct hv_device *dev,
+
+ memcpy(device_info->mac_adr, rndis_device->hw_mac_adr, ETH_ALEN);
+
++ /* Turn on the offloads; the host supports all of the relevant
++ * offloads.
++ */
++ memset(&offloads, 0, sizeof(struct ndis_offload_params));
++ /* A value of zero means "no change"; now turn on what we
++ * want.
++ */
++ offloads.ip_v4_csum = NDIS_OFFLOAD_PARAMETERS_TX_RX_ENABLED;
++ offloads.tcp_ip_v4_csum = NDIS_OFFLOAD_PARAMETERS_TX_RX_ENABLED;
++ offloads.udp_ip_v4_csum = NDIS_OFFLOAD_PARAMETERS_TX_RX_ENABLED;
++ offloads.tcp_ip_v6_csum = NDIS_OFFLOAD_PARAMETERS_TX_RX_ENABLED;
++ offloads.udp_ip_v6_csum = NDIS_OFFLOAD_PARAMETERS_TX_RX_ENABLED;
++ offloads.lso_v2_ipv4 = NDIS_OFFLOAD_PARAMETERS_LSOV2_ENABLED;
++
++
++ ret = rndis_filter_set_offload_params(dev, &offloads);
++ if (ret)
++ goto err_dev_remv;
++
++
+ rndis_filter_query_device_link_status(rndis_device);
+
+ device_info->link_state = rndis_device->link_state;
+@@ -874,6 +950,10 @@ int rndis_filter_device_add(struct hv_device *dev,
+ device_info->link_state ? "down" : "up");
+
+ return ret;
++
++err_dev_remv:
++ rndis_filter_device_remove(dev);
++ return ret;
+ }
+
+ void rndis_filter_device_remove(struct hv_device *dev)
+--
+2.4.3
+
--- /dev/null
+From 307f099520b66504cf6c5638f3f404c48b9fb45b Mon Sep 17 00:00:00 2001
+From: Haiyang Zhang <haiyangz@microsoft.com>
+Date: Wed, 21 May 2014 12:55:39 -0700
+Subject: [PATCH 07/11] hyperv: Add hash value into RNDIS Per-packet info
+
+It passes the hash value as the RNDIS Per-packet info to the Hyper-V host,
+so that the send completion notices can be spread across multiple channels.
+MS-TFS: 140273
+
+Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 4 ++++
+ drivers/net/hyperv/netvsc_drv.c | 18 ++++++++++++++----
+ 2 files changed, 18 insertions(+), 4 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index 4b7df5a5c966..6cc37c15e0bf 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -791,6 +791,7 @@ enum ndis_per_pkt_info_type {
+ IEEE_8021Q_INFO,
+ ORIGINAL_PKTINFO,
+ PACKET_CANCEL_ID,
++ NBL_HASH_VALUE = PACKET_CANCEL_ID,
+ ORIGINAL_NET_BUFLIST,
+ CACHED_NET_BUFLIST,
+ SHORT_PKT_PADINFO,
+@@ -937,6 +938,9 @@ struct ndis_tcp_lso_info {
+ #define NDIS_LSO_PPI_SIZE (sizeof(struct rndis_per_packet_info) + \
+ sizeof(struct ndis_tcp_lso_info))
+
++#define NDIS_HASH_PPI_SIZE (sizeof(struct rndis_per_packet_info) + \
++ sizeof(u32))
++
+ /* Format of Information buffer passed in a SetRequest for the OID */
+ /* OID_GEN_RNDIS_CONFIG_PARAMETER. */
+ struct rndis_config_parameter_info {
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 2e967a7bdb33..4fd71b75e666 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -224,9 +224,11 @@ static u16 netvsc_select_queue(struct net_device *ndev, struct sk_buff *skb,
+ if (nvsc_dev == NULL || ndev->real_num_tx_queues <= 1)
+ return 0;
+
+- if (netvsc_set_hash(&hash, skb))
++ if (netvsc_set_hash(&hash, skb)) {
+ q_idx = nvsc_dev->send_table[hash % VRSS_SEND_TAB_SIZE] %
+ ndev->real_num_tx_queues;
++ skb_set_hash(skb, hash, PKT_HASH_TYPE_L3);
++ }
+
+ return q_idx;
+ }
+@@ -384,6 +386,7 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ struct ndis_tcp_lso_info *lso_info;
+ int hdr_offset;
+ u32 net_trans_info;
++ u32 hash;
+
+
+ /* We will atmost need two pages to describe the rndis
+@@ -402,9 +405,8 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ packet = kzalloc(sizeof(struct hv_netvsc_packet) +
+ (num_data_pgs * sizeof(struct hv_page_buffer)) +
+ sizeof(struct rndis_message) +
+- NDIS_VLAN_PPI_SIZE +
+- NDIS_CSUM_PPI_SIZE +
+- NDIS_LSO_PPI_SIZE, GFP_ATOMIC);
++ NDIS_VLAN_PPI_SIZE + NDIS_CSUM_PPI_SIZE +
++ NDIS_LSO_PPI_SIZE + NDIS_HASH_PPI_SIZE, GFP_ATOMIC);
+ if (!packet) {
+ /* out of memory, drop packet */
+ netdev_err(net, "unable to allocate hv_netvsc_packet\n");
+@@ -443,6 +445,14 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+
+ rndis_msg_size = RNDIS_MESSAGE_SIZE(struct rndis_packet);
+
++ hash = skb_get_hash_raw(skb);
++ if (hash != 0 && net->real_num_tx_queues > 1) {
++ rndis_msg_size += NDIS_HASH_PPI_SIZE;
++ ppi = init_ppi_data(rndis_msg, NDIS_HASH_PPI_SIZE,
++ NBL_HASH_VALUE);
++ *(u32 *)((void *)ppi + ppi->ppi_offset) = hash;
++ }
++
+ if (isvlan) {
+ struct ndis_pkt_8021q_info *vlan;
+
+--
+2.4.3
+
--- /dev/null
+From 59e0c70c618668522a9431686f7e3a69ef396dff Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Sat, 8 Mar 2014 19:23:16 -0800
+Subject: [PATCH 08/25] Drivers: net: hyperv: Enable receive side IP checksum
+ offload
+
+Enable receive side checksum offload.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 33 ++++++++++++++++++++++++++++++++-
+ drivers/net/hyperv/netvsc_drv.c | 19 +++++++++++++++----
+ drivers/net/hyperv/rndis_filter.c | 4 +++-
+ 3 files changed, 50 insertions(+), 6 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index 8bc4e766589b..faeb74623fbd 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -30,6 +30,7 @@
+
+ /* Fwd declaration */
+ struct hv_netvsc_packet;
++struct ndis_tcp_ip_checksum_info;
+
+ /* Represent the xfer page packet which contains 1 or more netvsc packet */
+ struct xferpage_packet {
+@@ -117,7 +118,8 @@ int netvsc_send(struct hv_device *device,
+ void netvsc_linkstatus_callback(struct hv_device *device_obj,
+ unsigned int status);
+ int netvsc_recv_callback(struct hv_device *device_obj,
+- struct hv_netvsc_packet *packet);
++ struct hv_netvsc_packet *packet,
++ struct ndis_tcp_ip_checksum_info *csum_info);
+ int rndis_filter_open(struct hv_device *dev);
+ int rndis_filter_close(struct hv_device *dev);
+ int rndis_filter_device_add(struct hv_device *dev,
+@@ -776,9 +778,38 @@ struct ndis_offload_params {
+ };
+ };
+
++struct ndis_tcp_ip_checksum_info {
++ union {
++ struct {
++ u32 is_ipv4:1;
++ u32 is_ipv6:1;
++ u32 tcp_checksum:1;
++ u32 udp_checksum:1;
++ u32 ip_header_checksum:1;
++ u32 reserved:11;
++ u32 tcp_header_offset:10;
++ } transmit;
++ struct {
++ u32 tcp_checksum_failed:1;
++ u32 udp_checksum_failed:1;
++ u32 ip_checksum_failed:1;
++ u32 tcp_checksum_succeeded:1;
++ u32 udp_checksum_succeeded:1;
++ u32 ip_checksum_succeeded:1;
++ u32 loopback:1;
++ u32 tcp_checksum_value_invalid:1;
++ u32 ip_checksum_value_invalid:1;
++ } receive;
++ u32 value;
++ };
++};
++
+ #define NDIS_VLAN_PPI_SIZE (sizeof(struct rndis_per_packet_info) + \
+ sizeof(struct ndis_pkt_8021q_info))
+
++#define NDIS_CSUM_PPI_SIZE (sizeof(struct rndis_per_packet_info) + \
++ sizeof(struct ndis_tcp_ip_checksum_info))
++
+ /* Format of Information buffer passed in a SetRequest for the OID */
+ /* OID_GEN_RNDIS_CONFIG_PARAMETER. */
+ struct rndis_config_parameter_info {
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 87293a15e470..7438360b7a02 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -392,7 +392,8 @@ void netvsc_linkstatus_callback(struct hv_device *device_obj,
+ * "wire" on the specified device.
+ */
+ int netvsc_recv_callback(struct hv_device *device_obj,
+- struct hv_netvsc_packet *packet)
++ struct hv_netvsc_packet *packet,
++ struct ndis_tcp_ip_checksum_info *csum_info)
+ {
+ struct net_device *net;
+ struct sk_buff *skb;
+@@ -419,7 +420,17 @@ int netvsc_recv_callback(struct hv_device *device_obj,
+ packet->total_data_buflen);
+
+ skb->protocol = eth_type_trans(skb, net);
+- skb->ip_summed = CHECKSUM_NONE;
++ if (csum_info) {
++ /* We only look at the IP checksum here.
++ * Should we be dropping the packet if checksum
++ * failed? How do we deal with other checksums - TCP/UDP?
++ */
++ if (csum_info->receive.ip_checksum_succeeded)
++ skb->ip_summed = CHECKSUM_UNNECESSARY;
++ else
++ skb->ip_summed = CHECKSUM_NONE;
++ }
++
+ if (packet->vlan_tci & VLAN_TAG_PRESENT)
+ __vlan_hwaccel_put_tag(skb, htons(ETH_P_8021Q),
+ packet->vlan_tci);
+@@ -581,8 +592,8 @@ static int netvsc_probe(struct hv_device *dev,
+ net->netdev_ops = &device_ops;
+
+ /* TODO: Add GSO and Checksum offload */
+- net->hw_features = NETIF_F_SG;
+- net->features = NETIF_F_HW_VLAN_CTAG_TX | NETIF_F_SG;
++ net->hw_features = NETIF_F_RXCSUM | NETIF_F_SG;
++ net->features = NETIF_F_HW_VLAN_CTAG_TX | NETIF_F_SG | NETIF_F_RXCSUM;
+
+ SET_ETHTOOL_OPS(net, ðtool_ops);
+ SET_NETDEV_DEV(net, &dev->device);
+diff --git a/drivers/net/hyperv/rndis_filter.c b/drivers/net/hyperv/rndis_filter.c
+index 9b02f21097a7..4a37e3db9e32 100644
+--- a/drivers/net/hyperv/rndis_filter.c
++++ b/drivers/net/hyperv/rndis_filter.c
+@@ -370,6 +370,7 @@ static void rndis_filter_receive_data(struct rndis_device *dev,
+ struct rndis_packet *rndis_pkt;
+ u32 data_offset;
+ struct ndis_pkt_8021q_info *vlan;
++ struct ndis_tcp_ip_checksum_info *csum_info;
+
+ rndis_pkt = &msg->msg.pkt;
+
+@@ -408,7 +409,8 @@ static void rndis_filter_receive_data(struct rndis_device *dev,
+ pkt->vlan_tci = 0;
+ }
+
+- netvsc_recv_callback(dev->net_dev->dev, pkt);
++ csum_info = rndis_get_ppi(rndis_pkt, TCPIP_CHKSUM_PKTINFO);
++ netvsc_recv_callback(dev->net_dev->dev, pkt, csum_info);
+ }
+
+ int rndis_filter_receive(struct hv_device *dev,
+--
+2.4.3
+
--- /dev/null
+From 2f18423d7ebf8044a9edaca840be5ae199fb32f6 Mon Sep 17 00:00:00 2001
+From: Dave Jones <davej@redhat.com>
+Date: Mon, 16 Jun 2014 16:59:02 -0400
+Subject: [PATCH 08/11] hyperv: fix apparent cut-n-paste error in send path
+ teardown
+
+c25aaf814a63: "hyperv: Enable sendbuf mechanism on the send path" added
+some teardown code that looks like it was copied from the recieve path
+above, but missed a variable name replacement.
+
+Signed-off-by: Dave Jones <davej@redhat.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/netvsc.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index c041f63a6d30..4ed38eaecea8 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -189,7 +189,7 @@ static int netvsc_destroy_buf(struct netvsc_device *net_device)
+ "unable to teardown send buffer's gpadl\n");
+ return ret;
+ }
+- net_device->recv_buf_gpadl_handle = 0;
++ net_device->send_buf_gpadl_handle = 0;
+ }
+ if (net_device->send_buf) {
+ /* Free up the receive buffer */
+--
+2.4.3
+
--- /dev/null
+From d2a0be7f4263eb669af84240c5424a72cce4cdb4 Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Sat, 8 Mar 2014 19:23:17 -0800
+Subject: [PATCH 09/25] Drivers: net: hyperv: Enable send side checksum offload
+
+Enable send side checksum offload.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 10 ++++++
+ drivers/net/hyperv/netvsc_drv.c | 69 +++++++++++++++++++++++++++++++++++++++--
+ 2 files changed, 77 insertions(+), 2 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index faeb74623fbd..4cf238234321 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -1035,6 +1035,16 @@ struct rndis_message {
+ #define NDIS_PACKET_TYPE_FUNCTIONAL 0x00000400
+ #define NDIS_PACKET_TYPE_MAC_FRAME 0x00000800
+
++#define INFO_IPV4 2
++#define INFO_IPV6 4
++#define INFO_TCP 2
++#define INFO_UDP 4
++
++#define TRANSPORT_INFO_NOT_IP 0
++#define TRANSPORT_INFO_IPV4_TCP ((INFO_IPV4 << 16) | INFO_TCP)
++#define TRANSPORT_INFO_IPV4_UDP ((INFO_IPV4 << 16) | INFO_UDP)
++#define TRANSPORT_INFO_IPV6_TCP ((INFO_IPV6 << 16) | INFO_TCP)
++#define TRANSPORT_INFO_IPV6_UDP ((INFO_IPV6 << 16) | INFO_UDP)
+
+
+ #endif /* _HYPERV_NET_H */
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 7438360b7a02..2fab69ac61ef 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -257,6 +257,35 @@ static int netvsc_get_slots(struct sk_buff *skb)
+ return slots + frag_slots;
+ }
+
++static u32 get_net_transport_info(struct sk_buff *skb, u32 *trans_off)
++{
++ u32 ret_val = TRANSPORT_INFO_NOT_IP;
++
++ if ((eth_hdr(skb)->h_proto != htons(ETH_P_IP)) &&
++ (eth_hdr(skb)->h_proto != htons(ETH_P_IPV6))) {
++ goto not_ip;
++ }
++
++ *trans_off = skb_transport_offset(skb);
++
++ if ((eth_hdr(skb)->h_proto == htons(ETH_P_IP))) {
++ struct iphdr *iphdr = ip_hdr(skb);
++
++ if (iphdr->protocol == IPPROTO_TCP)
++ ret_val = TRANSPORT_INFO_IPV4_TCP;
++ else if (iphdr->protocol == IPPROTO_UDP)
++ ret_val = TRANSPORT_INFO_IPV4_UDP;
++ } else {
++ if (ipv6_hdr(skb)->nexthdr == IPPROTO_TCP)
++ ret_val = TRANSPORT_INFO_IPV6_TCP;
++ else if (ipv6_hdr(skb)->nexthdr == IPPROTO_UDP)
++ ret_val = TRANSPORT_INFO_IPV6_UDP;
++ }
++
++not_ip:
++ return ret_val;
++}
++
+ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ {
+ struct net_device_context *net_device_ctx = netdev_priv(net);
+@@ -269,6 +298,10 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ u32 rndis_msg_size;
+ bool isvlan;
+ struct rndis_per_packet_info *ppi;
++ struct ndis_tcp_ip_checksum_info *csum_info;
++ int hdr_offset;
++ u32 net_trans_info;
++
+
+ /* We will atmost need two pages to describe the rndis
+ * header. We can only transmit MAX_PAGE_BUFFER_COUNT number
+@@ -336,6 +369,37 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ VLAN_PRIO_SHIFT;
+ }
+
++ net_trans_info = get_net_transport_info(skb, &hdr_offset);
++ if (net_trans_info == TRANSPORT_INFO_NOT_IP)
++ goto do_send;
++
++ /*
++ * Setup the sendside checksum offload only if this is not a
++ * GSO packet.
++ */
++ if (skb_is_gso(skb))
++ goto do_send;
++
++ rndis_msg_size += NDIS_CSUM_PPI_SIZE;
++ ppi = init_ppi_data(rndis_msg, NDIS_CSUM_PPI_SIZE,
++ TCPIP_CHKSUM_PKTINFO);
++
++ csum_info = (struct ndis_tcp_ip_checksum_info *)((void *)ppi +
++ ppi->ppi_offset);
++
++ if (net_trans_info & (INFO_IPV4 << 16))
++ csum_info->transmit.is_ipv4 = 1;
++ else
++ csum_info->transmit.is_ipv6 = 1;
++
++ if (net_trans_info & INFO_TCP) {
++ csum_info->transmit.tcp_checksum = 1;
++ csum_info->transmit.tcp_header_offset = hdr_offset;
++ } else if (net_trans_info & INFO_UDP) {
++ csum_info->transmit.udp_checksum = 1;
++ }
++
++do_send:
+ /* Start filling in the page buffers with the rndis hdr */
+ rndis_msg->msg_len += rndis_msg_size;
+ packet->page_buf_cnt = init_page_array(rndis_msg, rndis_msg_size,
+@@ -592,8 +656,9 @@ static int netvsc_probe(struct hv_device *dev,
+ net->netdev_ops = &device_ops;
+
+ /* TODO: Add GSO and Checksum offload */
+- net->hw_features = NETIF_F_RXCSUM | NETIF_F_SG;
+- net->features = NETIF_F_HW_VLAN_CTAG_TX | NETIF_F_SG | NETIF_F_RXCSUM;
++ net->hw_features = NETIF_F_RXCSUM | NETIF_F_SG | NETIF_F_IP_CSUM;
++ net->features = NETIF_F_HW_VLAN_CTAG_TX | NETIF_F_SG | NETIF_F_RXCSUM |
++ NETIF_F_IP_CSUM;
+
+ SET_ETHTOOL_OPS(net, ðtool_ops);
+ SET_NETDEV_DEV(net, &dev->device);
+--
+2.4.3
+
--- /dev/null
+From dd1d3f8f9920926aa426589e542eed6bf58b7354 Mon Sep 17 00:00:00 2001
+From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
+Date: Wed, 23 Jul 2014 09:00:35 +0800
+Subject: [PATCH 09/11] hyperv: Fix error return code in netvsc_init_buf()
+
+Fix to return -ENOMEM from the kalloc error handling
+case instead of 0.
+
+Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/netvsc.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index 4ed38eaecea8..d97d5f39a04e 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -378,8 +378,10 @@ static int netvsc_init_buf(struct hv_device *device)
+
+ net_device->send_section_map =
+ kzalloc(net_device->map_words * sizeof(ulong), GFP_KERNEL);
+- if (net_device->send_section_map == NULL)
++ if (net_device->send_section_map == NULL) {
++ ret = -ENOMEM;
+ goto cleanup;
++ }
+
+ goto exit;
+
+--
+2.4.3
+
--- /dev/null
+From a4ec4f58017b456281ee17c35fb82dfe4eab2193 Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Sat, 8 Mar 2014 19:23:18 -0800
+Subject: [PATCH 10/25] Drivers: net: hyperv: Enable large send offload
+
+Enable segmentation offload.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 40 ++++++++++++++++++++++++++++++++++++++++
+ drivers/net/hyperv/netvsc_drv.c | 38 ++++++++++++++++++++++++++++++++++----
+ 2 files changed, 74 insertions(+), 4 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index 4cf238234321..7d06b4959383 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -742,6 +742,10 @@ struct ndis_oject_header {
+ #define NDIS_OFFLOAD_PARAMETERS_RX_ENABLED_TX_DISABLED 3
+ #define NDIS_OFFLOAD_PARAMETERS_TX_RX_ENABLED 4
+
++#define NDIS_TCP_LARGE_SEND_OFFLOAD_V2_TYPE 1
++#define NDIS_TCP_LARGE_SEND_OFFLOAD_IPV4 0
++#define NDIS_TCP_LARGE_SEND_OFFLOAD_IPV6 1
++
+ /*
+ * New offload OIDs for NDIS 6
+ */
+@@ -804,12 +808,48 @@ struct ndis_tcp_ip_checksum_info {
+ };
+ };
+
++struct ndis_tcp_lso_info {
++ union {
++ struct {
++ u32 unused:30;
++ u32 type:1;
++ u32 reserved2:1;
++ } transmit;
++ struct {
++ u32 mss:20;
++ u32 tcp_header_offset:10;
++ u32 type:1;
++ u32 reserved2:1;
++ } lso_v1_transmit;
++ struct {
++ u32 tcp_payload:30;
++ u32 type:1;
++ u32 reserved2:1;
++ } lso_v1_transmit_complete;
++ struct {
++ u32 mss:20;
++ u32 tcp_header_offset:10;
++ u32 type:1;
++ u32 ip_version:1;
++ } lso_v2_transmit;
++ struct {
++ u32 reserved:30;
++ u32 type:1;
++ u32 reserved2:1;
++ } lso_v2_transmit_complete;
++ u32 value;
++ };
++};
++
+ #define NDIS_VLAN_PPI_SIZE (sizeof(struct rndis_per_packet_info) + \
+ sizeof(struct ndis_pkt_8021q_info))
+
+ #define NDIS_CSUM_PPI_SIZE (sizeof(struct rndis_per_packet_info) + \
+ sizeof(struct ndis_tcp_ip_checksum_info))
+
++#define NDIS_LSO_PPI_SIZE (sizeof(struct rndis_per_packet_info) + \
++ sizeof(struct ndis_tcp_lso_info))
++
+ /* Format of Information buffer passed in a SetRequest for the OID */
+ /* OID_GEN_RNDIS_CONFIG_PARAMETER. */
+ struct rndis_config_parameter_info {
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 2fab69ac61ef..5baa1fa7e692 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -299,6 +299,7 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ bool isvlan;
+ struct rndis_per_packet_info *ppi;
+ struct ndis_tcp_ip_checksum_info *csum_info;
++ struct ndis_tcp_lso_info *lso_info;
+ int hdr_offset;
+ u32 net_trans_info;
+
+@@ -378,7 +379,7 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ * GSO packet.
+ */
+ if (skb_is_gso(skb))
+- goto do_send;
++ goto do_lso;
+
+ rndis_msg_size += NDIS_CSUM_PPI_SIZE;
+ ppi = init_ppi_data(rndis_msg, NDIS_CSUM_PPI_SIZE,
+@@ -398,6 +399,35 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ } else if (net_trans_info & INFO_UDP) {
+ csum_info->transmit.udp_checksum = 1;
+ }
++ goto do_send;
++
++do_lso:
++ rndis_msg_size += NDIS_LSO_PPI_SIZE;
++ ppi = init_ppi_data(rndis_msg, NDIS_LSO_PPI_SIZE,
++ TCP_LARGESEND_PKTINFO);
++
++ lso_info = (struct ndis_tcp_lso_info *)((void *)ppi +
++ ppi->ppi_offset);
++
++ lso_info->lso_v2_transmit.type = NDIS_TCP_LARGE_SEND_OFFLOAD_V2_TYPE;
++ if (net_trans_info & (INFO_IPV4 << 16)) {
++ lso_info->lso_v2_transmit.ip_version =
++ NDIS_TCP_LARGE_SEND_OFFLOAD_IPV4;
++ ip_hdr(skb)->tot_len = 0;
++ ip_hdr(skb)->check = 0;
++ tcp_hdr(skb)->check =
++ ~csum_tcpudp_magic(ip_hdr(skb)->saddr,
++ ip_hdr(skb)->daddr, 0, IPPROTO_TCP, 0);
++ } else {
++ lso_info->lso_v2_transmit.ip_version =
++ NDIS_TCP_LARGE_SEND_OFFLOAD_IPV6;
++ ipv6_hdr(skb)->payload_len = 0;
++ tcp_hdr(skb)->check =
++ ~csum_ipv6_magic(&ipv6_hdr(skb)->saddr,
++ &ipv6_hdr(skb)->daddr, 0, IPPROTO_TCP, 0);
++ }
++ lso_info->lso_v2_transmit.tcp_header_offset = hdr_offset;
++ lso_info->lso_v2_transmit.mss = skb_shinfo(skb)->gso_size;
+
+ do_send:
+ /* Start filling in the page buffers with the rndis hdr */
+@@ -655,10 +685,10 @@ static int netvsc_probe(struct hv_device *dev,
+
+ net->netdev_ops = &device_ops;
+
+- /* TODO: Add GSO and Checksum offload */
+- net->hw_features = NETIF_F_RXCSUM | NETIF_F_SG | NETIF_F_IP_CSUM;
++ net->hw_features = NETIF_F_RXCSUM | NETIF_F_SG | NETIF_F_IP_CSUM |
++ NETIF_F_TSO;
+ net->features = NETIF_F_HW_VLAN_CTAG_TX | NETIF_F_SG | NETIF_F_RXCSUM |
+- NETIF_F_IP_CSUM;
++ NETIF_F_IP_CSUM | NETIF_F_TSO;
+
+ SET_ETHTOOL_OPS(net, ðtool_ops);
+ SET_NETDEV_DEV(net, &dev->device);
+--
+2.4.3
+
--- /dev/null
+From b3e774263908a834c1c0d5abf3a7658280e42fc7 Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Sun, 28 Sep 2014 22:16:43 -0700
+Subject: [PATCH 10/11] hyperv: Fix a bug in netvsc_start_xmit()
+
+[ Upstream commit dedb845ded56ded1c62f5398a94ffa8615d4592d ]
+
+After the packet is successfully sent, we should not touch the skb
+as it may have been freed. This patch is based on the work done by
+Long Li <longli@microsoft.com>.
+
+In this version of the patch I have fixed issues pointed out by David.
+David, please queue this up for stable.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Tested-by: Long Li <longli@microsoft.com>
+Tested-by: Sitsofe Wheeler <sitsofe@yahoo.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/net/hyperv/netvsc_drv.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 4fd71b75e666..f15297201777 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -387,6 +387,7 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ int hdr_offset;
+ u32 net_trans_info;
+ u32 hash;
++ u32 skb_length = skb->len;
+
+
+ /* We will atmost need two pages to describe the rndis
+@@ -562,7 +563,7 @@ do_send:
+
+ drop:
+ if (ret == 0) {
+- net->stats.tx_bytes += skb->len;
++ net->stats.tx_bytes += skb_length;
+ net->stats.tx_packets++;
+ } else {
+ kfree(packet);
+--
+2.4.3
+
-From 99d3016de4f2a29635f5382b0e9bd0e5f2151487 Mon Sep 17 00:00:00 2001
+From 56b3f72d3fed7f9b8d17dcf5d81455fa1b4327d7 Mon Sep 17 00:00:00 2001
From: Haiyang Zhang <haiyangz@microsoft.com>
Date: Sun, 9 Mar 2014 16:10:59 -0700
-Subject: hyperv: Change the receive buffer size for legacy hosts
+Subject: [PATCH 11/25] hyperv: Change the receive buffer size for legacy hosts
Due to a bug in the Hyper-V host verion 2008R2, we need to use a slightly smaller
receive buffer size, otherwise the buffer will not be accepted by the legacy hosts.
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 1 +
+ drivers/net/hyperv/netvsc.c | 6 +++++-
+ 2 files changed, 6 insertions(+), 1 deletion(-)
diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
-index 7d06b49..13010b4 100644
+index 7d06b4959383..13010b4dae5b 100644
--- a/drivers/net/hyperv/hyperv_net.h
+++ b/drivers/net/hyperv/hyperv_net.h
@@ -513,6 +513,7 @@ struct nvsp_message {
#define NETVSC_RECEIVE_BUFFER_ID 0xcafe
diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
-index 1a0280d..daddea2 100644
+index 1a0280dcba7e..daddea2654ce 100644
--- a/drivers/net/hyperv/netvsc.c
+++ b/drivers/net/hyperv/netvsc.c
@@ -365,6 +365,11 @@ static int netvsc_connect_vsp(struct hv_device *device)
INIT_LIST_HEAD(&net_device->recv_pkt_list);
--
-cgit v0.10.2
+2.4.3
--- /dev/null
+From 26875bba869bd91a1d8fef9229a56a1e6d9fef2b Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Sun, 5 Oct 2014 10:42:51 -0700
+Subject: [PATCH 11/11] hyperv: Fix a bug in netvsc_send()
+
+[ Upstream commit 3a67c9ccad926a168d8b7891537a452018368a5b ]
+
+After the packet is successfully sent, we should not touch the packet
+as it may have been freed. This patch is based on the work done by
+Long Li <longli@microsoft.com>.
+
+David, please queue this up for stable.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reported-by: Sitsofe Wheeler <sitsofe@yahoo.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/net/hyperv/netvsc.c | 15 ++++++++-------
+ 1 file changed, 8 insertions(+), 7 deletions(-)
+
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index d97d5f39a04e..7edf976ecfa0 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -708,6 +708,7 @@ int netvsc_send(struct hv_device *device,
+ unsigned int section_index = NETVSC_INVALID_INDEX;
+ u32 msg_size = 0;
+ struct sk_buff *skb;
++ u16 q_idx = packet->q_idx;
+
+
+ net_device = get_outbound_net_device(device);
+@@ -772,24 +773,24 @@ int netvsc_send(struct hv_device *device,
+
+ if (ret == 0) {
+ atomic_inc(&net_device->num_outstanding_sends);
+- atomic_inc(&net_device->queue_sends[packet->q_idx]);
++ atomic_inc(&net_device->queue_sends[q_idx]);
+
+ if (hv_ringbuf_avail_percent(&out_channel->outbound) <
+ RING_AVAIL_PERCENT_LOWATER) {
+ netif_tx_stop_queue(netdev_get_tx_queue(
+- ndev, packet->q_idx));
++ ndev, q_idx));
+
+ if (atomic_read(&net_device->
+- queue_sends[packet->q_idx]) < 1)
++ queue_sends[q_idx]) < 1)
+ netif_tx_wake_queue(netdev_get_tx_queue(
+- ndev, packet->q_idx));
++ ndev, q_idx));
+ }
+ } else if (ret == -EAGAIN) {
+ netif_tx_stop_queue(netdev_get_tx_queue(
+- ndev, packet->q_idx));
+- if (atomic_read(&net_device->queue_sends[packet->q_idx]) < 1) {
++ ndev, q_idx));
++ if (atomic_read(&net_device->queue_sends[q_idx]) < 1) {
+ netif_tx_wake_queue(netdev_get_tx_queue(
+- ndev, packet->q_idx));
++ ndev, q_idx));
+ ret = -ENOSPC;
+ }
+ } else {
+--
+2.4.3
+
--- /dev/null
+From e0f6906eb7e5b395370da9499189d13b59020382 Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Wed, 9 Apr 2014 15:00:45 -0700
+Subject: [PATCH 12/25] Drivers: net: hyperv: Allocate memory for all possible
+ per-pecket information
+
+An outgoing packet can potentially need per-packet information for
+all the offloads and VLAN tagging. Fix this issue.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/netvsc_drv.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 5baa1fa7e692..c76c85176644 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -320,7 +320,9 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ packet = kzalloc(sizeof(struct hv_netvsc_packet) +
+ (num_data_pgs * sizeof(struct hv_page_buffer)) +
+ sizeof(struct rndis_message) +
+- NDIS_VLAN_PPI_SIZE, GFP_ATOMIC);
++ NDIS_VLAN_PPI_SIZE +
++ NDIS_CSUM_PPI_SIZE +
++ NDIS_LSO_PPI_SIZE, GFP_ATOMIC);
+ if (!packet) {
+ /* out of memory, drop packet */
+ netdev_err(net, "unable to allocate hv_netvsc_packet\n");
+--
+2.4.3
+
--- /dev/null
+From 8a7882bada78e7d7355aafc0ca3c5696d25eb443 Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Wed, 9 Apr 2014 15:00:46 -0700
+Subject: [PATCH 13/25] Drivers: net: hyperv: Negotiate suitable ndis version
+ for offload support
+
+Ws2008R2 supports ndis_version 6.1 and 6.1 is the minimal version required
+for various offloads. Negotiate ndis_version 6.1 when on ws2008r2.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/netvsc.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index daddea2654ce..f7629ecefa84 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -344,7 +344,7 @@ static int netvsc_connect_vsp(struct hv_device *device)
+ memset(init_packet, 0, sizeof(struct nvsp_message));
+
+ if (net_device->nvsp_version <= NVSP_PROTOCOL_VERSION_4)
+- ndis_version = 0x00050001;
++ ndis_version = 0x00060001;
+ else
+ ndis_version = 0x0006001e;
+
+--
+2.4.3
+
--- /dev/null
+From b822ee7a17efd1bc8c7584da5d0a2c042e9ca5b6 Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Wed, 9 Apr 2014 15:00:47 -0700
+Subject: [PATCH 14/25] Drivers: net: hyperv: Address UDP checksum issues
+
+ws2008r2 does not support UDP checksum offload. Thus, we cannnot turn on
+UDP offload in the host. Also, on ws2012 and ws2012 r2, there appear to be
+an issue with UDP checksum offload.
+Fix this issue by computing the UDP checksum in the Hyper-V driver.
+
+Based on Dave Miller's comments, in this version, I have COWed the skb
+before modifying the UDP header (the checksum field).
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 1 +
+ drivers/net/hyperv/netvsc_drv.c | 26 +++++++++++++++++++++++++-
+ drivers/net/hyperv/rndis_filter.c | 12 +++++++++++-
+ 3 files changed, 37 insertions(+), 2 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index 13010b4dae5b..d18f711d0b0c 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -747,6 +747,7 @@ struct ndis_oject_header {
+ #define NDIS_TCP_LARGE_SEND_OFFLOAD_IPV4 0
+ #define NDIS_TCP_LARGE_SEND_OFFLOAD_IPV6 1
+
++#define VERSION_4_OFFLOAD_SIZE 22
+ /*
+ * New offload OIDs for NDIS 6
+ */
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index c76c85176644..0d898876689e 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -399,7 +399,30 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ csum_info->transmit.tcp_checksum = 1;
+ csum_info->transmit.tcp_header_offset = hdr_offset;
+ } else if (net_trans_info & INFO_UDP) {
+- csum_info->transmit.udp_checksum = 1;
++ /* UDP checksum offload is not supported on ws2008r2.
++ * Furthermore, on ws2012 and ws2012r2, there are some
++ * issues with udp checksum offload from Linux guests.
++ * (these are host issues).
++ * For now compute the checksum here.
++ */
++ struct udphdr *uh;
++ u16 udp_len;
++
++ ret = skb_cow_head(skb, 0);
++ if (ret)
++ goto drop;
++
++ uh = udp_hdr(skb);
++ udp_len = ntohs(uh->len);
++ uh->check = 0;
++ uh->check = csum_tcpudp_magic(ip_hdr(skb)->saddr,
++ ip_hdr(skb)->daddr,
++ udp_len, IPPROTO_UDP,
++ csum_partial(uh, udp_len, 0));
++ if (uh->check == 0)
++ uh->check = CSUM_MANGLED_0;
++
++ csum_info->transmit.udp_checksum = 0;
+ }
+ goto do_send;
+
+@@ -439,6 +462,7 @@ do_send:
+
+ ret = netvsc_send(net_device_ctx->device_ctx, packet);
+
++drop:
+ if (ret == 0) {
+ net->stats.tx_bytes += skb_length;
+ net->stats.tx_packets++;
+diff --git a/drivers/net/hyperv/rndis_filter.c b/drivers/net/hyperv/rndis_filter.c
+index 4a37e3db9e32..143a98caf618 100644
+--- a/drivers/net/hyperv/rndis_filter.c
++++ b/drivers/net/hyperv/rndis_filter.c
+@@ -641,6 +641,16 @@ int rndis_filter_set_offload_params(struct hv_device *hdev,
+ struct rndis_set_complete *set_complete;
+ u32 extlen = sizeof(struct ndis_offload_params);
+ int ret, t;
++ u32 vsp_version = nvdev->nvsp_version;
++
++ if (vsp_version <= NVSP_PROTOCOL_VERSION_4) {
++ extlen = VERSION_4_OFFLOAD_SIZE;
++ /* On NVSP_PROTOCOL_VERSION_4 and below, we do not support
++ * UDP checksum offload.
++ */
++ req_offloads->udp_ip_v4_csum = 0;
++ req_offloads->udp_ip_v6_csum = 0;
++ }
+
+ request = get_rndis_request(rdev, RNDIS_MSG_SET,
+ RNDIS_MESSAGE_SIZE(struct rndis_set_request) + extlen);
+@@ -674,7 +684,7 @@ int rndis_filter_set_offload_params(struct hv_device *hdev,
+ } else {
+ set_complete = &request->response_msg.msg.set_complete;
+ if (set_complete->status != RNDIS_STATUS_SUCCESS) {
+- netdev_err(ndev, "Fail to set MAC on host side:0x%x\n",
++ netdev_err(ndev, "Fail to set offload on host side:0x%x\n",
+ set_complete->status);
+ ret = -EINVAL;
+ }
+--
+2.4.3
+
--- /dev/null
+From 540360773bad2b81f14c38ca92b62797fa32cbc6 Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Wed, 30 Apr 2014 11:58:25 -0700
+Subject: [PATCH 15/25] hyperv: Properly handle checksum offload
+
+Do checksum offload only if the client of the driver wants checksum to be
+offloaded.
+
+In V1 version of this patch, I addressed comments from
+Stephen Hemminger <stephen@networkplumber.org> and
+Eric Dumazet <eric.dumazet@gmail.com>.
+
+In this version of the patch I have addressed comments from
+David Miller.
+
+This patch fixes a bug that is exposed in gateway scenarios.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/netvsc_drv.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 0d898876689e..ce6d870dd7ae 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -383,6 +383,10 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ if (skb_is_gso(skb))
+ goto do_lso;
+
++ if ((skb->ip_summed == CHECKSUM_NONE) ||
++ (skb->ip_summed == CHECKSUM_UNNECESSARY))
++ goto do_send;
++
+ rndis_msg_size += NDIS_CSUM_PPI_SIZE;
+ ppi = init_ppi_data(rndis_msg, NDIS_CSUM_PPI_SIZE,
+ TCPIP_CHKSUM_PKTINFO);
+--
+2.4.3
+
--- /dev/null
+From 44559a96c6864eb6e95db0ae896c621b82e605f3 Mon Sep 17 00:00:00 2001
+From: Haiyang Zhang <haiyangz@microsoft.com>
+Date: Mon, 21 Apr 2014 10:20:28 -0700
+Subject: [PATCH 16/25] hyperv: Add support for virtual Receive Side Scaling
+ (vRSS)
+
+This feature allows multiple channels to be used by each virtual NIC.
+It is available on Hyper-V host 2012 R2.
+
+Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
+Reviewed-by: K. Y. Srinivasan <kys@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 110 +++++++++++++++++++++-
+ drivers/net/hyperv/netvsc.c | 136 +++++++++++++++++++++------
+ drivers/net/hyperv/netvsc_drv.c | 103 ++++++++++++++++++++-
+ drivers/net/hyperv/rndis_filter.c | 189 +++++++++++++++++++++++++++++++++++++-
+ 4 files changed, 504 insertions(+), 34 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index d18f711d0b0c..57eb3f906d64 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -28,6 +28,96 @@
+ #include <linux/hyperv.h>
+ #include <linux/rndis.h>
+
++/* RSS related */
++#define OID_GEN_RECEIVE_SCALE_CAPABILITIES 0x00010203 /* query only */
++#define OID_GEN_RECEIVE_SCALE_PARAMETERS 0x00010204 /* query and set */
++
++#define NDIS_OBJECT_TYPE_RSS_CAPABILITIES 0x88
++#define NDIS_OBJECT_TYPE_RSS_PARAMETERS 0x89
++
++#define NDIS_RECEIVE_SCALE_CAPABILITIES_REVISION_2 2
++#define NDIS_RECEIVE_SCALE_PARAMETERS_REVISION_2 2
++
++struct ndis_obj_header {
++ u8 type;
++ u8 rev;
++ u16 size;
++} __packed;
++
++/* ndis_recv_scale_cap/cap_flag */
++#define NDIS_RSS_CAPS_MESSAGE_SIGNALED_INTERRUPTS 0x01000000
++#define NDIS_RSS_CAPS_CLASSIFICATION_AT_ISR 0x02000000
++#define NDIS_RSS_CAPS_CLASSIFICATION_AT_DPC 0x04000000
++#define NDIS_RSS_CAPS_USING_MSI_X 0x08000000
++#define NDIS_RSS_CAPS_RSS_AVAILABLE_ON_PORTS 0x10000000
++#define NDIS_RSS_CAPS_SUPPORTS_MSI_X 0x20000000
++#define NDIS_RSS_CAPS_HASH_TYPE_TCP_IPV4 0x00000100
++#define NDIS_RSS_CAPS_HASH_TYPE_TCP_IPV6 0x00000200
++#define NDIS_RSS_CAPS_HASH_TYPE_TCP_IPV6_EX 0x00000400
++
++struct ndis_recv_scale_cap { /* NDIS_RECEIVE_SCALE_CAPABILITIES */
++ struct ndis_obj_header hdr;
++ u32 cap_flag;
++ u32 num_int_msg;
++ u32 num_recv_que;
++ u16 num_indirect_tabent;
++} __packed;
++
++
++/* ndis_recv_scale_param flags */
++#define NDIS_RSS_PARAM_FLAG_BASE_CPU_UNCHANGED 0x0001
++#define NDIS_RSS_PARAM_FLAG_HASH_INFO_UNCHANGED 0x0002
++#define NDIS_RSS_PARAM_FLAG_ITABLE_UNCHANGED 0x0004
++#define NDIS_RSS_PARAM_FLAG_HASH_KEY_UNCHANGED 0x0008
++#define NDIS_RSS_PARAM_FLAG_DISABLE_RSS 0x0010
++
++/* Hash info bits */
++#define NDIS_HASH_FUNC_TOEPLITZ 0x00000001
++#define NDIS_HASH_IPV4 0x00000100
++#define NDIS_HASH_TCP_IPV4 0x00000200
++#define NDIS_HASH_IPV6 0x00000400
++#define NDIS_HASH_IPV6_EX 0x00000800
++#define NDIS_HASH_TCP_IPV6 0x00001000
++#define NDIS_HASH_TCP_IPV6_EX 0x00002000
++
++#define NDIS_RSS_INDIRECTION_TABLE_MAX_SIZE_REVISION_2 (128 * 4)
++#define NDIS_RSS_HASH_SECRET_KEY_MAX_SIZE_REVISION_2 40
++
++#define ITAB_NUM 128
++#define HASH_KEYLEN NDIS_RSS_HASH_SECRET_KEY_MAX_SIZE_REVISION_2
++extern u8 netvsc_hash_key[];
++
++struct ndis_recv_scale_param { /* NDIS_RECEIVE_SCALE_PARAMETERS */
++ struct ndis_obj_header hdr;
++
++ /* Qualifies the rest of the information */
++ u16 flag;
++
++ /* The base CPU number to do receive processing. not used */
++ u16 base_cpu_number;
++
++ /* This describes the hash function and type being enabled */
++ u32 hashinfo;
++
++ /* The size of indirection table array */
++ u16 indirect_tabsize;
++
++ /* The offset of the indirection table from the beginning of this
++ * structure
++ */
++ u32 indirect_taboffset;
++
++ /* The size of the hash secret key */
++ u16 hashkey_size;
++
++ /* The offset of the secret key from the beginning of this structure */
++ u32 kashkey_offset;
++
++ u32 processor_masks_offset;
++ u32 num_processor_masks;
++ u32 processor_masks_entry_size;
++};
++
+ /* Fwd declaration */
+ struct hv_netvsc_packet;
+ struct ndis_tcp_ip_checksum_info;
+@@ -39,6 +129,8 @@ struct xferpage_packet {
+
+ /* # of netvsc packets this xfer packet contains */
+ u32 count;
++
++ struct vmbus_channel *channel;
+ };
+
+ /*
+@@ -54,6 +146,9 @@ struct hv_netvsc_packet {
+ bool is_data_pkt;
+ u16 vlan_tci;
+
++ u16 q_idx;
++ struct vmbus_channel *channel;
++
+ /*
+ * Valid only for receives when we break a xfer page packet
+ * into multiple netvsc packets
+@@ -120,6 +215,7 @@ void netvsc_linkstatus_callback(struct hv_device *device_obj,
+ int netvsc_recv_callback(struct hv_device *device_obj,
+ struct hv_netvsc_packet *packet,
+ struct ndis_tcp_ip_checksum_info *csum_info);
++void netvsc_channel_cb(void *context);
+ int rndis_filter_open(struct hv_device *dev);
+ int rndis_filter_close(struct hv_device *dev);
+ int rndis_filter_device_add(struct hv_device *dev,
+@@ -522,6 +618,8 @@ struct nvsp_message {
+
+ #define NETVSC_PACKET_SIZE 2048
+
++#define VRSS_SEND_TAB_SIZE 16
++
+ /* Per netvsc channel-specific */
+ struct netvsc_device {
+ struct hv_device *dev;
+@@ -555,10 +653,20 @@ struct netvsc_device {
+
+ struct net_device *ndev;
+
++ struct vmbus_channel *chn_table[NR_CPUS];
++ u32 send_table[VRSS_SEND_TAB_SIZE];
++ u32 num_chn;
++ atomic_t queue_sends[NR_CPUS];
++
+ /* Holds rndis device info */
+ void *extension;
+- /* The recive buffer for this device */
++
++ int ring_size;
++
++ /* The primary channel callback buffer */
+ unsigned char cb_buffer[NETVSC_PACKET_SIZE];
++ /* The sub channel callback buffer */
++ unsigned char *sub_cb_buf;
+ };
+
+ /* NdisInitialize message */
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index f7629ecefa84..e7e77f12bc38 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -422,6 +422,9 @@ int netvsc_device_remove(struct hv_device *device)
+ kfree(netvsc_packet);
+ }
+
++ if (net_device->sub_cb_buf)
++ vfree(net_device->sub_cb_buf);
++
+ kfree(net_device);
+ return 0;
+ }
+@@ -461,7 +464,9 @@ static void netvsc_send_completion(struct netvsc_device *net_device,
+ (nvsp_packet->hdr.msg_type ==
+ NVSP_MSG1_TYPE_SEND_RECV_BUF_COMPLETE) ||
+ (nvsp_packet->hdr.msg_type ==
+- NVSP_MSG1_TYPE_SEND_SEND_BUF_COMPLETE)) {
++ NVSP_MSG1_TYPE_SEND_SEND_BUF_COMPLETE) ||
++ (nvsp_packet->hdr.msg_type ==
++ NVSP_MSG5_TYPE_SUBCHANNEL)) {
+ /* Copy the response back */
+ memcpy(&net_device->channel_init_pkt, nvsp_packet,
+ sizeof(struct nvsp_message));
+@@ -469,28 +474,37 @@ static void netvsc_send_completion(struct netvsc_device *net_device,
+ } else if (nvsp_packet->hdr.msg_type ==
+ NVSP_MSG1_TYPE_SEND_RNDIS_PKT_COMPLETE) {
+ int num_outstanding_sends;
++ u16 q_idx = 0;
++ struct vmbus_channel *channel = device->channel;
++ int queue_sends;
+
+ /* Get the send context */
+ nvsc_packet = (struct hv_netvsc_packet *)(unsigned long)
+ packet->trans_id;
+
+ /* Notify the layer above us */
+- if (nvsc_packet)
++ if (nvsc_packet) {
++ q_idx = nvsc_packet->q_idx;
++ channel = nvsc_packet->channel;
+ nvsc_packet->completion.send.send_completion(
+ nvsc_packet->completion.send.
+ send_completion_ctx);
++ }
+
+ num_outstanding_sends =
+ atomic_dec_return(&net_device->num_outstanding_sends);
++ queue_sends = atomic_dec_return(&net_device->
++ queue_sends[q_idx]);
+
+ if (net_device->destroy && num_outstanding_sends == 0)
+ wake_up(&net_device->wait_drain);
+
+- if (netif_queue_stopped(ndev) && !net_device->start_remove &&
+- (hv_ringbuf_avail_percent(&device->channel->outbound)
+- > RING_AVAIL_PERCENT_HIWATER ||
+- num_outstanding_sends < 1))
+- netif_wake_queue(ndev);
++ if (netif_tx_queue_stopped(netdev_get_tx_queue(ndev, q_idx)) &&
++ !net_device->start_remove &&
++ (hv_ringbuf_avail_percent(&channel->outbound) >
++ RING_AVAIL_PERCENT_HIWATER || queue_sends < 1))
++ netif_tx_wake_queue(netdev_get_tx_queue(
++ ndev, q_idx));
+ } else {
+ netdev_err(ndev, "Unknown send completion packet type- "
+ "%d received!!\n", nvsp_packet->hdr.msg_type);
+@@ -505,6 +519,7 @@ int netvsc_send(struct hv_device *device,
+ int ret = 0;
+ struct nvsp_message sendMessage;
+ struct net_device *ndev;
++ struct vmbus_channel *out_channel = NULL;
+ u64 req_id;
+
+ net_device = get_outbound_net_device(device);
+@@ -531,15 +546,20 @@ int netvsc_send(struct hv_device *device,
+ else
+ req_id = 0;
+
++ out_channel = net_device->chn_table[packet->q_idx];
++ if (out_channel == NULL)
++ out_channel = device->channel;
++ packet->channel = out_channel;
++
+ if (packet->page_buf_cnt) {
+- ret = vmbus_sendpacket_pagebuffer(device->channel,
++ ret = vmbus_sendpacket_pagebuffer(out_channel,
+ packet->page_buf,
+ packet->page_buf_cnt,
+ &sendMessage,
+ sizeof(struct nvsp_message),
+ req_id);
+ } else {
+- ret = vmbus_sendpacket(device->channel, &sendMessage,
++ ret = vmbus_sendpacket(out_channel, &sendMessage,
+ sizeof(struct nvsp_message),
+ req_id,
+ VM_PKT_DATA_INBAND,
+@@ -548,17 +568,24 @@ int netvsc_send(struct hv_device *device,
+
+ if (ret == 0) {
+ atomic_inc(&net_device->num_outstanding_sends);
+- if (hv_ringbuf_avail_percent(&device->channel->outbound) <
++ atomic_inc(&net_device->queue_sends[packet->q_idx]);
++
++ if (hv_ringbuf_avail_percent(&out_channel->outbound) <
+ RING_AVAIL_PERCENT_LOWATER) {
+- netif_stop_queue(ndev);
++ netif_tx_stop_queue(netdev_get_tx_queue(
++ ndev, packet->q_idx));
++
+ if (atomic_read(&net_device->
+- num_outstanding_sends) < 1)
+- netif_wake_queue(ndev);
++ queue_sends[packet->q_idx]) < 1)
++ netif_tx_wake_queue(netdev_get_tx_queue(
++ ndev, packet->q_idx));
+ }
+ } else if (ret == -EAGAIN) {
+- netif_stop_queue(ndev);
+- if (atomic_read(&net_device->num_outstanding_sends) < 1) {
+- netif_wake_queue(ndev);
++ netif_tx_stop_queue(netdev_get_tx_queue(
++ ndev, packet->q_idx));
++ if (atomic_read(&net_device->queue_sends[packet->q_idx]) < 1) {
++ netif_tx_wake_queue(netdev_get_tx_queue(
++ ndev, packet->q_idx));
+ ret = -ENOSPC;
+ }
+ } else {
+@@ -570,6 +597,7 @@ int netvsc_send(struct hv_device *device,
+ }
+
+ static void netvsc_send_recv_completion(struct hv_device *device,
++ struct vmbus_channel *channel,
+ struct netvsc_device *net_device,
+ u64 transaction_id, u32 status)
+ {
+@@ -587,7 +615,7 @@ static void netvsc_send_recv_completion(struct hv_device *device,
+
+ retry_send_cmplt:
+ /* Send the completion */
+- ret = vmbus_sendpacket(device->channel, &recvcompMessage,
++ ret = vmbus_sendpacket(channel, &recvcompMessage,
+ sizeof(struct nvsp_message), transaction_id,
+ VM_PKT_COMP, 0);
+ if (ret == 0) {
+@@ -618,6 +646,7 @@ static void netvsc_receive_completion(void *context)
+ {
+ struct hv_netvsc_packet *packet = context;
+ struct hv_device *device = packet->device;
++ struct vmbus_channel *channel;
+ struct netvsc_device *net_device;
+ u64 transaction_id = 0;
+ bool fsend_receive_comp = false;
+@@ -649,6 +678,7 @@ static void netvsc_receive_completion(void *context)
+ */
+ if (packet->xfer_page_pkt->count == 0) {
+ fsend_receive_comp = true;
++ channel = packet->xfer_page_pkt->channel;
+ transaction_id = packet->completion.recv.recv_completion_tid;
+ status = packet->xfer_page_pkt->status;
+ list_add_tail(&packet->xfer_page_pkt->list_ent,
+@@ -662,12 +692,13 @@ static void netvsc_receive_completion(void *context)
+
+ /* Send a receive completion for the xfer page packet */
+ if (fsend_receive_comp)
+- netvsc_send_recv_completion(device, net_device, transaction_id,
+- status);
++ netvsc_send_recv_completion(device, channel, net_device,
++ transaction_id, status);
+
+ }
+
+ static void netvsc_receive(struct netvsc_device *net_device,
++ struct vmbus_channel *channel,
+ struct hv_device *device,
+ struct vmpacket_descriptor *packet)
+ {
+@@ -748,7 +779,7 @@ static void netvsc_receive(struct netvsc_device *net_device,
+ spin_unlock_irqrestore(&net_device->recv_pkt_list_lock,
+ flags);
+
+- netvsc_send_recv_completion(device, net_device,
++ netvsc_send_recv_completion(device, channel, net_device,
+ vmxferpage_packet->d.trans_id,
+ NVSP_STAT_FAIL);
+
+@@ -759,6 +790,7 @@ static void netvsc_receive(struct netvsc_device *net_device,
+ xferpage_packet = (struct xferpage_packet *)listHead.next;
+ list_del(&xferpage_packet->list_ent);
+ xferpage_packet->status = NVSP_STAT_SUCCESS;
++ xferpage_packet->channel = channel;
+
+ /* This is how much we can satisfy */
+ xferpage_packet->count = count - 1;
+@@ -800,10 +832,45 @@ static void netvsc_receive(struct netvsc_device *net_device,
+
+ }
+
+-static void netvsc_channel_cb(void *context)
++
++static void netvsc_send_table(struct hv_device *hdev,
++ struct vmpacket_descriptor *vmpkt)
++{
++ struct netvsc_device *nvscdev;
++ struct net_device *ndev;
++ struct nvsp_message *nvmsg;
++ int i;
++ u32 count, *tab;
++
++ nvscdev = get_outbound_net_device(hdev);
++ if (!nvscdev)
++ return;
++ ndev = nvscdev->ndev;
++
++ nvmsg = (struct nvsp_message *)((unsigned long)vmpkt +
++ (vmpkt->offset8 << 3));
++
++ if (nvmsg->hdr.msg_type != NVSP_MSG5_TYPE_SEND_INDIRECTION_TABLE)
++ return;
++
++ count = nvmsg->msg.v5_msg.send_table.count;
++ if (count != VRSS_SEND_TAB_SIZE) {
++ netdev_err(ndev, "Received wrong send-table size:%u\n", count);
++ return;
++ }
++
++ tab = (u32 *)((unsigned long)&nvmsg->msg.v5_msg.send_table +
++ nvmsg->msg.v5_msg.send_table.offset);
++
++ for (i = 0; i < count; i++)
++ nvscdev->send_table[i] = tab[i];
++}
++
++void netvsc_channel_cb(void *context)
+ {
+ int ret;
+- struct hv_device *device = context;
++ struct vmbus_channel *channel = (struct vmbus_channel *)context;
++ struct hv_device *device;
+ struct netvsc_device *net_device;
+ u32 bytes_recvd;
+ u64 request_id;
+@@ -812,14 +879,19 @@ static void netvsc_channel_cb(void *context)
+ int bufferlen = NETVSC_PACKET_SIZE;
+ struct net_device *ndev;
+
++ if (channel->primary_channel != NULL)
++ device = channel->primary_channel->device_obj;
++ else
++ device = channel->device_obj;
++
+ net_device = get_inbound_net_device(device);
+ if (!net_device)
+ return;
+ ndev = net_device->ndev;
+- buffer = net_device->cb_buffer;
++ buffer = get_per_channel_state(channel);
+
+ do {
+- ret = vmbus_recvpacket_raw(device->channel, buffer, bufferlen,
++ ret = vmbus_recvpacket_raw(channel, buffer, bufferlen,
+ &bytes_recvd, &request_id);
+ if (ret == 0) {
+ if (bytes_recvd > 0) {
+@@ -831,8 +903,12 @@ static void netvsc_channel_cb(void *context)
+ break;
+
+ case VM_PKT_DATA_USING_XFER_PAGES:
+- netvsc_receive(net_device,
+- device, desc);
++ netvsc_receive(net_device, channel,
++ device, desc);
++ break;
++
++ case VM_PKT_DATA_INBAND:
++ netvsc_send_table(device, desc);
+ break;
+
+ default:
+@@ -893,6 +969,8 @@ int netvsc_device_add(struct hv_device *device, void *additional_info)
+ goto cleanup;
+ }
+
++ net_device->ring_size = ring_size;
++
+ /*
+ * Coming into this function, struct net_device * is
+ * registered as the driver private data.
+@@ -917,10 +995,12 @@ int netvsc_device_add(struct hv_device *device, void *additional_info)
+ }
+ init_completion(&net_device->channel_init_wait);
+
++ set_per_channel_state(device->channel, net_device->cb_buffer);
++
+ /* Open the channel */
+ ret = vmbus_open(device->channel, ring_size * PAGE_SIZE,
+ ring_size * PAGE_SIZE, NULL, 0,
+- netvsc_channel_cb, device);
++ netvsc_channel_cb, device->channel);
+
+ if (ret != 0) {
+ netdev_err(ndev, "unable to open channel: %d\n", ret);
+@@ -930,6 +1010,8 @@ int netvsc_device_add(struct hv_device *device, void *additional_info)
+ /* Channel is opened */
+ pr_info("hv_netvsc channel opened successfully\n");
+
++ net_device->chn_table[0] = device->channel;
++
+ /* Connect with the NetVsp */
+ ret = netvsc_connect_vsp(device);
+ if (ret != 0) {
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index ce6d870dd7ae..e486dbd33f61 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -101,7 +101,7 @@ static int netvsc_open(struct net_device *net)
+ return ret;
+ }
+
+- netif_start_queue(net);
++ netif_tx_start_all_queues(net);
+
+ nvdev = hv_get_drvdata(device_obj);
+ rdev = nvdev->extension;
+@@ -149,6 +149,88 @@ static void *init_ppi_data(struct rndis_message *msg, u32 ppi_size,
+ return ppi;
+ }
+
++union sub_key {
++ u64 k;
++ struct {
++ u8 pad[3];
++ u8 kb;
++ u32 ka;
++ };
++};
++
++/* Toeplitz hash function
++ * data: network byte order
++ * return: host byte order
++ */
++static u32 comp_hash(u8 *key, int klen, u8 *data, int dlen)
++{
++ union sub_key subk;
++ int k_next = 4;
++ u8 dt;
++ int i, j;
++ u32 ret = 0;
++
++ subk.k = 0;
++ subk.ka = ntohl(*(u32 *)key);
++
++ for (i = 0; i < dlen; i++) {
++ subk.kb = key[k_next];
++ k_next = (k_next + 1) % klen;
++ dt = data[i];
++ for (j = 0; j < 8; j++) {
++ if (dt & 0x80)
++ ret ^= subk.ka;
++ dt <<= 1;
++ subk.k <<= 1;
++ }
++ }
++
++ return ret;
++}
++
++static bool netvsc_set_hash(u32 *hash, struct sk_buff *skb)
++{
++ struct iphdr *iphdr;
++ int data_len;
++ bool ret = false;
++
++ if (eth_hdr(skb)->h_proto != htons(ETH_P_IP))
++ return false;
++
++ iphdr = ip_hdr(skb);
++
++ if (iphdr->version == 4) {
++ if (iphdr->protocol == IPPROTO_TCP)
++ data_len = 12;
++ else
++ data_len = 8;
++ *hash = comp_hash(netvsc_hash_key, HASH_KEYLEN,
++ (u8 *)&iphdr->saddr, data_len);
++ ret = true;
++ }
++
++ return ret;
++}
++
++static u16 netvsc_select_queue(struct net_device *ndev, struct sk_buff *skb,
++ void *accel_priv, select_queue_fallback_t fallback)
++{
++ struct net_device_context *net_device_ctx = netdev_priv(ndev);
++ struct hv_device *hdev = net_device_ctx->device_ctx;
++ struct netvsc_device *nvsc_dev = hv_get_drvdata(hdev);
++ u32 hash;
++ u16 q_idx = 0;
++
++ if (nvsc_dev == NULL || ndev->real_num_tx_queues <= 1)
++ return 0;
++
++ if (netvsc_set_hash(&hash, skb))
++ q_idx = nvsc_dev->send_table[hash % VRSS_SEND_TAB_SIZE] %
++ ndev->real_num_tx_queues;
++
++ return q_idx;
++}
++
+ static void netvsc_xmit_completion(void *context)
+ {
+ struct hv_netvsc_packet *packet = (struct hv_netvsc_packet *)context;
+@@ -334,6 +416,8 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+
+ packet->vlan_tci = skb->vlan_tci;
+
++ packet->q_idx = skb_get_queue_mapping(skb);
++
+ packet->is_data_pkt = true;
+ packet->total_data_buflen = skb->len;
+
+@@ -559,6 +643,10 @@ int netvsc_recv_callback(struct hv_device *device_obj,
+ __vlan_hwaccel_put_tag(skb, htons(ETH_P_8021Q),
+ packet->vlan_tci);
+
++ skb_record_rx_queue(skb, packet->xfer_page_pkt->channel->
++ offermsg.offer.sub_channel_index %
++ net->real_num_rx_queues);
++
+ net->stats.rx_packets++;
+ net->stats.rx_bytes += packet->total_data_buflen;
+
+@@ -607,7 +695,7 @@ static int netvsc_change_mtu(struct net_device *ndev, int mtu)
+ hv_set_drvdata(hdev, ndev);
+ device_info.ring_size = ring_size;
+ rndis_filter_device_add(hdev, &device_info);
+- netif_wake_queue(ndev);
++ netif_tx_wake_all_queues(ndev);
+
+ return 0;
+ }
+@@ -653,6 +741,7 @@ static const struct net_device_ops device_ops = {
+ .ndo_change_mtu = netvsc_change_mtu,
+ .ndo_validate_addr = eth_validate_addr,
+ .ndo_set_mac_address = netvsc_set_mac_addr,
++ .ndo_select_queue = netvsc_select_queue,
+ };
+
+ /*
+@@ -699,9 +788,11 @@ static int netvsc_probe(struct hv_device *dev,
+ struct net_device *net = NULL;
+ struct net_device_context *net_device_ctx;
+ struct netvsc_device_info device_info;
++ struct netvsc_device *nvdev;
+ int ret;
+
+- net = alloc_etherdev(sizeof(struct net_device_context));
++ net = alloc_etherdev_mq(sizeof(struct net_device_context),
++ num_online_cpus());
+ if (!net)
+ return -ENOMEM;
+
+@@ -734,6 +825,12 @@ static int netvsc_probe(struct hv_device *dev,
+ }
+ memcpy(net->dev_addr, device_info.mac_adr, ETH_ALEN);
+
++ nvdev = hv_get_drvdata(dev);
++ netif_set_real_num_tx_queues(net, nvdev->num_chn);
++ netif_set_real_num_rx_queues(net, nvdev->num_chn);
++ dev_info(&dev->device, "real num tx,rx queues:%u, %u\n",
++ net->real_num_tx_queues, net->real_num_rx_queues);
++
+ ret = register_netdev(net);
+ if (ret != 0) {
+ pr_err("Unable to register netdev.\n");
+diff --git a/drivers/net/hyperv/rndis_filter.c b/drivers/net/hyperv/rndis_filter.c
+index 143a98caf618..d92cfbe43410 100644
+--- a/drivers/net/hyperv/rndis_filter.c
++++ b/drivers/net/hyperv/rndis_filter.c
+@@ -31,7 +31,7 @@
+ #include "hyperv_net.h"
+
+
+-#define RNDIS_EXT_LEN 100
++#define RNDIS_EXT_LEN PAGE_SIZE
+ struct rndis_request {
+ struct list_head list_ent;
+ struct completion wait_event;
+@@ -94,6 +94,8 @@ static struct rndis_request *get_rndis_request(struct rndis_device *dev,
+ rndis_msg->ndis_msg_type = msg_type;
+ rndis_msg->msg_len = msg_len;
+
++ request->pkt.q_idx = 0;
++
+ /*
+ * Set the request id. This field is always after the rndis header for
+ * request/response packet types so we just used the SetRequest as a
+@@ -509,6 +511,19 @@ static int rndis_filter_query_device(struct rndis_device *dev, u32 oid,
+ query->info_buflen = 0;
+ query->dev_vc_handle = 0;
+
++ if (oid == OID_GEN_RECEIVE_SCALE_CAPABILITIES) {
++ struct ndis_recv_scale_cap *cap;
++
++ request->request_msg.msg_len +=
++ sizeof(struct ndis_recv_scale_cap);
++ query->info_buflen = sizeof(struct ndis_recv_scale_cap);
++ cap = (struct ndis_recv_scale_cap *)((unsigned long)query +
++ query->info_buf_offset);
++ cap->hdr.type = NDIS_OBJECT_TYPE_RSS_CAPABILITIES;
++ cap->hdr.rev = NDIS_RECEIVE_SCALE_CAPABILITIES_REVISION_2;
++ cap->hdr.size = sizeof(struct ndis_recv_scale_cap);
++ }
++
+ ret = rndis_filter_send_request(dev, request);
+ if (ret != 0)
+ goto cleanup;
+@@ -695,6 +710,89 @@ cleanup:
+ return ret;
+ }
+
++u8 netvsc_hash_key[HASH_KEYLEN] = {
++ 0x6d, 0x5a, 0x56, 0xda, 0x25, 0x5b, 0x0e, 0xc2,
++ 0x41, 0x67, 0x25, 0x3d, 0x43, 0xa3, 0x8f, 0xb0,
++ 0xd0, 0xca, 0x2b, 0xcb, 0xae, 0x7b, 0x30, 0xb4,
++ 0x77, 0xcb, 0x2d, 0xa3, 0x80, 0x30, 0xf2, 0x0c,
++ 0x6a, 0x42, 0xb7, 0x3b, 0xbe, 0xac, 0x01, 0xfa
++};
++
++int rndis_filter_set_rss_param(struct rndis_device *rdev, int num_queue)
++{
++ struct net_device *ndev = rdev->net_dev->ndev;
++ struct rndis_request *request;
++ struct rndis_set_request *set;
++ struct rndis_set_complete *set_complete;
++ u32 extlen = sizeof(struct ndis_recv_scale_param) +
++ 4*ITAB_NUM + HASH_KEYLEN;
++ struct ndis_recv_scale_param *rssp;
++ u32 *itab;
++ u8 *keyp;
++ int i, t, ret;
++
++ request = get_rndis_request(
++ rdev, RNDIS_MSG_SET,
++ RNDIS_MESSAGE_SIZE(struct rndis_set_request) + extlen);
++ if (!request)
++ return -ENOMEM;
++
++ set = &request->request_msg.msg.set_req;
++ set->oid = OID_GEN_RECEIVE_SCALE_PARAMETERS;
++ set->info_buflen = extlen;
++ set->info_buf_offset = sizeof(struct rndis_set_request);
++ set->dev_vc_handle = 0;
++
++ rssp = (struct ndis_recv_scale_param *)(set + 1);
++ rssp->hdr.type = NDIS_OBJECT_TYPE_RSS_PARAMETERS;
++ rssp->hdr.rev = NDIS_RECEIVE_SCALE_PARAMETERS_REVISION_2;
++ rssp->hdr.size = sizeof(struct ndis_recv_scale_param);
++ rssp->flag = 0;
++ rssp->hashinfo = NDIS_HASH_FUNC_TOEPLITZ | NDIS_HASH_IPV4 |
++ NDIS_HASH_TCP_IPV4;
++ rssp->indirect_tabsize = 4*ITAB_NUM;
++ rssp->indirect_taboffset = sizeof(struct ndis_recv_scale_param);
++ rssp->hashkey_size = HASH_KEYLEN;
++ rssp->kashkey_offset = rssp->indirect_taboffset +
++ rssp->indirect_tabsize;
++
++ /* Set indirection table entries */
++ itab = (u32 *)(rssp + 1);
++ for (i = 0; i < ITAB_NUM; i++)
++ itab[i] = i % num_queue;
++
++ /* Set hask key values */
++ keyp = (u8 *)((unsigned long)rssp + rssp->kashkey_offset);
++ for (i = 0; i < HASH_KEYLEN; i++)
++ keyp[i] = netvsc_hash_key[i];
++
++
++ ret = rndis_filter_send_request(rdev, request);
++ if (ret != 0)
++ goto cleanup;
++
++ t = wait_for_completion_timeout(&request->wait_event, 5*HZ);
++ if (t == 0) {
++ netdev_err(ndev, "timeout before we got a set response...\n");
++ /* can't put_rndis_request, since we may still receive a
++ * send-completion.
++ */
++ return -ETIMEDOUT;
++ } else {
++ set_complete = &request->response_msg.msg.set_complete;
++ if (set_complete->status != RNDIS_STATUS_SUCCESS) {
++ netdev_err(ndev, "Fail to set RSS parameters:0x%x\n",
++ set_complete->status);
++ ret = -EINVAL;
++ }
++ }
++
++cleanup:
++ put_rndis_request(rdev, request);
++ return ret;
++}
++
++
+ static int rndis_filter_query_device_link_status(struct rndis_device *dev)
+ {
+ u32 size = sizeof(u32);
+@@ -886,6 +984,28 @@ static int rndis_filter_close_device(struct rndis_device *dev)
+ return ret;
+ }
+
++static void netvsc_sc_open(struct vmbus_channel *new_sc)
++{
++ struct netvsc_device *nvscdev;
++ u16 chn_index = new_sc->offermsg.offer.sub_channel_index;
++ int ret;
++
++ nvscdev = hv_get_drvdata(new_sc->primary_channel->device_obj);
++
++ if (chn_index >= nvscdev->num_chn)
++ return;
++
++ set_per_channel_state(new_sc, nvscdev->sub_cb_buf + (chn_index - 1) *
++ NETVSC_PACKET_SIZE);
++
++ ret = vmbus_open(new_sc, nvscdev->ring_size * PAGE_SIZE,
++ nvscdev->ring_size * PAGE_SIZE, NULL, 0,
++ netvsc_channel_cb, new_sc);
++
++ if (ret == 0)
++ nvscdev->chn_table[chn_index] = new_sc;
++}
++
+ int rndis_filter_device_add(struct hv_device *dev,
+ void *additional_info)
+ {
+@@ -894,6 +1014,10 @@ int rndis_filter_device_add(struct hv_device *dev,
+ struct rndis_device *rndis_device;
+ struct netvsc_device_info *device_info = additional_info;
+ struct ndis_offload_params offloads;
++ struct nvsp_message *init_packet;
++ int t;
++ struct ndis_recv_scale_cap rsscap;
++ u32 rsscap_size = sizeof(struct ndis_recv_scale_cap);
+
+ rndis_device = get_rndis_device();
+ if (!rndis_device)
+@@ -913,6 +1037,7 @@ int rndis_filter_device_add(struct hv_device *dev,
+
+ /* Initialize the rndis device */
+ net_device = hv_get_drvdata(dev);
++ net_device->num_chn = 1;
+
+ net_device->extension = rndis_device;
+ rndis_device->net_dev = net_device;
+@@ -952,7 +1077,6 @@ int rndis_filter_device_add(struct hv_device *dev,
+ if (ret)
+ goto err_dev_remv;
+
+-
+ rndis_filter_query_device_link_status(rndis_device);
+
+ device_info->link_state = rndis_device->link_state;
+@@ -961,7 +1085,66 @@ int rndis_filter_device_add(struct hv_device *dev,
+ rndis_device->hw_mac_adr,
+ device_info->link_state ? "down" : "up");
+
+- return ret;
++ if (net_device->nvsp_version < NVSP_PROTOCOL_VERSION_5)
++ return 0;
++
++ /* vRSS setup */
++ memset(&rsscap, 0, rsscap_size);
++ ret = rndis_filter_query_device(rndis_device,
++ OID_GEN_RECEIVE_SCALE_CAPABILITIES,
++ &rsscap, &rsscap_size);
++ if (ret || rsscap.num_recv_que < 2)
++ goto out;
++
++ net_device->num_chn = (num_online_cpus() < rsscap.num_recv_que) ?
++ num_online_cpus() : rsscap.num_recv_que;
++ if (net_device->num_chn == 1)
++ goto out;
++
++ net_device->sub_cb_buf = vzalloc((net_device->num_chn - 1) *
++ NETVSC_PACKET_SIZE);
++ if (!net_device->sub_cb_buf) {
++ net_device->num_chn = 1;
++ dev_info(&dev->device, "No memory for subchannels.\n");
++ goto out;
++ }
++
++ vmbus_set_sc_create_callback(dev->channel, netvsc_sc_open);
++
++ init_packet = &net_device->channel_init_pkt;
++ memset(init_packet, 0, sizeof(struct nvsp_message));
++ init_packet->hdr.msg_type = NVSP_MSG5_TYPE_SUBCHANNEL;
++ init_packet->msg.v5_msg.subchn_req.op = NVSP_SUBCHANNEL_ALLOCATE;
++ init_packet->msg.v5_msg.subchn_req.num_subchannels =
++ net_device->num_chn - 1;
++ ret = vmbus_sendpacket(dev->channel, init_packet,
++ sizeof(struct nvsp_message),
++ (unsigned long)init_packet,
++ VM_PKT_DATA_INBAND,
++ VMBUS_DATA_PACKET_FLAG_COMPLETION_REQUESTED);
++ if (ret)
++ goto out;
++ t = wait_for_completion_timeout(&net_device->channel_init_wait, 5*HZ);
++ if (t == 0) {
++ ret = -ETIMEDOUT;
++ goto out;
++ }
++ if (init_packet->msg.v5_msg.subchn_comp.status !=
++ NVSP_STAT_SUCCESS) {
++ ret = -ENODEV;
++ goto out;
++ }
++ net_device->num_chn = 1 +
++ init_packet->msg.v5_msg.subchn_comp.num_subchannels;
++
++ vmbus_are_subchannels_present(dev->channel);
++
++ ret = rndis_filter_set_rss_param(rndis_device, net_device->num_chn);
++
++out:
++ if (ret)
++ net_device->num_chn = 1;
++ return 0; /* return 0 because primary channel can be used alone */
+
+ err_dev_remv:
+ rndis_filter_device_remove(dev);
+--
+2.4.3
+
--- /dev/null
+From d6bf5567c1438b4f3b1bcff1a1525ddb1754df19 Mon Sep 17 00:00:00 2001
+From: Haiyang Zhang <haiyangz@microsoft.com>
+Date: Mon, 21 Apr 2014 14:54:43 -0700
+Subject: [PATCH 17/25] hyperv: Remove recv_pkt_list and lock
+
+Removed recv_pkt_list and lock, and updated related code, so that
+the locking overhead is reduced especially when multiple channels
+are in use.
+
+The recv_pkt_list isn't actually necessary because the packets are
+processed sequentially in each channel. It has been replaced by a
+local variable, and the related lock for this list is also removed.
+The is_data_pkt field is not used in receive path, so its assignment
+is cleaned up.
+
+Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
+Reviewed-by: K. Y. Srinivasan <kys@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 33 --------
+ drivers/net/hyperv/netvsc.c | 174 +++-----------------------------------
+ drivers/net/hyperv/netvsc_drv.c | 2 +-
+ drivers/net/hyperv/rndis_filter.c | 2 -
+ 4 files changed, 13 insertions(+), 198 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index 57eb3f906d64..a1af0f7711e2 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -119,27 +119,14 @@ struct ndis_recv_scale_param { /* NDIS_RECEIVE_SCALE_PARAMETERS */
+ };
+
+ /* Fwd declaration */
+-struct hv_netvsc_packet;
+ struct ndis_tcp_ip_checksum_info;
+
+-/* Represent the xfer page packet which contains 1 or more netvsc packet */
+-struct xferpage_packet {
+- struct list_head list_ent;
+- u32 status;
+-
+- /* # of netvsc packets this xfer packet contains */
+- u32 count;
+-
+- struct vmbus_channel *channel;
+-};
+-
+ /*
+ * Represent netvsc packet which contains 1 RNDIS and 1 ethernet frame
+ * within the RNDIS
+ */
+ struct hv_netvsc_packet {
+ /* Bookkeeping stuff */
+- struct list_head list_ent;
+ u32 status;
+
+ struct hv_device *device;
+@@ -149,19 +136,8 @@ struct hv_netvsc_packet {
+ u16 q_idx;
+ struct vmbus_channel *channel;
+
+- /*
+- * Valid only for receives when we break a xfer page packet
+- * into multiple netvsc packets
+- */
+- struct xferpage_packet *xfer_page_pkt;
+-
+ union {
+ struct {
+- u64 recv_completion_tid;
+- void *recv_completion_ctx;
+- void (*recv_completion)(void *context);
+- } recv;
+- struct {
+ u64 send_completion_tid;
+ void *send_completion_ctx;
+ void (*send_completion)(void *context);
+@@ -613,9 +589,6 @@ struct nvsp_message {
+
+ #define NETVSC_RECEIVE_BUFFER_ID 0xcafe
+
+-/* Preallocated receive packets */
+-#define NETVSC_RECEIVE_PACKETLIST_COUNT 256
+-
+ #define NETVSC_PACKET_SIZE 2048
+
+ #define VRSS_SEND_TAB_SIZE 16
+@@ -630,12 +603,6 @@ struct netvsc_device {
+ wait_queue_head_t wait_drain;
+ bool start_remove;
+ bool destroy;
+- /*
+- * List of free preallocated hv_netvsc_packet to represent receive
+- * packet
+- */
+- struct list_head recv_pkt_list;
+- spinlock_t recv_pkt_list_lock;
+
+ /* Receive buffer allocated by us but manages by NetVSP */
+ void *recv_buf;
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index e7e77f12bc38..b10334773b32 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -387,7 +387,6 @@ static void netvsc_disconnect_vsp(struct netvsc_device *net_device)
+ int netvsc_device_remove(struct hv_device *device)
+ {
+ struct netvsc_device *net_device;
+- struct hv_netvsc_packet *netvsc_packet, *pos;
+ unsigned long flags;
+
+ net_device = hv_get_drvdata(device);
+@@ -416,12 +415,6 @@ int netvsc_device_remove(struct hv_device *device)
+ vmbus_close(device->channel);
+
+ /* Release all resources */
+- list_for_each_entry_safe(netvsc_packet, pos,
+- &net_device->recv_pkt_list, list_ent) {
+- list_del(&netvsc_packet->list_ent);
+- kfree(netvsc_packet);
+- }
+-
+ if (net_device->sub_cb_buf)
+ vfree(net_device->sub_cb_buf);
+
+@@ -641,62 +634,6 @@ retry_send_cmplt:
+ }
+ }
+
+-/* Send a receive completion packet to RNDIS device (ie NetVsp) */
+-static void netvsc_receive_completion(void *context)
+-{
+- struct hv_netvsc_packet *packet = context;
+- struct hv_device *device = packet->device;
+- struct vmbus_channel *channel;
+- struct netvsc_device *net_device;
+- u64 transaction_id = 0;
+- bool fsend_receive_comp = false;
+- unsigned long flags;
+- struct net_device *ndev;
+- u32 status = NVSP_STAT_NONE;
+-
+- /*
+- * Even though it seems logical to do a GetOutboundNetDevice() here to
+- * send out receive completion, we are using GetInboundNetDevice()
+- * since we may have disable outbound traffic already.
+- */
+- net_device = get_inbound_net_device(device);
+- if (!net_device)
+- return;
+- ndev = net_device->ndev;
+-
+- /* Overloading use of the lock. */
+- spin_lock_irqsave(&net_device->recv_pkt_list_lock, flags);
+-
+- if (packet->status != NVSP_STAT_SUCCESS)
+- packet->xfer_page_pkt->status = NVSP_STAT_FAIL;
+-
+- packet->xfer_page_pkt->count--;
+-
+- /*
+- * Last one in the line that represent 1 xfer page packet.
+- * Return the xfer page packet itself to the freelist
+- */
+- if (packet->xfer_page_pkt->count == 0) {
+- fsend_receive_comp = true;
+- channel = packet->xfer_page_pkt->channel;
+- transaction_id = packet->completion.recv.recv_completion_tid;
+- status = packet->xfer_page_pkt->status;
+- list_add_tail(&packet->xfer_page_pkt->list_ent,
+- &net_device->recv_pkt_list);
+-
+- }
+-
+- /* Put the packet back */
+- list_add_tail(&packet->list_ent, &net_device->recv_pkt_list);
+- spin_unlock_irqrestore(&net_device->recv_pkt_list_lock, flags);
+-
+- /* Send a receive completion for the xfer page packet */
+- if (fsend_receive_comp)
+- netvsc_send_recv_completion(device, channel, net_device,
+- transaction_id, status);
+-
+-}
+-
+ static void netvsc_receive(struct netvsc_device *net_device,
+ struct vmbus_channel *channel,
+ struct hv_device *device,
+@@ -704,16 +641,13 @@ static void netvsc_receive(struct netvsc_device *net_device,
+ {
+ struct vmtransfer_page_packet_header *vmxferpage_packet;
+ struct nvsp_message *nvsp_packet;
+- struct hv_netvsc_packet *netvsc_packet = NULL;
+- /* struct netvsc_driver *netvscDriver; */
+- struct xferpage_packet *xferpage_packet = NULL;
++ struct hv_netvsc_packet nv_pkt;
++ struct hv_netvsc_packet *netvsc_packet = &nv_pkt;
++ u32 status = NVSP_STAT_SUCCESS;
+ int i;
+ int count = 0;
+- unsigned long flags;
+ struct net_device *ndev;
+
+- LIST_HEAD(listHead);
+-
+ ndev = net_device->ndev;
+
+ /*
+@@ -746,78 +680,14 @@ static void netvsc_receive(struct netvsc_device *net_device,
+ return;
+ }
+
+- /*
+- * Grab free packets (range count + 1) to represent this xfer
+- * page packet. +1 to represent the xfer page packet itself.
+- * We grab it here so that we know exactly how many we can
+- * fulfil
+- */
+- spin_lock_irqsave(&net_device->recv_pkt_list_lock, flags);
+- while (!list_empty(&net_device->recv_pkt_list)) {
+- list_move_tail(net_device->recv_pkt_list.next, &listHead);
+- if (++count == vmxferpage_packet->range_cnt + 1)
+- break;
+- }
+- spin_unlock_irqrestore(&net_device->recv_pkt_list_lock, flags);
+-
+- /*
+- * We need at least 2 netvsc pkts (1 to represent the xfer
+- * page and at least 1 for the range) i.e. we can handled
+- * some of the xfer page packet ranges...
+- */
+- if (count < 2) {
+- netdev_err(ndev, "Got only %d netvsc pkt...needed "
+- "%d pkts. Dropping this xfer page packet completely!\n",
+- count, vmxferpage_packet->range_cnt + 1);
+-
+- /* Return it to the freelist */
+- spin_lock_irqsave(&net_device->recv_pkt_list_lock, flags);
+- for (i = count; i != 0; i--) {
+- list_move_tail(listHead.next,
+- &net_device->recv_pkt_list);
+- }
+- spin_unlock_irqrestore(&net_device->recv_pkt_list_lock,
+- flags);
+-
+- netvsc_send_recv_completion(device, channel, net_device,
+- vmxferpage_packet->d.trans_id,
+- NVSP_STAT_FAIL);
+-
+- return;
+- }
+-
+- /* Remove the 1st packet to represent the xfer page packet itself */
+- xferpage_packet = (struct xferpage_packet *)listHead.next;
+- list_del(&xferpage_packet->list_ent);
+- xferpage_packet->status = NVSP_STAT_SUCCESS;
+- xferpage_packet->channel = channel;
+-
+- /* This is how much we can satisfy */
+- xferpage_packet->count = count - 1;
+-
+- if (xferpage_packet->count != vmxferpage_packet->range_cnt) {
+- netdev_err(ndev, "Needed %d netvsc pkts to satisfy "
+- "this xfer page...got %d\n",
+- vmxferpage_packet->range_cnt, xferpage_packet->count);
+- }
++ count = vmxferpage_packet->range_cnt;
++ netvsc_packet->device = device;
++ netvsc_packet->channel = channel;
+
+ /* Each range represents 1 RNDIS pkt that contains 1 ethernet frame */
+- for (i = 0; i < (count - 1); i++) {
+- netvsc_packet = (struct hv_netvsc_packet *)listHead.next;
+- list_del(&netvsc_packet->list_ent);
+-
++ for (i = 0; i < count; i++) {
+ /* Initialize the netvsc packet */
+ netvsc_packet->status = NVSP_STAT_SUCCESS;
+- netvsc_packet->xfer_page_pkt = xferpage_packet;
+- netvsc_packet->completion.recv.recv_completion =
+- netvsc_receive_completion;
+- netvsc_packet->completion.recv.recv_completion_ctx =
+- netvsc_packet;
+- netvsc_packet->device = device;
+- /* Save this so that we can send it back */
+- netvsc_packet->completion.recv.recv_completion_tid =
+- vmxferpage_packet->d.trans_id;
+-
+ netvsc_packet->data = (void *)((unsigned long)net_device->
+ recv_buf + vmxferpage_packet->ranges[i].byte_offset);
+ netvsc_packet->total_data_buflen =
+@@ -826,10 +696,12 @@ static void netvsc_receive(struct netvsc_device *net_device,
+ /* Pass it to the upper layer */
+ rndis_filter_receive(device, netvsc_packet);
+
+- netvsc_receive_completion(netvsc_packet->
+- completion.recv.recv_completion_ctx);
++ if (netvsc_packet->status != NVSP_STAT_SUCCESS)
++ status = NVSP_STAT_FAIL;
+ }
+
++ netvsc_send_recv_completion(device, channel, net_device,
++ vmxferpage_packet->d.trans_id, status);
+ }
+
+
+@@ -956,11 +828,9 @@ void netvsc_channel_cb(void *context)
+ int netvsc_device_add(struct hv_device *device, void *additional_info)
+ {
+ int ret = 0;
+- int i;
+ int ring_size =
+ ((struct netvsc_device_info *)additional_info)->ring_size;
+ struct netvsc_device *net_device;
+- struct hv_netvsc_packet *packet, *pos;
+ struct net_device *ndev;
+
+ net_device = alloc_net_device(device);
+@@ -981,18 +851,6 @@ int netvsc_device_add(struct hv_device *device, void *additional_info)
+ ndev = net_device->ndev;
+
+ /* Initialize the NetVSC channel extension */
+- spin_lock_init(&net_device->recv_pkt_list_lock);
+-
+- INIT_LIST_HEAD(&net_device->recv_pkt_list);
+-
+- for (i = 0; i < NETVSC_RECEIVE_PACKETLIST_COUNT; i++) {
+- packet = kzalloc(sizeof(struct hv_netvsc_packet), GFP_KERNEL);
+- if (!packet)
+- break;
+-
+- list_add_tail(&packet->list_ent,
+- &net_device->recv_pkt_list);
+- }
+ init_completion(&net_device->channel_init_wait);
+
+ set_per_channel_state(device->channel, net_device->cb_buffer);
+@@ -1028,16 +886,8 @@ close:
+
+ cleanup:
+
+- if (net_device) {
+- list_for_each_entry_safe(packet, pos,
+- &net_device->recv_pkt_list,
+- list_ent) {
+- list_del(&packet->list_ent);
+- kfree(packet);
+- }
+-
++ if (net_device)
+ kfree(net_device);
+- }
+
+ return ret;
+ }
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index e486dbd33f61..6cc4db064fec 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -643,7 +643,7 @@ int netvsc_recv_callback(struct hv_device *device_obj,
+ __vlan_hwaccel_put_tag(skb, htons(ETH_P_8021Q),
+ packet->vlan_tci);
+
+- skb_record_rx_queue(skb, packet->xfer_page_pkt->channel->
++ skb_record_rx_queue(skb, packet->channel->
+ offermsg.offer.sub_channel_index %
+ net->real_num_rx_queues);
+
+diff --git a/drivers/net/hyperv/rndis_filter.c b/drivers/net/hyperv/rndis_filter.c
+index d92cfbe43410..48f5a0fbd674 100644
+--- a/drivers/net/hyperv/rndis_filter.c
++++ b/drivers/net/hyperv/rndis_filter.c
+@@ -401,8 +401,6 @@ static void rndis_filter_receive_data(struct rndis_device *dev,
+ pkt->total_data_buflen = rndis_pkt->data_len;
+ pkt->data = (void *)((unsigned long)pkt->data + data_offset);
+
+- pkt->is_data_pkt = true;
+-
+ vlan = rndis_get_ppi(rndis_pkt, IEEE_8021Q_INFO);
+ if (vlan) {
+ pkt->vlan_tci = VLAN_TAG_PRESENT | vlan->vlanid |
+--
+2.4.3
+
--- /dev/null
+From d6eeeb452c1e6e7cf14f4a581a8f2ea2c50ec17a Mon Sep 17 00:00:00 2001
+From: Haiyang Zhang <haiyangz@microsoft.com>
+Date: Mon, 21 Apr 2014 14:54:44 -0700
+Subject: [PATCH 18/25] hyperv: Simplify the send_completion variables
+
+The union contains only one member now, so we use the variables in it directly.
+
+Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
+Reviewed-by: K. Y. Srinivasan <kys@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 10 +++-------
+ drivers/net/hyperv/netvsc.c | 7 +++----
+ drivers/net/hyperv/netvsc_drv.c | 8 ++++----
+ drivers/net/hyperv/rndis_filter.c | 2 +-
+ 4 files changed, 11 insertions(+), 16 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index a1af0f7711e2..d1f7826aa75f 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -136,13 +136,9 @@ struct hv_netvsc_packet {
+ u16 q_idx;
+ struct vmbus_channel *channel;
+
+- union {
+- struct {
+- u64 send_completion_tid;
+- void *send_completion_ctx;
+- void (*send_completion)(void *context);
+- } send;
+- } completion;
++ u64 send_completion_tid;
++ void *send_completion_ctx;
++ void (*send_completion)(void *context);
+
+ /* This points to the memory after page_buf */
+ struct rndis_message *rndis_msg;
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index b10334773b32..bbee44635035 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -479,9 +479,8 @@ static void netvsc_send_completion(struct netvsc_device *net_device,
+ if (nvsc_packet) {
+ q_idx = nvsc_packet->q_idx;
+ channel = nvsc_packet->channel;
+- nvsc_packet->completion.send.send_completion(
+- nvsc_packet->completion.send.
+- send_completion_ctx);
++ nvsc_packet->send_completion(nvsc_packet->
++ send_completion_ctx);
+ }
+
+ num_outstanding_sends =
+@@ -534,7 +533,7 @@ int netvsc_send(struct hv_device *device,
+ 0xFFFFFFFF;
+ sendMessage.msg.v1_msg.send_rndis_pkt.send_buf_section_size = 0;
+
+- if (packet->completion.send.send_completion)
++ if (packet->send_completion)
+ req_id = (ulong)packet;
+ else
+ req_id = 0;
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 6cc4db064fec..f3d3525ed42d 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -235,7 +235,7 @@ static void netvsc_xmit_completion(void *context)
+ {
+ struct hv_netvsc_packet *packet = (struct hv_netvsc_packet *)context;
+ struct sk_buff *skb = (struct sk_buff *)
+- (unsigned long)packet->completion.send.send_completion_tid;
++ (unsigned long)packet->send_completion_tid;
+
+ kfree(packet);
+
+@@ -426,9 +426,9 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ (num_data_pgs * sizeof(struct hv_page_buffer)));
+
+ /* Set the completion routine */
+- packet->completion.send.send_completion = netvsc_xmit_completion;
+- packet->completion.send.send_completion_ctx = packet;
+- packet->completion.send.send_completion_tid = (unsigned long)skb;
++ packet->send_completion = netvsc_xmit_completion;
++ packet->send_completion_ctx = packet;
++ packet->send_completion_tid = (unsigned long)skb;
+
+ isvlan = packet->vlan_tci & VLAN_TAG_PRESENT;
+
+diff --git a/drivers/net/hyperv/rndis_filter.c b/drivers/net/hyperv/rndis_filter.c
+index 48f5a0fbd674..99c527adae5b 100644
+--- a/drivers/net/hyperv/rndis_filter.c
++++ b/drivers/net/hyperv/rndis_filter.c
+@@ -236,7 +236,7 @@ static int rndis_filter_send_request(struct rndis_device *dev,
+ packet->page_buf[0].len;
+ }
+
+- packet->completion.send.send_completion = NULL;
++ packet->send_completion = NULL;
+
+ ret = netvsc_send(dev->net_dev->dev, packet);
+ return ret;
+--
+2.4.3
+
--- /dev/null
+From 4685e50349d5dc5fe485c898ca3ce539e93a0118 Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Wed, 30 Apr 2014 10:14:31 -0700
+Subject: [PATCH 19/25] hyperv: Enable sendbuf mechanism on the send path
+
+We send packets using a copy-free mechanism (this is the Guest to Host transport
+via VMBUS). While this is obviously optimal for large packets,
+it may not be optimal for small packets. Hyper-V host supports
+a second mechanism for sending packets that is "copy based". We implement that
+mechanism in this patch.
+
+In this version of the patch I have addressed a comment from David Miller.
+
+With this patch (and all of the other offload and VRSS patches), we are now able
+to almost saturate a 10G interface between Linux VMs on Hyper-V
+on different hosts - close to 9 Gbps as measured via iperf.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 14 +++
+ drivers/net/hyperv/netvsc.c | 226 ++++++++++++++++++++++++++++++++++++++--
+ drivers/net/hyperv/netvsc_drv.c | 3 +-
+ 3 files changed, 234 insertions(+), 9 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index d1f7826aa75f..4b7df5a5c966 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -140,6 +140,8 @@ struct hv_netvsc_packet {
+ void *send_completion_ctx;
+ void (*send_completion)(void *context);
+
++ u32 send_buf_index;
++
+ /* This points to the memory after page_buf */
+ struct rndis_message *rndis_msg;
+
+@@ -582,6 +584,9 @@ struct nvsp_message {
+
+ #define NETVSC_RECEIVE_BUFFER_SIZE (1024*1024*16) /* 16MB */
+ #define NETVSC_RECEIVE_BUFFER_SIZE_LEGACY (1024*1024*15) /* 15MB */
++#define NETVSC_SEND_BUFFER_SIZE (1024 * 1024) /* 1MB */
++#define NETVSC_INVALID_INDEX -1
++
+
+ #define NETVSC_RECEIVE_BUFFER_ID 0xcafe
+
+@@ -607,6 +612,15 @@ struct netvsc_device {
+ u32 recv_section_cnt;
+ struct nvsp_1_receive_buffer_section *recv_section;
+
++ /* Send buffer allocated by us */
++ void *send_buf;
++ u32 send_buf_size;
++ u32 send_buf_gpadl_handle;
++ u32 send_section_cnt;
++ u32 send_section_size;
++ unsigned long *send_section_map;
++ int map_words;
++
+ /* Used for NetVSP initialization protocol */
+ struct completion channel_init_wait;
+ struct nvsp_message channel_init_pkt;
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index bbee44635035..c041f63a6d30 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -28,6 +28,7 @@
+ #include <linux/slab.h>
+ #include <linux/netdevice.h>
+ #include <linux/if_ether.h>
++#include <asm/sync_bitops.h>
+
+ #include "hyperv_net.h"
+
+@@ -80,7 +81,7 @@ get_in_err:
+ }
+
+
+-static int netvsc_destroy_recv_buf(struct netvsc_device *net_device)
++static int netvsc_destroy_buf(struct netvsc_device *net_device)
+ {
+ struct nvsp_message *revoke_packet;
+ int ret = 0;
+@@ -146,10 +147,62 @@ static int netvsc_destroy_recv_buf(struct netvsc_device *net_device)
+ net_device->recv_section = NULL;
+ }
+
++ /* Deal with the send buffer we may have setup.
++ * If we got a send section size, it means we received a
++ * SendsendBufferComplete msg (ie sent
++ * NvspMessage1TypeSendReceiveBuffer msg) therefore, we need
++ * to send a revoke msg here
++ */
++ if (net_device->send_section_size) {
++ /* Send the revoke receive buffer */
++ revoke_packet = &net_device->revoke_packet;
++ memset(revoke_packet, 0, sizeof(struct nvsp_message));
++
++ revoke_packet->hdr.msg_type =
++ NVSP_MSG1_TYPE_REVOKE_SEND_BUF;
++ revoke_packet->msg.v1_msg.revoke_recv_buf.id = 0;
++
++ ret = vmbus_sendpacket(net_device->dev->channel,
++ revoke_packet,
++ sizeof(struct nvsp_message),
++ (unsigned long)revoke_packet,
++ VM_PKT_DATA_INBAND, 0);
++ /* If we failed here, we might as well return and
++ * have a leak rather than continue and a bugchk
++ */
++ if (ret != 0) {
++ netdev_err(ndev, "unable to send "
++ "revoke send buffer to netvsp\n");
++ return ret;
++ }
++ }
++ /* Teardown the gpadl on the vsp end */
++ if (net_device->send_buf_gpadl_handle) {
++ ret = vmbus_teardown_gpadl(net_device->dev->channel,
++ net_device->send_buf_gpadl_handle);
++
++ /* If we failed here, we might as well return and have a leak
++ * rather than continue and a bugchk
++ */
++ if (ret != 0) {
++ netdev_err(ndev,
++ "unable to teardown send buffer's gpadl\n");
++ return ret;
++ }
++ net_device->recv_buf_gpadl_handle = 0;
++ }
++ if (net_device->send_buf) {
++ /* Free up the receive buffer */
++ free_pages((unsigned long)net_device->send_buf,
++ get_order(net_device->send_buf_size));
++ net_device->send_buf = NULL;
++ }
++ kfree(net_device->send_section_map);
++
+ return ret;
+ }
+
+-static int netvsc_init_recv_buf(struct hv_device *device)
++static int netvsc_init_buf(struct hv_device *device)
+ {
+ int ret = 0;
+ int t;
+@@ -248,10 +301,90 @@ static int netvsc_init_recv_buf(struct hv_device *device)
+ goto cleanup;
+ }
+
++ /* Now setup the send buffer.
++ */
++ net_device->send_buf =
++ (void *)__get_free_pages(GFP_KERNEL|__GFP_ZERO,
++ get_order(net_device->send_buf_size));
++ if (!net_device->send_buf) {
++ netdev_err(ndev, "unable to allocate send "
++ "buffer of size %d\n", net_device->send_buf_size);
++ ret = -ENOMEM;
++ goto cleanup;
++ }
++
++ /* Establish the gpadl handle for this buffer on this
++ * channel. Note: This call uses the vmbus connection rather
++ * than the channel to establish the gpadl handle.
++ */
++ ret = vmbus_establish_gpadl(device->channel, net_device->send_buf,
++ net_device->send_buf_size,
++ &net_device->send_buf_gpadl_handle);
++ if (ret != 0) {
++ netdev_err(ndev,
++ "unable to establish send buffer's gpadl\n");
++ goto cleanup;
++ }
++
++ /* Notify the NetVsp of the gpadl handle */
++ init_packet = &net_device->channel_init_pkt;
++ memset(init_packet, 0, sizeof(struct nvsp_message));
++ init_packet->hdr.msg_type = NVSP_MSG1_TYPE_SEND_SEND_BUF;
++ init_packet->msg.v1_msg.send_recv_buf.gpadl_handle =
++ net_device->send_buf_gpadl_handle;
++ init_packet->msg.v1_msg.send_recv_buf.id = 0;
++
++ /* Send the gpadl notification request */
++ ret = vmbus_sendpacket(device->channel, init_packet,
++ sizeof(struct nvsp_message),
++ (unsigned long)init_packet,
++ VM_PKT_DATA_INBAND,
++ VMBUS_DATA_PACKET_FLAG_COMPLETION_REQUESTED);
++ if (ret != 0) {
++ netdev_err(ndev,
++ "unable to send send buffer's gpadl to netvsp\n");
++ goto cleanup;
++ }
++
++ t = wait_for_completion_timeout(&net_device->channel_init_wait, 5*HZ);
++ BUG_ON(t == 0);
++
++ /* Check the response */
++ if (init_packet->msg.v1_msg.
++ send_send_buf_complete.status != NVSP_STAT_SUCCESS) {
++ netdev_err(ndev, "Unable to complete send buffer "
++ "initialization with NetVsp - status %d\n",
++ init_packet->msg.v1_msg.
++ send_recv_buf_complete.status);
++ ret = -EINVAL;
++ goto cleanup;
++ }
++
++ /* Parse the response */
++ net_device->send_section_size = init_packet->msg.
++ v1_msg.send_send_buf_complete.section_size;
++
++ /* Section count is simply the size divided by the section size.
++ */
++ net_device->send_section_cnt =
++ net_device->send_buf_size/net_device->send_section_size;
++
++ dev_info(&device->device, "Send section size: %d, Section count:%d\n",
++ net_device->send_section_size, net_device->send_section_cnt);
++
++ /* Setup state for managing the send buffer. */
++ net_device->map_words = DIV_ROUND_UP(net_device->send_section_cnt,
++ BITS_PER_LONG);
++
++ net_device->send_section_map =
++ kzalloc(net_device->map_words * sizeof(ulong), GFP_KERNEL);
++ if (net_device->send_section_map == NULL)
++ goto cleanup;
++
+ goto exit;
+
+ cleanup:
+- netvsc_destroy_recv_buf(net_device);
++ netvsc_destroy_buf(net_device);
+
+ exit:
+ return ret;
+@@ -369,8 +502,9 @@ static int netvsc_connect_vsp(struct hv_device *device)
+ net_device->recv_buf_size = NETVSC_RECEIVE_BUFFER_SIZE_LEGACY;
+ else
+ net_device->recv_buf_size = NETVSC_RECEIVE_BUFFER_SIZE;
++ net_device->send_buf_size = NETVSC_SEND_BUFFER_SIZE;
+
+- ret = netvsc_init_recv_buf(device);
++ ret = netvsc_init_buf(device);
+
+ cleanup:
+ return ret;
+@@ -378,7 +512,7 @@ cleanup:
+
+ static void netvsc_disconnect_vsp(struct netvsc_device *net_device)
+ {
+- netvsc_destroy_recv_buf(net_device);
++ netvsc_destroy_buf(net_device);
+ }
+
+ /*
+@@ -440,6 +574,12 @@ static inline u32 hv_ringbuf_avail_percent(
+ return avail_write * 100 / ring_info->ring_datasize;
+ }
+
++static inline void netvsc_free_send_slot(struct netvsc_device *net_device,
++ u32 index)
++{
++ sync_change_bit(index, net_device->send_section_map);
++}
++
+ static void netvsc_send_completion(struct netvsc_device *net_device,
+ struct hv_device *device,
+ struct vmpacket_descriptor *packet)
+@@ -447,6 +587,7 @@ static void netvsc_send_completion(struct netvsc_device *net_device,
+ struct nvsp_message *nvsp_packet;
+ struct hv_netvsc_packet *nvsc_packet;
+ struct net_device *ndev;
++ u32 send_index;
+
+ ndev = net_device->ndev;
+
+@@ -477,6 +618,9 @@ static void netvsc_send_completion(struct netvsc_device *net_device,
+
+ /* Notify the layer above us */
+ if (nvsc_packet) {
++ send_index = nvsc_packet->send_buf_index;
++ if (send_index != NETVSC_INVALID_INDEX)
++ netvsc_free_send_slot(net_device, send_index);
+ q_idx = nvsc_packet->q_idx;
+ channel = nvsc_packet->channel;
+ nvsc_packet->send_completion(nvsc_packet->
+@@ -504,6 +648,52 @@ static void netvsc_send_completion(struct netvsc_device *net_device,
+
+ }
+
++static u32 netvsc_get_next_send_section(struct netvsc_device *net_device)
++{
++ unsigned long index;
++ u32 max_words = net_device->map_words;
++ unsigned long *map_addr = (unsigned long *)net_device->send_section_map;
++ u32 section_cnt = net_device->send_section_cnt;
++ int ret_val = NETVSC_INVALID_INDEX;
++ int i;
++ int prev_val;
++
++ for (i = 0; i < max_words; i++) {
++ if (!~(map_addr[i]))
++ continue;
++ index = ffz(map_addr[i]);
++ prev_val = sync_test_and_set_bit(index, &map_addr[i]);
++ if (prev_val)
++ continue;
++ if ((index + (i * BITS_PER_LONG)) >= section_cnt)
++ break;
++ ret_val = (index + (i * BITS_PER_LONG));
++ break;
++ }
++ return ret_val;
++}
++
++u32 netvsc_copy_to_send_buf(struct netvsc_device *net_device,
++ unsigned int section_index,
++ struct hv_netvsc_packet *packet)
++{
++ char *start = net_device->send_buf;
++ char *dest = (start + (section_index * net_device->send_section_size));
++ int i;
++ u32 msg_size = 0;
++
++ for (i = 0; i < packet->page_buf_cnt; i++) {
++ char *src = phys_to_virt(packet->page_buf[i].pfn << PAGE_SHIFT);
++ u32 offset = packet->page_buf[i].offset;
++ u32 len = packet->page_buf[i].len;
++
++ memcpy(dest, (src + offset), len);
++ msg_size += len;
++ dest += len;
++ }
++ return msg_size;
++}
++
+ int netvsc_send(struct hv_device *device,
+ struct hv_netvsc_packet *packet)
+ {
+@@ -513,6 +703,10 @@ int netvsc_send(struct hv_device *device,
+ struct net_device *ndev;
+ struct vmbus_channel *out_channel = NULL;
+ u64 req_id;
++ unsigned int section_index = NETVSC_INVALID_INDEX;
++ u32 msg_size = 0;
++ struct sk_buff *skb;
++
+
+ net_device = get_outbound_net_device(device);
+ if (!net_device)
+@@ -528,10 +722,26 @@ int netvsc_send(struct hv_device *device,
+ sendMessage.msg.v1_msg.send_rndis_pkt.channel_type = 1;
+ }
+
+- /* Not using send buffer section */
++ /* Attempt to send via sendbuf */
++ if (packet->total_data_buflen < net_device->send_section_size) {
++ section_index = netvsc_get_next_send_section(net_device);
++ if (section_index != NETVSC_INVALID_INDEX) {
++ msg_size = netvsc_copy_to_send_buf(net_device,
++ section_index,
++ packet);
++ skb = (struct sk_buff *)
++ (unsigned long)packet->send_completion_tid;
++ if (skb)
++ dev_kfree_skb_any(skb);
++ packet->page_buf_cnt = 0;
++ }
++ }
++ packet->send_buf_index = section_index;
++
++
+ sendMessage.msg.v1_msg.send_rndis_pkt.send_buf_section_index =
+- 0xFFFFFFFF;
+- sendMessage.msg.v1_msg.send_rndis_pkt.send_buf_section_size = 0;
++ section_index;
++ sendMessage.msg.v1_msg.send_rndis_pkt.send_buf_section_size = msg_size;
+
+ if (packet->send_completion)
+ req_id = (ulong)packet;
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index f3d3525ed42d..9a19aa5672e6 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -236,10 +236,11 @@ static void netvsc_xmit_completion(void *context)
+ struct hv_netvsc_packet *packet = (struct hv_netvsc_packet *)context;
+ struct sk_buff *skb = (struct sk_buff *)
+ (unsigned long)packet->send_completion_tid;
++ u32 index = packet->send_buf_index;
+
+ kfree(packet);
+
+- if (skb)
++ if (skb && (index == NETVSC_INVALID_INDEX))
+ dev_kfree_skb_any(skb);
+ }
+
+--
+2.4.3
+
--- /dev/null
+From 3f0b77385356301cf4718a94f76a4068588ecb8e Mon Sep 17 00:00:00 2001
+From: Haiyang Zhang <haiyangz@microsoft.com>
+Date: Thu, 8 May 2014 15:14:10 -0700
+Subject: [PATCH 20/25] Add support for netvsc build without CONFIG_SYSFS flag
+
+This change ensures the driver can be built successfully without the
+CONFIG_SYSFS flag.
+MS-TFS: 182270
+
+Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
+Reviewed-by: K. Y. Srinivasan <kys@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/netvsc_drv.c | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 9a19aa5672e6..346f1aeb9c24 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -645,8 +645,7 @@ int netvsc_recv_callback(struct hv_device *device_obj,
+ packet->vlan_tci);
+
+ skb_record_rx_queue(skb, packet->channel->
+- offermsg.offer.sub_channel_index %
+- net->real_num_rx_queues);
++ offermsg.offer.sub_channel_index);
+
+ net->stats.rx_packets++;
+ net->stats.rx_bytes += packet->total_data_buflen;
+@@ -829,8 +828,6 @@ static int netvsc_probe(struct hv_device *dev,
+ nvdev = hv_get_drvdata(dev);
+ netif_set_real_num_tx_queues(net, nvdev->num_chn);
+ netif_set_real_num_rx_queues(net, nvdev->num_chn);
+- dev_info(&dev->device, "real num tx,rx queues:%u, %u\n",
+- net->real_num_tx_queues, net->real_num_rx_queues);
+
+ ret = register_netdev(net);
+ if (ret != 0) {
+--
+2.4.3
+
--- /dev/null
+From 1267d9b235e7612f8cdfa842a0433bb82e75f7fb Mon Sep 17 00:00:00 2001
+From: Haiyang Zhang <haiyangz@microsoft.com>
+Date: Wed, 21 May 2014 12:55:39 -0700
+Subject: [PATCH 21/25] hyperv: Add hash value into RNDIS Per-packet info
+
+It passes the hash value as the RNDIS Per-packet info to the Hyper-V host,
+so that the send completion notices can be spread across multiple channels.
+MS-TFS: 140273
+
+Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/hyperv_net.h | 4 ++++
+ drivers/net/hyperv/netvsc_drv.c | 18 ++++++++++++++----
+ 2 files changed, 18 insertions(+), 4 deletions(-)
+
+diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
+index 4b7df5a5c966..6cc37c15e0bf 100644
+--- a/drivers/net/hyperv/hyperv_net.h
++++ b/drivers/net/hyperv/hyperv_net.h
+@@ -791,6 +791,7 @@ enum ndis_per_pkt_info_type {
+ IEEE_8021Q_INFO,
+ ORIGINAL_PKTINFO,
+ PACKET_CANCEL_ID,
++ NBL_HASH_VALUE = PACKET_CANCEL_ID,
+ ORIGINAL_NET_BUFLIST,
+ CACHED_NET_BUFLIST,
+ SHORT_PKT_PADINFO,
+@@ -937,6 +938,9 @@ struct ndis_tcp_lso_info {
+ #define NDIS_LSO_PPI_SIZE (sizeof(struct rndis_per_packet_info) + \
+ sizeof(struct ndis_tcp_lso_info))
+
++#define NDIS_HASH_PPI_SIZE (sizeof(struct rndis_per_packet_info) + \
++ sizeof(u32))
++
+ /* Format of Information buffer passed in a SetRequest for the OID */
+ /* OID_GEN_RNDIS_CONFIG_PARAMETER. */
+ struct rndis_config_parameter_info {
+diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c
+index 346f1aeb9c24..bd3b3acd04dc 100644
+--- a/drivers/net/hyperv/netvsc_drv.c
++++ b/drivers/net/hyperv/netvsc_drv.c
+@@ -224,9 +224,11 @@ static u16 netvsc_select_queue(struct net_device *ndev, struct sk_buff *skb,
+ if (nvsc_dev == NULL || ndev->real_num_tx_queues <= 1)
+ return 0;
+
+- if (netvsc_set_hash(&hash, skb))
++ if (netvsc_set_hash(&hash, skb)) {
+ q_idx = nvsc_dev->send_table[hash % VRSS_SEND_TAB_SIZE] %
+ ndev->real_num_tx_queues;
++ skb_set_hash(skb, hash, PKT_HASH_TYPE_L3);
++ }
+
+ return q_idx;
+ }
+@@ -385,6 +387,7 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ struct ndis_tcp_lso_info *lso_info;
+ int hdr_offset;
+ u32 net_trans_info;
++ u32 hash;
+
+
+ /* We will atmost need two pages to describe the rndis
+@@ -403,9 +406,8 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+ packet = kzalloc(sizeof(struct hv_netvsc_packet) +
+ (num_data_pgs * sizeof(struct hv_page_buffer)) +
+ sizeof(struct rndis_message) +
+- NDIS_VLAN_PPI_SIZE +
+- NDIS_CSUM_PPI_SIZE +
+- NDIS_LSO_PPI_SIZE, GFP_ATOMIC);
++ NDIS_VLAN_PPI_SIZE + NDIS_CSUM_PPI_SIZE +
++ NDIS_LSO_PPI_SIZE + NDIS_HASH_PPI_SIZE, GFP_ATOMIC);
+ if (!packet) {
+ /* out of memory, drop packet */
+ netdev_err(net, "unable to allocate hv_netvsc_packet\n");
+@@ -444,6 +446,14 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
+
+ rndis_msg_size = RNDIS_MESSAGE_SIZE(struct rndis_packet);
+
++ hash = skb_get_hash_raw(skb);
++ if (hash != 0 && net->real_num_tx_queues > 1) {
++ rndis_msg_size += NDIS_HASH_PPI_SIZE;
++ ppi = init_ppi_data(rndis_msg, NDIS_HASH_PPI_SIZE,
++ NBL_HASH_VALUE);
++ *(u32 *)((void *)ppi + ppi->ppi_offset) = hash;
++ }
++
+ if (isvlan) {
+ struct ndis_pkt_8021q_info *vlan;
+
+--
+2.4.3
+
--- /dev/null
+From ee99150c7f34737e4382e7199d2ffe3dfbb54a5c Mon Sep 17 00:00:00 2001
+From: Dave Jones <davej@redhat.com>
+Date: Mon, 16 Jun 2014 16:59:02 -0400
+Subject: [PATCH 22/25] hyperv: fix apparent cut-n-paste error in send path
+ teardown
+
+c25aaf814a63: "hyperv: Enable sendbuf mechanism on the send path" added
+some teardown code that looks like it was copied from the recieve path
+above, but missed a variable name replacement.
+
+Signed-off-by: Dave Jones <davej@redhat.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/netvsc.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index c041f63a6d30..4ed38eaecea8 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -189,7 +189,7 @@ static int netvsc_destroy_buf(struct netvsc_device *net_device)
+ "unable to teardown send buffer's gpadl\n");
+ return ret;
+ }
+- net_device->recv_buf_gpadl_handle = 0;
++ net_device->send_buf_gpadl_handle = 0;
+ }
+ if (net_device->send_buf) {
+ /* Free up the receive buffer */
+--
+2.4.3
+
--- /dev/null
+From f1009dfec7c439a958bd9ed8893dd6aa692c61f5 Mon Sep 17 00:00:00 2001
+From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
+Date: Wed, 23 Jul 2014 09:00:35 +0800
+Subject: [PATCH 23/25] hyperv: Fix error return code in netvsc_init_buf()
+
+Fix to return -ENOMEM from the kalloc error handling
+case instead of 0.
+
+Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
+Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+---
+ drivers/net/hyperv/netvsc.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index 4ed38eaecea8..d97d5f39a04e 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -378,8 +378,10 @@ static int netvsc_init_buf(struct hv_device *device)
+
+ net_device->send_section_map =
+ kzalloc(net_device->map_words * sizeof(ulong), GFP_KERNEL);
+- if (net_device->send_section_map == NULL)
++ if (net_device->send_section_map == NULL) {
++ ret = -ENOMEM;
+ goto cleanup;
++ }
+
+ goto exit;
+
+--
+2.4.3
+
--- /dev/null
+From 38bca2d5bd6fdaa0b8e1e415f79d89322c6825a8 Mon Sep 17 00:00:00 2001
+From: KY Srinivasan <kys@microsoft.com>
+Date: Sun, 5 Oct 2014 10:42:51 -0700
+Subject: [PATCH 24/25] hyperv: Fix a bug in netvsc_send()
+
+[ Upstream commit 3a67c9ccad926a168d8b7891537a452018368a5b ]
+
+After the packet is successfully sent, we should not touch the packet
+as it may have been freed. This patch is based on the work done by
+Long Li <longli@microsoft.com>.
+
+David, please queue this up for stable.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Reported-by: Sitsofe Wheeler <sitsofe@yahoo.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/net/hyperv/netvsc.c | 15 ++++++++-------
+ 1 file changed, 8 insertions(+), 7 deletions(-)
+
+diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
+index d97d5f39a04e..7edf976ecfa0 100644
+--- a/drivers/net/hyperv/netvsc.c
++++ b/drivers/net/hyperv/netvsc.c
+@@ -708,6 +708,7 @@ int netvsc_send(struct hv_device *device,
+ unsigned int section_index = NETVSC_INVALID_INDEX;
+ u32 msg_size = 0;
+ struct sk_buff *skb;
++ u16 q_idx = packet->q_idx;
+
+
+ net_device = get_outbound_net_device(device);
+@@ -772,24 +773,24 @@ int netvsc_send(struct hv_device *device,
+
+ if (ret == 0) {
+ atomic_inc(&net_device->num_outstanding_sends);
+- atomic_inc(&net_device->queue_sends[packet->q_idx]);
++ atomic_inc(&net_device->queue_sends[q_idx]);
+
+ if (hv_ringbuf_avail_percent(&out_channel->outbound) <
+ RING_AVAIL_PERCENT_LOWATER) {
+ netif_tx_stop_queue(netdev_get_tx_queue(
+- ndev, packet->q_idx));
++ ndev, q_idx));
+
+ if (atomic_read(&net_device->
+- queue_sends[packet->q_idx]) < 1)
++ queue_sends[q_idx]) < 1)
+ netif_tx_wake_queue(netdev_get_tx_queue(
+- ndev, packet->q_idx));
++ ndev, q_idx));
+ }
+ } else if (ret == -EAGAIN) {
+ netif_tx_stop_queue(netdev_get_tx_queue(
+- ndev, packet->q_idx));
+- if (atomic_read(&net_device->queue_sends[packet->q_idx]) < 1) {
++ ndev, q_idx));
++ if (atomic_read(&net_device->queue_sends[q_idx]) < 1) {
+ netif_tx_wake_queue(netdev_get_tx_queue(
+- ndev, packet->q_idx));
++ ndev, q_idx));
+ ret = -ENOSPC;
+ }
+ } else {
+--
+2.4.3
+
--- /dev/null
+From 4b71288758aa1d510402b84ca93b1ef566575d22 Mon Sep 17 00:00:00 2001
+From: "K. Y. Srinivasan" <kys@microsoft.com>
+Date: Mon, 3 Feb 2014 12:42:45 -0800
+Subject: [PATCH 25/25] Drivers: hv: vmbus: Support per-channel driver state
+
+As we implement Virtual Receive Side Scaling on the networking side
+(the VRSS patches are currently under review), it will be useful to have
+per-channel state that vmbus drivers can manage. Add support for
+managing per-channel state.
+
+Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ include/linux/hyperv.h | 14 ++++++++++++++
+ 1 file changed, 14 insertions(+)
+
+diff --git a/include/linux/hyperv.h b/include/linux/hyperv.h
+index 6088058a3e00..732dc7e37e96 100644
+--- a/include/linux/hyperv.h
++++ b/include/linux/hyperv.h
+@@ -1045,6 +1045,10 @@ struct vmbus_channel {
+ * This will be NULL for the primary channel.
+ */
+ struct vmbus_channel *primary_channel;
++ /*
++ * Support per-channel state for use by vmbus drivers.
++ */
++ void *per_channel_state;
+ };
+
+ static inline void set_channel_read_state(struct vmbus_channel *c, bool state)
+@@ -1052,6 +1056,16 @@ static inline void set_channel_read_state(struct vmbus_channel *c, bool state)
+ c->batched_reading = state;
+ }
+
++static inline void set_per_channel_state(struct vmbus_channel *c, void *s)
++{
++ c->per_channel_state = s;
++}
++
++static inline void *get_per_channel_state(struct vmbus_channel *c)
++{
++ return c->per_channel_state;
++}
++
+ void vmbus_onmessage(void *context);
+
+ int vmbus_request_offers(void);
+--
+2.4.3
+
--- /dev/null
+diff -up lua-5.3.0/configure.ac.autoxxx lua-5.3.0/configure.ac
+--- lua-5.3.0/configure.ac.autoxxx 2015-01-15 10:20:03.826889574 -0500
++++ lua-5.3.0/configure.ac 2015-01-15 10:20:03.826889574 -0500
+@@ -0,0 +1,69 @@
++AC_PREREQ(2.59)
++AC_INIT([lua], [5.3.0], [https://bugzilla.redhat.com/], [lua-at], [http://www.lua.org])
++AC_SUBST([MAJOR_VERSION], [5.3])
++
++AC_CONFIG_HEADERS([config.h])
++AC_CONFIG_SRCDIR([src/lapi.c])
++
++AM_INIT_AUTOMAKE([1.9 foreign])
++
++AC_PROG_CC
++AC_PROG_LIBTOOL
++
++AC_ARG_WITH(
++ [readline],
++ [AC_HELP_STRING([--with-readline], [Use readline for interpreter input [default=yes]])],
++ [use_readline=$withval],
++ [use_readline=yes]
++)
++
++LUA_LIBS="-lm"
++
++# Check for readline
++READLINE_DEFS="#undef LUA_USE_READLINE"
++if test "x$use_readline" == "xyes"; then
++ AC_CHECK_LIB([readline], [readline], [:], [use_readline=no], [-lncurses])
++ AC_CHECK_HEADERS([readline/readline.h readline/history.h], [], [use_readline=no])
++ if test "x$use_readline" == "xno"; then
++ AC_MSG_WARN([readline headers could not be found, disabling readline support])
++ else
++ READLINE_DEFS="#define LUA_USE_READLINE"
++ READLINE_LIBS="-lreadline -lncurses"
++ fi
++fi
++AC_SUBST(READLINE_DEFS)
++AC_SUBST(READLINE_LIBS)
++
++case "$host" in
++ *-mingw*) use_os=win32 ;;
++ *-darwin*) use_os=macosx ;;
++ *) use_os=posix ;;
++esac
++
++POSIX_DEFS="#undef LUA_USE_POSIX"
++LUA_DL_DEFS="#undef LUA_USE_DLOPEN"
++LUA_BUILD_AS_DLL_DEFS="#undef LUA_BUILD_AS_DLL"
++
++if test "x$use_os" == "xwin32"; then
++ LUA_BUILD_AS_DLL_DEFS="#define LUA_BUILD_AS_DLL"
++elif test "x$use_os" == "xmacosx"; then
++ POSIX_DEFS="#define LUA_USE_POSIX"
++ LUA_DL_DEFS="#define LUA_DL_DYLD"
++elif test "x$use_os" == "xposix"; then
++ POSIX_DEFS="#define LUA_USE_POSIX"
++ LUA_DL_DEFS="#define LUA_DL_DLOPEN"
++ LUA_LIBS="$LUA_LIBS -ldl"
++fi
++AC_SUBST(POSIX_DEFS)
++AC_SUBST(LUA_DL_DEFS)
++AC_SUBST(LUA_BUILD_AS_DLL_DEFS)
++
++AC_SUBST(LUA_LIBS)
++
++AC_CONFIG_FILES([Makefile
++ src/Makefile
++ src/lua.pc
++ src/luaconf.h.template
++ doc/Makefile
++])
++AC_OUTPUT
+diff -up lua-5.3.0/doc/Makefile.am.autoxxx lua-5.3.0/doc/Makefile.am
+--- lua-5.3.0/doc/Makefile.am.autoxxx 2015-01-15 10:20:03.826889574 -0500
++++ lua-5.3.0/doc/Makefile.am 2015-01-15 10:20:03.826889574 -0500
+@@ -0,0 +1,4 @@
++man1_MANS = lua.1 luac.1
++
++EXTRA_DIST = \
++ contents.html logo.gif lua.1 luac.1 lua.css manual.css manual.html osi-certified-72x60.png readme.html
+diff -up lua-5.3.0/Makefile.am.autoxxx lua-5.3.0/Makefile.am
+--- lua-5.3.0/Makefile.am.autoxxx 2015-01-15 10:20:03.826889574 -0500
++++ lua-5.3.0/Makefile.am 2015-01-15 10:20:03.826889574 -0500
+@@ -0,0 +1,3 @@
++SUBDIRS = src doc
++
++EXTRA_DIST = README
+diff -up lua-5.3.0/src/.gitignore.autoxxx lua-5.3.0/src/.gitignore
+--- lua-5.3.0/src/.gitignore.autoxxx 2015-01-15 10:20:03.826889574 -0500
++++ lua-5.3.0/src/.gitignore 2015-01-15 10:20:03.826889574 -0500
+@@ -0,0 +1,5 @@
++lua
++lua.pc
++luac
++luaconf.h
++luaconf.h.template
+diff -up lua-5.3.0/src/luaconf.h.template.in.autoxxx lua-5.3.0/src/luaconf.h.template.in
+--- lua-5.3.0/src/luaconf.h.template.in.autoxxx 2015-01-15 10:20:03.828889562 -0500
++++ lua-5.3.0/src/luaconf.h.template.in 2015-01-15 10:22:37.420027778 -0500
+@@ -11,6 +11,11 @@
+ #include <limits.h>
+ #include <stddef.h>
+
++@POSIX_DEFS@
++@LUA_DL_DEFS@
++@LUA_BUILD_AS_DLL_DEFS@
++@READLINE_DEFS@
++
+
+ /*
+ ** ===================================================================
+@@ -175,9 +180,9 @@
+
+ #else /* }{ */
+
+-#define LUA_ROOT "/usr/local/"
+-#define LUA_LDIR LUA_ROOT "share/lua/" LUA_VDIR "/"
+-#define LUA_CDIR LUA_ROOT "lib/lua/" LUA_VDIR "/"
++#define LUA_ROOT "@prefix@/"
++#define LUA_LDIR "@pkgdatadir@/lua/" LUA_VDIR "/"
++#define LUA_CDIR "@libdir@/lua/" LUA_VDIR "/"
+ #define LUA_PATH_DEFAULT \
+ LUA_LDIR"?.lua;" LUA_LDIR"?/init.lua;" \
+ LUA_CDIR"?.lua;" LUA_CDIR"?/init.lua;" \
+diff -up lua-5.3.0/src/lua.pc.in.autoxxx lua-5.3.0/src/lua.pc.in
+--- lua-5.3.0/src/lua.pc.in.autoxxx 2015-01-15 10:20:03.827889568 -0500
++++ lua-5.3.0/src/lua.pc.in 2015-01-15 10:20:03.827889568 -0500
+@@ -0,0 +1,13 @@
++V= @MAJOR_VERSION@
++R= @VERSION@
++prefix= @prefix@
++exec_prefix=${prefix}
++libdir= @libdir@
++includedir=${prefix}/include
++
++Name: Lua
++Description: An Extensible Extension Language
++Version: ${R}
++Requires:
++Libs: -llua @LUA_LIBS@
++Cflags: -I${includedir}
+diff -up lua-5.3.0/src/Makefile.am.autoxxx lua-5.3.0/src/Makefile.am
+--- lua-5.3.0/src/Makefile.am.autoxxx 2015-01-15 10:20:03.826889574 -0500
++++ lua-5.3.0/src/Makefile.am 2015-01-15 10:20:03.826889574 -0500
+@@ -0,0 +1,46 @@
++AM_CFLAGS = -Wall
++
++include_HEADERS = lua.h lualib.h lauxlib.h lua.hpp
++
++nodist_include_HEADERS = luaconf.h
++
++lib_LTLIBRARIES = liblua.la
++liblua_la_LDFLAGS = -release @MAJOR_VERSION@
++liblua_la_SOURCES = \
++ lapi.c lauxlib.c lbaselib.c lbitlib.c lcode.c lcorolib.c lctype.c ldblib.c \
++ ldebug.c ldo.c ldump.c lfunc.c lgc.c linit.c liolib.c llex.c lmathlib.c lmem.c \
++ loadlib.c lobject.c lopcodes.c loslib.c lparser.c lstate.c lstring.c lstrlib.c \
++ ltable.c ltablib.c ltm.c lundump.c lutf8lib.c lvm.c lzio.c \
++ lapi.h lcode.h lctype.h ldebug.h ldo.h lfunc.h lgc.h llex.h llimits.h \
++ lmem.h lobject.h lopcodes.h lparser.h lstate.h lstring.h ltable.h ltm.h \
++ lundump.h lvm.h lzio.h
++
++pkgconfigdir = $(libdir)/pkgconfig
++pkgconfig_DATA = lua.pc
++
++bin_PROGRAMS = lua luac
++
++lua_SOURCES = lua.c
++lua_LDADD = liblua.la @LUA_LIBS@ @READLINE_LIBS@
++lua_DEPENDENCIES = liblua.la
++
++luac_SOURCES = luac.c
++# Statically link liblua against luac since luac uses symbols not exported in liblua
++luac_LDADD = .libs/liblua.a @LUA_LIBS@
++luac_DEPENDENCIES = liblua.la
++
++EXTRA_DIST = luaconf.h.template
++BUILT_SOURCES = luaconf.h
++CLEANFILES = luaconf.h luaconf.h.template
++
++readline_defs = @READLINE_DEFS@
++
++edit = sed \
++ -e 's,%prefix%,$(prefix),g' \
++ -e 's,%lua_datadir%,$(datadir),g' \
++ -e 's,%lua_libdir%,$(libdir),g'
++
++luaconf.h : luaconf.h.template
++ rm -f $@ $@.tmp
++ $(edit) $< >$@.tmp
++ mv $@.tmp $@
+++ /dev/null
-# http://bugs.ntp.org/show_bug.cgi?id=2965
-
-From 6f68f1f0fd764f0006506e3957a5b8116726d443 Mon Sep 17 00:00:00 2001
-From: <burnicki/martin@pc-martin4.>
-Date: Mon, 16 Nov 2015 11:59:55 +0100
-Subject: [PATCH] [Bug 2965] Local clock didn't work since 4.2.8p4
-
----
- ntpd/refclock_local.c | 1 +
- 1 files changed, 1 insertions(+)
-
-diff --git a/ntpd/refclock_local.c b/ntpd/refclock_local.c
-index d816c55..8c0f74f 100644
---- a/ntpd/refclock_local.c
-+++ b/ntpd/refclock_local.c
-@@ -205,6 +205,7 @@ local_poll(
- pp->disp = 0;
- pp->jitter = 0;
- #else /* KERNEL_PLL LOCKCLOCK */
-+ pp->leap = LEAP_NOWARNING;
- pp->disp = DISPERSION;
- pp->jitter = 0;
- #endif /* KERNEL_PLL LOCKCLOCK */
--- /dev/null
+------------------------------------------------------------
+revno: 13230
+revision-id: squid3@treenet.co.nz-20160212045316-zwx4r9we4gf27rx3
+parent: squid3@treenet.co.nz-20151119051038-vwclso11p68sgvxc
+fixes bug: http://bugs.squid-cache.org/show_bug.cgi?id=4431
+author: Marcos Mello <marcosfrm@gmail.com>
+committer: Amos Jeffries <squid3@treenet.co.nz>
+branch nick: 3.4
+timestamp: Fri 2016-02-12 17:53:16 +1300
+message:
+ Bug 4431: C code is not compiled with CFLAGS
+------------------------------------------------------------
+# Bazaar merge directive format 2 (Bazaar 0.90)
+# revision_id: squid3@treenet.co.nz-20160212045316-zwx4r9we4gf27rx3
+# target_branch: http://bzr.squid-cache.org/bzr/squid3/3.4
+# testament_sha1: 53c8d70db04dad826815fb86995cda7e99f1d8e2
+# timestamp: 2016-02-12 05:50:53 +0000
+# source_branch: http://bzr.squid-cache.org/bzr/squid3/3.4
+# base_revision_id: squid3@treenet.co.nz-20151119051038-\
+# vwclso11p68sgvxc
+#
+# Begin patch
+=== modified file 'acinclude/compiler-flags.m4'
+--- acinclude/compiler-flags.m4 2015-01-09 10:30:44 +0000
++++ acinclude/compiler-flags.m4 2016-02-12 04:53:16 +0000
+@@ -36,7 +36,7 @@
+ AC_CACHE_CHECK([whether compiler accepts $2],[$1],
+ [{
+ AC_REQUIRE([AC_PROG_CC])
+- SAVED_FLAGS="$CFLAGS"
++ SAVED_CFLAGS="$CFLAGS"
+ SAVED_CXXFLAGS="$CXXFLAGS"
+ CFLAGS="$CFLAGS $2"
+ CXXFLAGS="$CXXFLAGS $2"
+@@ -60,7 +60,7 @@
+ AC_CACHE_CHECK([whether compiler requires $2],[$1],
+ [{
+ AC_REQUIRE([AC_PROG_CC])
+- SAVED_FLAGS="$CFLAGS"
++ SAVED_CFLAGS="$CFLAGS"
+ SAVED_CXXFLAGS="$CXXFLAGS"
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM($3,$4)],[$1=no],[],[$1=no])
+ if test "x$1" != "xno" ; then
+
--- /dev/null
+--- configure.ac~ 2016-01-23 01:27:44.078013879 +0000
++++ configure.ac 2016-01-23 01:28:19.422179243 +0000
+@@ -2573,6 +2573,9 @@
+ ;;
+ esac
+
++SQUID_CHECK_DEFAULT_FD_SETSIZE
++SQUID_CHECK_MAXFD
++
+ dnl --with-maxfd present for compatibility with Squid-2.
+ dnl undocumented in ./configure --help to encourage using the Squid-3 directive
+ AC_ARG_WITH(maxfd,,
+@@ -2603,8 +2606,6 @@
+ esac
+ ])
+
+-SQUID_CHECK_DEFAULT_FD_SETSIZE
+-SQUID_CHECK_MAXFD
+ if test "x$squid_filedescriptors_num" != "x"; then
+ AC_MSG_NOTICE([Default number of fieldescriptors: $squid_filedescriptors_num])
+ fi
echo "$FIRE gateway" >> /tmp/hosts
else
#DNS lookup failed use direct ip
- echo "178.63.73.246 gateway" >> /tmp/hosts
+ echo "81.3.27.38 gateway" >> /tmp/hosts
fi
fi
mv /tmp/hosts /etc/hosts
case "${target_arch}" in
x86_64)
BUILDTARGET="${target_arch}-unknown-linux-gnu"
- CROSSTARGET="${BUILD_ARCH}-cross-linux-gnu"
+ CROSSTARGET="${target_arch}-cross-linux-gnu"
CFLAGS_ARCH="-m64 -mtune=generic"
;;
i586)
BUILDTARGET="${target_arch}-pc-linux-gnu"
- CROSSTARGET="${BUILD_ARCH}-cross-linux-gnu"
+ CROSSTARGET="${target_arch}-cross-linux-gnu"
CFLAGS_ARCH="-march=i586 -mtune=generic -fomit-frame-pointer"
;;
armv5tel)
BUILDTARGET="${target_arch}-unknown-linux-gnueabi"
- CROSSTARGET="${BUILD_ARCH}-cross-linux-gnueabi"
+ CROSSTARGET="${target_arch}-cross-linux-gnueabi"
CFLAGS_ARCH="-march=armv5te -mfloat-abi=soft -fomit-frame-pointer"
MACHINE_TYPE="arm"
;;
MACHINE="${TARGET_ARCH}"
CFLAGS="-O2 -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fPIC"
- CFLAGS="${CFLAGS} -fstack-protector-all --param=ssp-buffer-size=4 ${CFLAGS_ARCH}"
+ CFLAGS="${CFLAGS} -fstack-protector-strong --param=ssp-buffer-size=4 ${CFLAGS_ARCH}"
CXXFLAGS="${CFLAGS}"
}