Re: [PATCH] drm/amdgpu: remove unneeded break

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am 19.10.20 um 16:43 schrieb trix@xxxxxxxxxx:
From: Tom Rix <trix@xxxxxxxxxx>

A break is not needed if it is preceded by a return or break

Signed-off-by: Tom Rix <trix@xxxxxxxxxx>

Acked-by: Christian König <christian.koenig@xxxxxxx>

---
  drivers/gpu/drm/amd/display/dc/dce/dce_transform.c      | 1 -
  drivers/gpu/drm/amd/display/dc/dce100/dce100_resource.c | 7 -------
  drivers/gpu/drm/amd/display/dc/dce110/dce110_resource.c | 7 -------
  drivers/gpu/drm/amd/display/dc/dce112/dce112_resource.c | 7 -------
  drivers/gpu/drm/amd/display/dc/dce120/dce120_resource.c | 7 -------
  drivers/gpu/drm/amd/display/dc/dce60/dce60_resource.c   | 7 -------
  drivers/gpu/drm/amd/display/dc/dce80/dce80_resource.c   | 7 -------
  7 files changed, 43 deletions(-)

diff --git a/drivers/gpu/drm/amd/display/dc/dce/dce_transform.c b/drivers/gpu/drm/amd/display/dc/dce/dce_transform.c
index 2a32b66959ba..130a0a0c8332 100644
--- a/drivers/gpu/drm/amd/display/dc/dce/dce_transform.c
+++ b/drivers/gpu/drm/amd/display/dc/dce/dce_transform.c
@@ -1330,7 +1330,6 @@ static bool configure_graphics_mode(
  			REG_SET(OUTPUT_CSC_CONTROL, 0,
  				OUTPUT_CSC_GRPH_MODE, 0);
  			break;
-			break;
  		case COLOR_SPACE_SRGB_LIMITED:
  			/* TV RGB */
  			REG_SET(OUTPUT_CSC_CONTROL, 0,
diff --git a/drivers/gpu/drm/amd/display/dc/dce100/dce100_resource.c b/drivers/gpu/drm/amd/display/dc/dce100/dce100_resource.c
index d741787f75dc..42c7d157da32 100644
--- a/drivers/gpu/drm/amd/display/dc/dce100/dce100_resource.c
+++ b/drivers/gpu/drm/amd/display/dc/dce100/dce100_resource.c
@@ -418,25 +418,18 @@ static int map_transmitter_id_to_phy_instance(
  	switch (transmitter) {
  	case TRANSMITTER_UNIPHY_A:
  		return 0;
-	break;
  	case TRANSMITTER_UNIPHY_B:
  		return 1;
-	break;
  	case TRANSMITTER_UNIPHY_C:
  		return 2;
-	break;
  	case TRANSMITTER_UNIPHY_D:
  		return 3;
-	break;
  	case TRANSMITTER_UNIPHY_E:
  		return 4;
-	break;
  	case TRANSMITTER_UNIPHY_F:
  		return 5;
-	break;
  	case TRANSMITTER_UNIPHY_G:
  		return 6;
-	break;
  	default:
  		ASSERT(0);
  		return 0;
diff --git a/drivers/gpu/drm/amd/display/dc/dce110/dce110_resource.c b/drivers/gpu/drm/amd/display/dc/dce110/dce110_resource.c
index 2bbfa2e176a9..382581c4a674 100644
--- a/drivers/gpu/drm/amd/display/dc/dce110/dce110_resource.c
+++ b/drivers/gpu/drm/amd/display/dc/dce110/dce110_resource.c
@@ -471,25 +471,18 @@ static int map_transmitter_id_to_phy_instance(
  	switch (transmitter) {
  	case TRANSMITTER_UNIPHY_A:
  		return 0;
-	break;
  	case TRANSMITTER_UNIPHY_B:
  		return 1;
-	break;
  	case TRANSMITTER_UNIPHY_C:
  		return 2;
-	break;
  	case TRANSMITTER_UNIPHY_D:
  		return 3;
-	break;
  	case TRANSMITTER_UNIPHY_E:
  		return 4;
-	break;
  	case TRANSMITTER_UNIPHY_F:
  		return 5;
-	break;
  	case TRANSMITTER_UNIPHY_G:
  		return 6;
-	break;
  	default:
  		ASSERT(0);
  		return 0;
diff --git a/drivers/gpu/drm/amd/display/dc/dce112/dce112_resource.c b/drivers/gpu/drm/amd/display/dc/dce112/dce112_resource.c
index b622b4b1dac3..7b4b2304bbff 100644
--- a/drivers/gpu/drm/amd/display/dc/dce112/dce112_resource.c
+++ b/drivers/gpu/drm/amd/display/dc/dce112/dce112_resource.c
@@ -446,25 +446,18 @@ static int map_transmitter_id_to_phy_instance(
  	switch (transmitter) {
  	case TRANSMITTER_UNIPHY_A:
  		return 0;
-	break;
  	case TRANSMITTER_UNIPHY_B:
  		return 1;
-	break;
  	case TRANSMITTER_UNIPHY_C:
  		return 2;
-	break;
  	case TRANSMITTER_UNIPHY_D:
  		return 3;
-	break;
  	case TRANSMITTER_UNIPHY_E:
  		return 4;
-	break;
  	case TRANSMITTER_UNIPHY_F:
  		return 5;
-	break;
  	case TRANSMITTER_UNIPHY_G:
  		return 6;
-	break;
  	default:
  		ASSERT(0);
  		return 0;
diff --git a/drivers/gpu/drm/amd/display/dc/dce120/dce120_resource.c b/drivers/gpu/drm/amd/display/dc/dce120/dce120_resource.c
index 16fe7344702f..3d782b7c86cb 100644
--- a/drivers/gpu/drm/amd/display/dc/dce120/dce120_resource.c
+++ b/drivers/gpu/drm/amd/display/dc/dce120/dce120_resource.c
@@ -383,25 +383,18 @@ static int map_transmitter_id_to_phy_instance(
  	switch (transmitter) {
  	case TRANSMITTER_UNIPHY_A:
  		return 0;
-	break;
  	case TRANSMITTER_UNIPHY_B:
  		return 1;
-	break;
  	case TRANSMITTER_UNIPHY_C:
  		return 2;
-	break;
  	case TRANSMITTER_UNIPHY_D:
  		return 3;
-	break;
  	case TRANSMITTER_UNIPHY_E:
  		return 4;
-	break;
  	case TRANSMITTER_UNIPHY_F:
  		return 5;
-	break;
  	case TRANSMITTER_UNIPHY_G:
  		return 6;
-	break;
  	default:
  		ASSERT(0);
  		return 0;
diff --git a/drivers/gpu/drm/amd/display/dc/dce60/dce60_resource.c b/drivers/gpu/drm/amd/display/dc/dce60/dce60_resource.c
index 5a5a9cb77acb..e9dd78c484d6 100644
--- a/drivers/gpu/drm/amd/display/dc/dce60/dce60_resource.c
+++ b/drivers/gpu/drm/amd/display/dc/dce60/dce60_resource.c
@@ -453,25 +453,18 @@ static int map_transmitter_id_to_phy_instance(
  	switch (transmitter) {
  	case TRANSMITTER_UNIPHY_A:
  		return 0;
-	break;
  	case TRANSMITTER_UNIPHY_B:
  		return 1;
-	break;
  	case TRANSMITTER_UNIPHY_C:
  		return 2;
-	break;
  	case TRANSMITTER_UNIPHY_D:
  		return 3;
-	break;
  	case TRANSMITTER_UNIPHY_E:
  		return 4;
-	break;
  	case TRANSMITTER_UNIPHY_F:
  		return 5;
-	break;
  	case TRANSMITTER_UNIPHY_G:
  		return 6;
-	break;
  	default:
  		ASSERT(0);
  		return 0;
diff --git a/drivers/gpu/drm/amd/display/dc/dce80/dce80_resource.c b/drivers/gpu/drm/amd/display/dc/dce80/dce80_resource.c
index 0eae8cd35f9a..9dbf658162cd 100644
--- a/drivers/gpu/drm/amd/display/dc/dce80/dce80_resource.c
+++ b/drivers/gpu/drm/amd/display/dc/dce80/dce80_resource.c
@@ -458,25 +458,18 @@ static int map_transmitter_id_to_phy_instance(
  	switch (transmitter) {
  	case TRANSMITTER_UNIPHY_A:
  		return 0;
-	break;
  	case TRANSMITTER_UNIPHY_B:
  		return 1;
-	break;
  	case TRANSMITTER_UNIPHY_C:
  		return 2;
-	break;
  	case TRANSMITTER_UNIPHY_D:
  		return 3;
-	break;
  	case TRANSMITTER_UNIPHY_E:
  		return 4;
-	break;
  	case TRANSMITTER_UNIPHY_F:
  		return 5;
-	break;
  	case TRANSMITTER_UNIPHY_G:
  		return 6;
-	break;
  	default:
  		ASSERT(0);
  		return 0;

_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/dri-devel




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux