- 01 5月, 2014 4 次提交
-
-
由 Lars Ellenberg 提交于
Because all administrative requests via genetlink have been globally serialized via genl_lock(), we used to have one static struct drbd_config_context "admin context". Move this on-stack to the respective callback functions. This will allow us to selectively drop the genl_lock() (or use genl_family->parallel_ops) in the future. Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com> Signed-off-by: NLars Ellenberg <lars.ellenberg@linbit.com> Signed-off-by: NJens Axboe <axboe@fb.com>
-
由 Philipp Reisner 提交于
If a user forces the operation he takes the blame in case the peer does not have enough space. No reason to dey this... Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com> Signed-off-by: NLars Ellenberg <lars.ellenberg@linbit.com> Signed-off-by: NJens Axboe <axboe@fb.com>
-
由 Philipp Reisner 提交于
Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com> Signed-off-by: NLars Ellenberg <lars.ellenberg@linbit.com> Signed-off-by: NJens Axboe <axboe@fb.com>
-
由 Philipp Reisner 提交于
Actually we are clearing the susp_fen flag if we are not going to call a fencing handler. For setting the susp_fen flag needs to be edge-triggerd, and not level triggered. Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com> Signed-off-by: NLars Ellenberg <lars.ellenberg@linbit.com> Signed-off-by: NJens Axboe <axboe@fb.com>
-
- 22 2月, 2014 1 次提交
-
-
由 Andreas Gruenbacher 提交于
Right now every resource has exactly one connection. But we are preparing for dynamic connections. I.e. in the future thre can be resources without connections. However smatch points this out as 'variable dereferenced before check', which is correct. This issue was introduced in drbd: get_one_status(): Iterate over resource->devices instead of connection->peer_devices Reported-by: NDan Carpenter <dan.carpenter@oracle.com> Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com> Signed-off-by: NJens Axboe <axboe@fb.com>
-
- 17 2月, 2014 31 次提交
-
-
由 Andreas Gruenbacher 提交于
The new function can flush any work queue, not just the work queue of the data socket of a connection. Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
These functions actually operate on a peer device, or need a peer device. drbd_prepare_command(), drbd_send_command(), drbd_send_sync_param() drbd_send_uuids(), drbd_gen_and_send_sync_uuid(), drbd_send_sizes() drbd_send_state(), drbd_send_current_state(), and drbd_send_state_req() drbd_send_sr_reply(), drbd_send_ack(), drbd_send_drequest(), drbd_send_drequest_csum(), drbd_send_ov_request(), drbd_send_dblock() drbd_send_block(), drbd_send_out_of_sync(), recv_dless_read() drbd_drain_block(), receive_bitmap_plain(), recv_resync_read() read_in_block(), read_for_csum(), drbd_alloc_pages(), drbd_alloc_peer_req() need_peer_seq(), update_peer_seq(), wait_for_and_update_peer_seq() drbd_sync_handshake(), drbd_asb_recover_{0,1,2}p(), drbd_connected() drbd_disconnected(), decode_bitmap_c() and recv_bm_rle_bits() Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Also change drbd_adm_connect() to expect a resource after it requested one. Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
in drbd_adm_down(), drbd_create_device() and drbd_set_role() Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
The implicit dependency on a variable inside the macro is problematic. Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
With the polymorphic drbd_() macros, we no longer need the connection specific variants. Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
DRBD was using dev_err() and similar all over the code; instead of having to write dev_err(disk_to_dev(device->vdisk), ...) to convert a drbd_device into a kernel device, a DEV macro was used which implicitly references the device variable. This is terrible; introduce separate drbd_err() and similar macros with an explicit device parameter instead. Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Let connection->peer_devices point to peer devices; connection->volumes was pointing to devices. Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
So far, connections and resources always come in pairs, but in the future with multiple connections per resource, the names will stick with the resources. Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
This allows to access the volumes of a resource by number. Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
In a first step, each resource has exactly one connection, and both objects are allocated at the same time. The final result will be one resource and zero or more connections. Only allow to delete a resource if all its connections are C_STANDALONE. Stop the worker threads of all connections early enough. Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Rename functions conn_destroy() -> drbd_destroy_connection(), drbd_minor_destroy() -> drbd_destroy_device() drbd_adm_add_minor() -> drbd_adm_add_minor() drbd_adm_delete_minor() -> drbd_adm_del_minor() Rename global variable minors to drbd_devices Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
In a setup where a device (aka volume) can replicate to multiple peers and one connection can be shared between multiple devices, we need separate objects to represent devices on peer nodes and network connections. As a first step to introduce multiple connections per device, give each drbd_device object a single drbd_peer_device object which connects it to a drbd_connection object. Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
sed -i -e 's:all_tconn:connections:g' -e 's:tconn:connection:g' Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
sed -i -e 's:mdev:device:g' Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
sed -i -e 's:\<drbd_conf\>:drbd_device:g' Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Andreas Gruenbacher 提交于
Keep the protocol definitions separate from the kernel code; they are useful in their own right. Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
由 Philipp Reisner 提交于
Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com> Signed-off-by: NLars Ellenberg <lars.ellenberg@linbit.com>
-
由 Rashika Kheria 提交于
Mark functions conn_khelper(), nla_put_drbd_cfg_context(), nla_put_status_info() and get_one_status() as static in drbd/drbd_nl.c because they are not used outside this file. This eliminates the following warnings in drbd/drbd_nl.c: drivers/block/drbd/drbd_nl.c:365:5: warning: no previous prototype for ‘conn_khelper’ [-Wmissing-prototypes] drivers/block/drbd/drbd_nl.c:2727:5: warning: no previous prototype for ‘nla_put_drbd_cfg_context’ [-Wmissing-prototypes] drivers/block/drbd/drbd_nl.c:2753:5: warning: no previous prototype for ‘nla_put_status_info’ [-Wmissing-prototypes] drivers/block/drbd/drbd_nl.c:2895:5: warning: no previous prototype for ‘get_one_status’ [-Wmissing-prototypes] Signed-off-by: NRashika Kheria <rashika.kheria@gmail.com> Reviewed-by: NJosh Triplett <josh@joshtriplett.org> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
-
- 09 11月, 2013 2 次提交
-
-
由 Lars Ellenberg 提交于
For a long time, the receiving side has spread "too large" incoming requests over multiple bios. No need to shrink our max_bio_size (max_hw_sectors) if the peer is reconfigured to use a different storage. The problem manifests itself if we are not the top of the device stack (DRBD is used a LVM PV). A hardware reconfiguration on the peer may cause the supported max_bio_size to shrink, and the connection handshake would now unnecessarily shrink the max_bio_size on the active node. There is no way to notify upper layers that they have to "re-stack" their limits. So they won't notice at all, and may keep submitting bios that are suddenly considered "too large for device". We already check for compatibility and ignore changes on the peer, the code only was masked out unless we have a fully established connection. We just need to allow it a bit earlier during the handshake. Also consider max_hw_sectors in our merge bvec function, just in case. Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com> Signed-off-by: NLars Ellenberg <lars.ellenberg@linbit.com> Signed-off-by: NJens Axboe <axboe@kernel.dk>
-
由 Philipp Reisner 提交于
Online adding of new minors with freshly created meta data to an resource with an established connection failed, with a wrong state transition on one side on one side of the new minor. Freshly created meta-data has a la_size (last agreed size) of 0. When we online add such devices, the code wrongly got into the code path for resyncing new storage that was added while the disk was detached. Fixed that by making the GREW from ZERO a special case. Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com> Signed-off-by: NLars Ellenberg <lars.ellenberg@linbit.com> Signed-off-by: NJens Axboe <axboe@kernel.dk>
-
- 28 6月, 2013 2 次提交
-
-
由 Philipp Reisner 提交于
Allow to change the AL layout with an resize operation. For that the reisze command gets two new fields: al_stripes and al_stripe_size. In order to make the operation crash save: 1) Lock out all IO and MD-IO 2) Write the super block with MDF_PRIMARY_IND clear 3) write the bitmap to the new location (all zeros, since we allow only while connected) 4) Initialize the new AL-area 5) Write the super block with the restored MDF_PRIMARY_IND. 6) Unfreeze all IO Since the AL-layout has no influence on the protocol, this operation needs to be beforemed on both sides of a resource (if intended). Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com> Signed-off-by: NJens Axboe <axboe@kernel.dk>
-
由 Philipp Reisner 提交于
Signed-off-by: NAndreas Gruenbacher <agruen@linbit.com> Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com> Signed-off-by: NJens Axboe <axboe@kernel.dk>
-