From 0911736245df19b423a3b156f6709e7bba48b18a Mon Sep 17 00:00:00 2001 From: Nikolay Aleksandrov Date: Wed, 22 Jan 2014 14:53:16 +0100 Subject: bonding: add infrastructure for an option API This patch adds the necessary basic infrastructure to support centralized and unified option manipulation API for the bonding. The new structure bond_option will be used to describe each option with its dependencies on modes which will be checked automatically thus removing a lot of duplicated code. Also automatic range checking is added for some options. Currently the option setting function requires RTNL to be acquired prior to calling it, since many options already rely on RTNL it seemed like the best choice to protect all against common race conditions. In order to add an option the following steps need to be done: 1. Add an entry BOND_OPT_