File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
components/drivers/serial Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -30,11 +30,11 @@ int serial_dev_set_name(struct rt_serial_device *sdev)
3030 id = rt_ofw_get_alias_id (sdev -> parent .ofw_node , "uart" );
3131 }
3232 }
33- #endif
33+ #endif /* RT_USING_OFW */
3434
3535 if (id < 0 )
3636 {
37- id = (int )rt_hw_atomic_add (& uid , 1 );
37+ id = (int )rt_atomic_add (& uid , 1 );
3838 }
3939
4040 return rt_dm_dev_set_name (& sdev -> parent , "uart%u" , id );
@@ -53,7 +53,7 @@ static int serial_dm_naming_framework_init(void)
5353 uid_min = uid_min < 0 ? 0 : (uid_min + 1 );
5454
5555 rt_hw_atomic_store (& uid , uid_min );
56- #endif
56+ #endif /* RT_USING_OFW */
5757
5858 return 0 ;
5959}
@@ -154,7 +154,7 @@ struct serial_configure serial_cfg_from_args(char *_str)
154154 rt_memset (str , 0 , RT_ARRAY_SIZE (earlycon_magic ));
155155 }
156156 }
157- #endif
157+ #endif /* RT_USING_OFW */
158158 }
159159
160160 return cfg ;
You can’t perform that action at this time.
0 commit comments