forked from torvalds/linux
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
They should be reimplemented in the current scheme. Signed-off-by: Jens Axboe <[email protected]>
- Loading branch information
Jens Axboe
committed
Oct 1, 2009
1 parent
ab8fafc
commit 6a0afdf
Showing
11 changed files
with
3 additions
and
1,021 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -53,7 +53,6 @@ | |
|
||
#include <linux/drbd_limits.h> | ||
#include "drbd_int.h" | ||
#include "drbd_tracing.h" | ||
#include "drbd_req.h" /* only for _req_mod in tl_release and tl_clear */ | ||
|
||
#include "drbd_vli.h" | ||
|
@@ -80,18 +79,6 @@ static int w_md_sync(struct drbd_conf *mdev, struct drbd_work *w, int unused); | |
static void md_sync_timer_fn(unsigned long data); | ||
static int w_bitmap_io(struct drbd_conf *mdev, struct drbd_work *w, int unused); | ||
|
||
DEFINE_TRACE(drbd_unplug); | ||
DEFINE_TRACE(drbd_uuid); | ||
DEFINE_TRACE(drbd_ee); | ||
DEFINE_TRACE(drbd_packet); | ||
DEFINE_TRACE(drbd_md_io); | ||
DEFINE_TRACE(drbd_epoch); | ||
DEFINE_TRACE(drbd_netlink); | ||
DEFINE_TRACE(drbd_actlog); | ||
DEFINE_TRACE(drbd_bio); | ||
DEFINE_TRACE(_drbd_resync); | ||
DEFINE_TRACE(drbd_req); | ||
|
||
MODULE_AUTHOR("Philipp Reisner <[email protected]>, " | ||
"Lars Ellenberg <[email protected]>"); | ||
MODULE_DESCRIPTION("drbd - Distributed Replicated Block Device v" REL_VERSION); | ||
|
@@ -1576,7 +1563,6 @@ int _drbd_send_cmd(struct drbd_conf *mdev, struct socket *sock, | |
h->command = cpu_to_be16(cmd); | ||
h->length = cpu_to_be16(size-sizeof(struct p_header)); | ||
|
||
trace_drbd_packet(mdev, sock, 0, (void *)h, __FILE__, __LINE__); | ||
sent = drbd_send(mdev, sock, h, size, msg_flags); | ||
|
||
ok = (sent == size); | ||
|
@@ -1628,8 +1614,6 @@ int drbd_send_cmd2(struct drbd_conf *mdev, enum drbd_packets cmd, char *data, | |
if (!drbd_get_data_sock(mdev)) | ||
return 0; | ||
|
||
trace_drbd_packet(mdev, mdev->data.socket, 0, (void *)&h, __FILE__, __LINE__); | ||
|
||
ok = (sizeof(h) == | ||
drbd_send(mdev, mdev->data.socket, &h, sizeof(h), 0)); | ||
ok = ok && (size == | ||
|
@@ -2359,7 +2343,6 @@ int drbd_send_dblock(struct drbd_conf *mdev, struct drbd_request *req) | |
dp_flags |= DP_MAY_SET_IN_SYNC; | ||
|
||
p.dp_flags = cpu_to_be32(dp_flags); | ||
trace_drbd_packet(mdev, mdev->data.socket, 0, (void *)&p, __FILE__, __LINE__); | ||
set_bit(UNPLUG_REMOTE, &mdev->flags); | ||
ok = (sizeof(p) == | ||
drbd_send(mdev, mdev->data.socket, &p, sizeof(p), MSG_MORE)); | ||
|
@@ -2410,7 +2393,6 @@ int drbd_send_block(struct drbd_conf *mdev, enum drbd_packets cmd, | |
if (!drbd_get_data_sock(mdev)) | ||
return 0; | ||
|
||
trace_drbd_packet(mdev, mdev->data.socket, 0, (void *)&p, __FILE__, __LINE__); | ||
ok = sizeof(p) == drbd_send(mdev, mdev->data.socket, &p, | ||
sizeof(p), MSG_MORE); | ||
if (ok && dgs) { | ||
|
@@ -2546,8 +2528,6 @@ static void drbd_unplug_fn(struct request_queue *q) | |
{ | ||
struct drbd_conf *mdev = q->queuedata; | ||
|
||
trace_drbd_unplug(mdev, "got unplugged"); | ||
|
||
/* unplug FIRST */ | ||
spin_lock_irq(q->queue_lock); | ||
blk_remove_plug(q); | ||
|
@@ -3252,8 +3232,6 @@ void drbd_md_sync(struct drbd_conf *mdev) | |
if (!get_ldev_if_state(mdev, D_FAILED)) | ||
return; | ||
|
||
trace_drbd_md_io(mdev, WRITE, mdev->ldev); | ||
|
||
mutex_lock(&mdev->md_io_mutex); | ||
buffer = (struct meta_data_on_disk *)page_address(mdev->md_io_page); | ||
memset(buffer, 0, 512); | ||
|
@@ -3308,8 +3286,6 @@ int drbd_md_read(struct drbd_conf *mdev, struct drbd_backing_dev *bdev) | |
if (!get_ldev_if_state(mdev, D_ATTACHING)) | ||
return ERR_IO_MD_DISK; | ||
|
||
trace_drbd_md_io(mdev, READ, bdev); | ||
|
||
mutex_lock(&mdev->md_io_mutex); | ||
buffer = (struct meta_data_on_disk *)page_address(mdev->md_io_page); | ||
|
||
|
@@ -3388,11 +3364,8 @@ static void drbd_uuid_move_history(struct drbd_conf *mdev) __must_hold(local) | |
{ | ||
int i; | ||
|
||
for (i = UI_HISTORY_START; i < UI_HISTORY_END; i++) { | ||
for (i = UI_HISTORY_START; i < UI_HISTORY_END; i++) | ||
mdev->ldev->md.uuid[i+1] = mdev->ldev->md.uuid[i]; | ||
|
||
trace_drbd_uuid(mdev, i+1); | ||
} | ||
} | ||
|
||
void _drbd_uuid_set(struct drbd_conf *mdev, int idx, u64 val) __must_hold(local) | ||
|
@@ -3407,7 +3380,6 @@ void _drbd_uuid_set(struct drbd_conf *mdev, int idx, u64 val) __must_hold(local) | |
} | ||
|
||
mdev->ldev->md.uuid[idx] = val; | ||
trace_drbd_uuid(mdev, idx); | ||
drbd_md_mark_dirty(mdev); | ||
} | ||
|
||
|
@@ -3417,7 +3389,6 @@ void drbd_uuid_set(struct drbd_conf *mdev, int idx, u64 val) __must_hold(local) | |
if (mdev->ldev->md.uuid[idx]) { | ||
drbd_uuid_move_history(mdev); | ||
mdev->ldev->md.uuid[UI_HISTORY_START] = mdev->ldev->md.uuid[idx]; | ||
trace_drbd_uuid(mdev, UI_HISTORY_START); | ||
} | ||
_drbd_uuid_set(mdev, idx, val); | ||
} | ||
|
@@ -3436,7 +3407,6 @@ void drbd_uuid_new_current(struct drbd_conf *mdev) __must_hold(local) | |
dev_info(DEV, "Creating new current UUID\n"); | ||
D_ASSERT(mdev->ldev->md.uuid[UI_BITMAP] == 0); | ||
mdev->ldev->md.uuid[UI_BITMAP] = mdev->ldev->md.uuid[UI_CURRENT]; | ||
trace_drbd_uuid(mdev, UI_BITMAP); | ||
|
||
get_random_bytes(&val, sizeof(u64)); | ||
_drbd_uuid_set(mdev, UI_CURRENT, val); | ||
|
@@ -3451,16 +3421,13 @@ void drbd_uuid_set_bm(struct drbd_conf *mdev, u64 val) __must_hold(local) | |
drbd_uuid_move_history(mdev); | ||
mdev->ldev->md.uuid[UI_HISTORY_START] = mdev->ldev->md.uuid[UI_BITMAP]; | ||
mdev->ldev->md.uuid[UI_BITMAP] = 0; | ||
trace_drbd_uuid(mdev, UI_HISTORY_START); | ||
trace_drbd_uuid(mdev, UI_BITMAP); | ||
} else { | ||
if (mdev->ldev->md.uuid[UI_BITMAP]) | ||
dev_warn(DEV, "bm UUID already set"); | ||
|
||
mdev->ldev->md.uuid[UI_BITMAP] = val; | ||
mdev->ldev->md.uuid[UI_BITMAP] &= ~((u64)1); | ||
|
||
trace_drbd_uuid(mdev, UI_BITMAP); | ||
} | ||
drbd_md_mark_dirty(mdev); | ||
} | ||
|
@@ -3727,7 +3694,6 @@ const char *drbd_buildtag(void) | |
module_init(drbd_init) | ||
module_exit(drbd_cleanup) | ||
|
||
/* For drbd_tracing: */ | ||
EXPORT_SYMBOL(drbd_conn_str); | ||
EXPORT_SYMBOL(drbd_role_str); | ||
EXPORT_SYMBOL(drbd_disk_str); | ||
|
Oops, something went wrong.