Commit d7628d05 authored by Dave Jiang's avatar Dave Jiang Committed by Dan Williams

isci: Cleanup warning messages for phy resets

Moving some of the chattiness of warning messages to debug so only the Linux
system messages are shown.
Signed-off-by: default avatarDave Jiang <dave.jiang@intel.com>
Signed-off-by: default avatarDan Williams <dan.j.williams@intel.com>
parent 4d07f7f3
...@@ -1669,7 +1669,7 @@ void scic_sds_controller_link_up( ...@@ -1669,7 +1669,7 @@ void scic_sds_controller_link_up(
if (link_up) if (link_up)
link_up(scic, sci_port, sci_phy); link_up(scic, sci_port, sci_phy);
else else
dev_warn(scic_to_dev(scic), dev_dbg(scic_to_dev(scic),
"%s: SCIC Controller linkup event from phy %d in " "%s: SCIC Controller linkup event from phy %d in "
"unexpected state %d\n", "unexpected state %d\n",
__func__, __func__,
...@@ -1694,14 +1694,11 @@ void scic_sds_controller_link_down( ...@@ -1694,14 +1694,11 @@ void scic_sds_controller_link_down(
if (link_down) if (link_down)
link_down(scic, sci_port, sci_phy); link_down(scic, sci_port, sci_phy);
else else
dev_warn(scic_to_dev(scic), dev_dbg(scic_to_dev(scic),
"%s: SCIC Controller linkdown event from phy %d in " "%s: SCIC Controller linkdown event from phy %d in "
"unexpected state %d\n", "unexpected state %d\n",
__func__, __func__,
sci_phy->phy_index, sci_phy->phy_index, state);
sci_base_state_machine_get_state(
scic_sds_controller_get_base_state_machine(
scic)));
} }
/** /**
...@@ -1710,28 +1707,22 @@ void scic_sds_controller_link_down( ...@@ -1710,28 +1707,22 @@ void scic_sds_controller_link_down(
* *
*/ */
void scic_sds_controller_remote_device_started( void scic_sds_controller_remote_device_started(struct scic_sds_controller *scic,
struct scic_sds_controller *this_controller, struct scic_sds_remote_device *sci_dev)
struct scic_sds_remote_device *the_device)
{ {
u32 state; u32 state;
scic_sds_controller_device_handler_t remote_device_started_handler; scic_sds_controller_device_handler_t started;
state = this_controller->parent.state_machine.current_state_id; state = scic->parent.state_machine.current_state_id;
remote_device_started_handler = scic_sds_controller_state_handler_table[state].remote_device_started_handler; started = scic_sds_controller_state_handler_table[state].remote_device_started_handler;
if (remote_device_started_handler != NULL) if (started)
remote_device_started_handler(this_controller, the_device); started(scic, sci_dev);
else { else {
dev_warn(scic_to_dev(this_controller), dev_dbg(scic_to_dev(scic),
"%s: SCIC Controller 0x%p remote device started event " "%s: SCIC Controller 0x%p remote device started event "
"from device 0x%p in unexpected state %d\n", "from device 0x%p in unexpected state %d\n",
__func__, __func__, scic, sci_dev, state);
this_controller,
the_device,
sci_base_state_machine_get_state(
scic_sds_controller_get_base_state_machine(
this_controller)));
} }
} }
...@@ -1761,29 +1752,23 @@ bool scic_sds_controller_has_remote_devices_stopping( ...@@ -1761,29 +1752,23 @@ bool scic_sds_controller_has_remote_devices_stopping(
* *
*/ */
void scic_sds_controller_remote_device_stopped( void scic_sds_controller_remote_device_stopped(struct scic_sds_controller *scic,
struct scic_sds_controller *this_controller, struct scic_sds_remote_device *sci_dev)
struct scic_sds_remote_device *the_device)
{ {
u32 state; u32 state;
scic_sds_controller_device_handler_t remote_device_stopped_handler; scic_sds_controller_device_handler_t stopped;
state = this_controller->parent.state_machine.current_state_id; state = scic->parent.state_machine.current_state_id;
remote_device_stopped_handler = scic_sds_controller_state_handler_table[state].remote_device_stopped_handler; stopped = scic_sds_controller_state_handler_table[state].remote_device_stopped_handler;
if (remote_device_stopped_handler != NULL) if (stopped)
remote_device_stopped_handler(this_controller, the_device); stopped(scic, sci_dev);
else { else {
dev_warn(scic_to_dev(this_controller), dev_dbg(scic_to_dev(scic),
"%s: SCIC Controller 0x%p remote device stopped event " "%s: SCIC Controller 0x%p remote device stopped event "
"from device 0x%p in unexpected state %d\n", "from device 0x%p in unexpected state %d\n",
__func__, __func__, scic, sci_dev, state);
this_controller,
the_device,
sci_base_state_machine_get_state(
scic_sds_controller_get_base_state_machine(
this_controller)));
} }
} }
......
...@@ -808,11 +808,11 @@ static enum sci_status scic_sds_phy_starting_substate_await_ossp_event_handler( ...@@ -808,11 +808,11 @@ static enum sci_status scic_sds_phy_starting_substate_await_ossp_event_handler(
break; break;
default: default:
dev_warn(sciphy_to_dev(this_phy), dev_dbg(sciphy_to_dev(this_phy),
"%s: PHY starting substate machine received " "%s: PHY starting substate machine received "
"unexpected event_code %x\n", "unexpected event_code %x\n",
__func__, __func__,
event_code); event_code);
result = SCI_FAILURE; result = SCI_FAILURE;
break; break;
...@@ -2000,26 +2000,24 @@ enum sci_status scic_sds_phy_default_start_handler( ...@@ -2000,26 +2000,24 @@ enum sci_status scic_sds_phy_default_start_handler(
/** /**
* *
* @phy: This is the struct sci_base_phy object which is cast into a struct scic_sds_phy * @phy: This is the struct sci_base_phy object which is cast into a
* object. * struct scic_sds_phy object.
* *
* This is the default method for phy a stop request. It will report a warning * This is the default method for phy a stop request. It will report a warning
* and exit. enum sci_status SCI_FAILURE_INVALID_STATE * and exit. enum sci_status SCI_FAILURE_INVALID_STATE
*/ */
enum sci_status scic_sds_phy_default_stop_handler( enum sci_status scic_sds_phy_default_stop_handler(struct sci_base_phy *base_phy)
struct sci_base_phy *phy)
{ {
struct scic_sds_phy *this_phy; struct scic_sds_phy *sci_phy;
this_phy = (struct scic_sds_phy *)phy; sci_phy = (struct scic_sds_phy *)base_phy;
dev_warn(sciphy_to_dev(this_phy), dev_dbg(sciphy_to_dev(sci_phy),
"%s: SCIC Phy 0x%p requested to stop from invalid " "%s: SCIC Phy 0x%p requested to stop from invalid state %d\n",
"state %d\n", __func__,
__func__, sci_phy,
this_phy, sci_base_state_machine_get_state(
sci_base_state_machine_get_state( &sci_phy->parent.state_machine));
&this_phy->parent.state_machine));
return SCI_FAILURE_INVALID_STATE; return SCI_FAILURE_INVALID_STATE;
} }
...@@ -2119,7 +2117,7 @@ enum sci_status scic_sds_phy_default_event_handler( ...@@ -2119,7 +2117,7 @@ enum sci_status scic_sds_phy_default_event_handler(
struct scic_sds_phy *this_phy, struct scic_sds_phy *this_phy,
u32 event_code) u32 event_code)
{ {
dev_warn(sciphy_to_dev(this_phy), dev_dbg(sciphy_to_dev(this_phy),
"%s: SCIC Phy 0x%p received unexpected event status %x " "%s: SCIC Phy 0x%p received unexpected event status %x "
"while in state %d\n", "while in state %d\n",
__func__, __func__,
......
...@@ -472,7 +472,7 @@ void isci_remote_device_gone( ...@@ -472,7 +472,7 @@ void isci_remote_device_gone(
struct isci_remote_device *isci_device = isci_dev_from_domain_dev( struct isci_remote_device *isci_device = isci_dev_from_domain_dev(
domain_dev); domain_dev);
dev_err(&isci_device->isci_port->isci_host->pdev->dev, dev_dbg(&isci_device->isci_port->isci_host->pdev->dev,
"%s: domain_device = %p, isci_device = %p, isci_port = %p\n", "%s: domain_device = %p, isci_device = %p, isci_port = %p\n",
__func__, domain_dev, isci_device, isci_device->isci_port); __func__, domain_dev, isci_device, isci_device->isci_port);
......
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