From e99ba1362723df14bbe36da6eeaadf81d95782e6 Mon Sep 17 00:00:00 2001 From: "Stephen M. Cameron" Date: Mon, 19 Jul 2010 13:45:15 -0500 Subject: cciss: factor out cciss_wait_for_board_ready() cciss: factor out cciss_wait_for_board_ready() Signed-off-by: Stephen M. Cameron Signed-off-by: Jens Axboe --- drivers/block/cciss.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'drivers/block/cciss.h') diff --git a/drivers/block/cciss.h b/drivers/block/cciss.h index 8a9f5b58daa8..c2ef9dd56c45 100644 --- a/drivers/block/cciss.h +++ b/drivers/block/cciss.h @@ -190,6 +190,21 @@ struct ctlr_info #define CCISS_INTR_ON 1 #define CCISS_INTR_OFF 0 + + +/* CCISS_BOARD_READY_WAIT_SECS is how long to wait for a board + * to become ready, in seconds, before giving up on it. + * CCISS_BOARD_READY_POLL_INTERVAL_MSECS * is how long to wait + * between polling the board to see if it is ready, in + * milliseconds. CCISS_BOARD_READY_ITERATIONS is derived + * the above. + */ +#define CCISS_BOARD_READY_WAIT_SECS (120) +#define CCISS_BOARD_READY_POLL_INTERVAL_MSECS (100) +#define CCISS_BOARD_READY_ITERATIONS \ + ((CCISS_BOARD_READY_WAIT_SECS * 1000) / \ + CCISS_BOARD_READY_POLL_INTERVAL_MSECS) + /* Send the command to the hardware */ -- cgit v1.2.3