bsp:ls2k:gpio read typo error,fix it.

from ls2k user manuanl know that GPIO0_I is input, GPIO1_I is reserved.
here typo error, fix it.
This commit is contained in:
michael 2020-08-24 09:12:41 +08:00
parent b4f75d1ef8
commit 9d742141b8
1 changed files with 1 additions and 1 deletions

View File

@ -73,7 +73,7 @@ static int loongson_pin_read(struct rt_device *device, rt_base_t pin)
gpio = (void *)device->user_data;
rt_uint64_t m;
m = gpio->GPIO1_I;
m = gpio->GPIO0_I;
m &= (rt_uint64_t)1 << pin;
rc = !!m;