Commit 09bf9e5e authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

[PATCH] sn: shubio.c cleanup

From: Pat Gefre <pfg@sgi.com>

shubio.c cleanup
parent de39d711
...@@ -158,8 +158,6 @@ hub_ioerror_handler( ...@@ -158,8 +158,6 @@ hub_ioerror_handler(
iopaddr_t p; iopaddr_t p;
caddr_t cp; caddr_t cp;
IOERROR_DUMP("hub_ioerror_handler", error_code, mode, ioerror);
hubinfo_get(hub_v, &hinfo); hubinfo_get(hub_v, &hinfo);
if (!hinfo){ if (!hinfo){
...@@ -285,8 +283,6 @@ hub_ioerror_handler( ...@@ -285,8 +283,6 @@ hub_ioerror_handler(
IOERROR_SETVALUE(ioerror,widgetnum,widgetnum); IOERROR_SETVALUE(ioerror,widgetnum,widgetnum);
IOERROR_SETVALUE(ioerror,xtalkaddr,xtalkaddr); IOERROR_SETVALUE(ioerror,xtalkaddr,xtalkaddr);
} else { } else {
IOERROR_DUMP("hub_ioerror_handler", error_code,
mode, ioerror);
IOERR_PRINTF(printk( IOERR_PRINTF(printk(
"hub_ioerror_handler: Invalid address passed")); "hub_ioerror_handler: Invalid address passed"));
...@@ -306,11 +302,6 @@ hub_ioerror_handler( ...@@ -306,11 +302,6 @@ hub_ioerror_handler(
* widget is enabled. * widget is enabled.
*/ */
if (!is_widget_pio_enabled(ioerror)) { if (!is_widget_pio_enabled(ioerror)) {
if (error_state_get(hub_v) ==
ERROR_STATE_ACTION)
ioerror_dump("No outbound widget"
" access - ",
error_code, mode, ioerror);
return(IOERROR_HANDLED); return(IOERROR_HANDLED);
} }
...@@ -348,11 +339,6 @@ hub_ioerror_handler( ...@@ -348,11 +339,6 @@ hub_ioerror_handler(
*/ */
if (!is_widget_pio_enabled(ioerror)) { if (!is_widget_pio_enabled(ioerror)) {
if (error_state_get(hub_v) ==
ERROR_STATE_ACTION)
ioerror_dump("No outbound widget"
" access - ",
error_code, mode, ioerror);
return(IOERROR_HANDLED); return(IOERROR_HANDLED);
} }
...@@ -476,7 +462,7 @@ error_return_code_t ...@@ -476,7 +462,7 @@ error_return_code_t
error_state_set(vertex_hdl_t v,error_state_t new_state) error_state_set(vertex_hdl_t v,error_state_t new_state)
{ {
error_state_t old_state; error_state_t old_state;
boolean_t replace = B_TRUE; int replace = 1;
/* Check if we have a valid hwgraph vertex */ /* Check if we have a valid hwgraph vertex */
if ( v == (vertex_hdl_t)0 ) if ( v == (vertex_hdl_t)0 )
...@@ -495,7 +481,7 @@ error_state_set(vertex_hdl_t v,error_state_t new_state) ...@@ -495,7 +481,7 @@ error_state_set(vertex_hdl_t v,error_state_t new_state)
* for this vertex. * for this vertex.
*/ */
if (v_error_state_get(v,old_state) != GRAPH_SUCCESS) if (v_error_state_get(v,old_state) != GRAPH_SUCCESS)
replace = B_FALSE; replace = 0;
if (v_error_state_set(v,new_state,replace) != GRAPH_SUCCESS) { if (v_error_state_set(v,new_state,replace) != GRAPH_SUCCESS) {
return(ERROR_RETURN_CODE_CANNOT_SET_STATE); return(ERROR_RETURN_CODE_CANNOT_SET_STATE);
......
...@@ -231,10 +231,6 @@ hwgraph_info_get_LBL(v, INFO_LBL_ERROR_SKIP_ENV, (arbitrary_info_t *)&l) ...@@ -231,10 +231,6 @@ hwgraph_info_get_LBL(v, INFO_LBL_ERROR_SKIP_ENV, (arbitrary_info_t *)&l)
#define v_error_skip_env_clear(v) \ #define v_error_skip_env_clear(v) \
hwgraph_info_remove_LBL(v, INFO_LBL_ERROR_SKIP_ENV, 0) hwgraph_info_remove_LBL(v, INFO_LBL_ERROR_SKIP_ENV, 0)
/* Skip point interfaces */
extern error_return_code_t error_skip_point_jump(vertex_hdl_t, boolean_t);
extern error_return_code_t error_skip_point_clear(vertex_hdl_t);
/* REFERENCED */ /* REFERENCED */
#if defined(CONFIG_SGI_IO_ERROR_HANDLING) #if defined(CONFIG_SGI_IO_ERROR_HANDLING)
...@@ -284,13 +280,5 @@ extern counter_t error_retry_count_decrement(vertex_hdl_t); ...@@ -284,13 +280,5 @@ extern counter_t error_retry_count_decrement(vertex_hdl_t);
#define IS_ERROR_INTR_CONTEXT(_ec) ((_ec & IOECODE_DMA) || \ #define IS_ERROR_INTR_CONTEXT(_ec) ((_ec & IOECODE_DMA) || \
(_ec == IOECODE_PIO_WRITE)) (_ec == IOECODE_PIO_WRITE))
/* Some convenience macros on device state. This state is accessed only
* thru the calls the io error handling layer.
*/
#if defined(CONFIG_SGI_IO_ERROR_HANDLING)
extern boolean_t is_device_shutdown(vertex_hdl_t);
#define IS_DEVICE_SHUTDOWN(_d) (is_device_shutdown(_d))
#endif
#endif /* __KERNEL__ */ #endif /* __KERNEL__ */
#endif /* _ASM_IA64_SN_IOERROR_HANDLING_H */ #endif /* _ASM_IA64_SN_IOERROR_HANDLING_H */
...@@ -25,8 +25,6 @@ typedef hwgfs_handle_t vertex_hdl_t; ...@@ -25,8 +25,6 @@ typedef hwgfs_handle_t vertex_hdl_t;
#define MAXDEVNAME 256 #define MAXDEVNAME 256
#endif #endif
typedef enum { B_FALSE, B_TRUE } boolean_t;
/* /*
* Possible return values from graph routines. * Possible return values from graph routines.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment