mirror of
				git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
				synced 2025-11-01 09:13:37 +00:00 
			
		
		
		
	gpio: mark expected switch fall-throughs
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
This commit is contained in:
		
							parent
							
								
									609aaf6a60
								
							
						
					
					
						commit
						e80df7b823
					
				
					 3 changed files with 6 additions and 2 deletions
				
			
		| 
						 | 
				
			
			@ -411,13 +411,16 @@ static int aspeed_gpio_set_type(struct irq_data *d, unsigned int type)
 | 
			
		|||
	switch (type & IRQ_TYPE_SENSE_MASK) {
 | 
			
		||||
	case IRQ_TYPE_EDGE_BOTH:
 | 
			
		||||
		type2 |= bit;
 | 
			
		||||
		/* fall through */
 | 
			
		||||
	case IRQ_TYPE_EDGE_RISING:
 | 
			
		||||
		type0 |= bit;
 | 
			
		||||
		/* fall through */
 | 
			
		||||
	case IRQ_TYPE_EDGE_FALLING:
 | 
			
		||||
		handler = handle_edge_irq;
 | 
			
		||||
		break;
 | 
			
		||||
	case IRQ_TYPE_LEVEL_HIGH:
 | 
			
		||||
		type0 |= bit;
 | 
			
		||||
		/* fall through */
 | 
			
		||||
	case IRQ_TYPE_LEVEL_LOW:
 | 
			
		||||
		type1 |= bit;
 | 
			
		||||
		handler = handle_level_irq;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -132,6 +132,7 @@ static int ath79_gpio_irq_set_type(struct irq_data *data,
 | 
			
		|||
 | 
			
		||||
	case IRQ_TYPE_LEVEL_HIGH:
 | 
			
		||||
		polarity |= mask;
 | 
			
		||||
		/* fall through */
 | 
			
		||||
	case IRQ_TYPE_LEVEL_LOW:
 | 
			
		||||
		type |= mask;
 | 
			
		||||
		break;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -299,7 +299,7 @@ static void stmpe_dbg_show_one(struct seq_file *s,
 | 
			
		|||
			if (ret < 0)
 | 
			
		||||
				return;
 | 
			
		||||
			edge_det = !!(ret & mask);
 | 
			
		||||
 | 
			
		||||
			/* fall through */
 | 
			
		||||
		case STMPE1801:
 | 
			
		||||
			rise_reg = stmpe->regs[STMPE_IDX_GPRER_LSB + bank];
 | 
			
		||||
			fall_reg = stmpe->regs[STMPE_IDX_GPFER_LSB + bank];
 | 
			
		||||
| 
						 | 
				
			
			@ -312,7 +312,7 @@ static void stmpe_dbg_show_one(struct seq_file *s,
 | 
			
		|||
			if (ret < 0)
 | 
			
		||||
				return;
 | 
			
		||||
			fall = !!(ret & mask);
 | 
			
		||||
 | 
			
		||||
			/* fall through */
 | 
			
		||||
		case STMPE801:
 | 
			
		||||
		case STMPE1600:
 | 
			
		||||
			irqen_reg = stmpe->regs[STMPE_IDX_IEGPIOR_LSB + bank];
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		
		Reference in a new issue