소스 검색

add:写gpio禁中断

Dozingfiretruck 3 년 전
부모
커밋
cab7b6af3c
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      platform/drivers/gpio/wm_gpio.c

+ 2 - 2
platform/drivers/gpio/wm_gpio.c

@@ -202,7 +202,7 @@ __attribute__((section (".ram_run"))) void tls_gpio_write(enum tls_io_name gpio_
     }
 
 	
-	// cpu_sr = tls_os_set_critical();
+	cpu_sr = tls_os_set_critical();
 	
 	// reg_en = tls_reg_read32(HR_GPIO_DATA_EN + offset);
 	// tls_reg_write32(HR_GPIO_DATA_EN + offset, reg_en | (1 << pin));
@@ -215,7 +215,7 @@ __attribute__((section (".ram_run"))) void tls_gpio_write(enum tls_io_name gpio_
 
     // tls_reg_write32(HR_GPIO_DATA_EN + offset, reg_en);
 
-	// tls_os_release_critical(cpu_sr);
+	tls_os_release_critical(cpu_sr);
 }
 
 //add by hyj, 2022-05-20