@@ -158,6 +158,7 @@ impl Peripherals {
158158 }
159159
160160 /// Unchecked version of `Peripherals::take`
161+ #[ inline]
161162 pub unsafe fn steal ( ) -> Self {
162163 CORE_PERIPHERALS = true ;
163164
@@ -211,13 +212,15 @@ unsafe impl Send for CBP {}
211212
212213#[ cfg( not( armv6m) ) ]
213214impl CBP {
215+ #[ inline( always) ]
214216 pub ( crate ) unsafe fn new ( ) -> Self {
215217 CBP {
216218 _marker : PhantomData ,
217219 }
218220 }
219221
220222 /// Returns a pointer to the register block
223+ #[ inline( always) ]
221224 pub fn ptr ( ) -> * const self :: cbp:: RegisterBlock {
222225 0xE000_EF50 as * const _
223226 }
@@ -227,6 +230,7 @@ impl CBP {
227230impl ops:: Deref for CBP {
228231 type Target = self :: cbp:: RegisterBlock ;
229232
233+ #[ inline( always) ]
230234 fn deref ( & self ) -> & Self :: Target {
231235 unsafe { & * Self :: ptr ( ) }
232236 }
@@ -241,6 +245,7 @@ unsafe impl Send for CPUID {}
241245
242246impl CPUID {
243247 /// Returns a pointer to the register block
248+ #[ inline( always) ]
244249 pub fn ptr ( ) -> * const self :: cpuid:: RegisterBlock {
245250 0xE000_ED00 as * const _
246251 }
@@ -249,6 +254,7 @@ impl CPUID {
249254impl ops:: Deref for CPUID {
250255 type Target = self :: cpuid:: RegisterBlock ;
251256
257+ #[ inline( always) ]
252258 fn deref ( & self ) -> & Self :: Target {
253259 unsafe { & * Self :: ptr ( ) }
254260 }
@@ -263,6 +269,7 @@ unsafe impl Send for DCB {}
263269
264270impl DCB {
265271 /// Returns a pointer to the register block
272+ #[ inline( always) ]
266273 pub fn ptr ( ) -> * const dcb:: RegisterBlock {
267274 0xE000_EDF0 as * const _
268275 }
@@ -271,6 +278,7 @@ impl DCB {
271278impl ops:: Deref for DCB {
272279 type Target = self :: dcb:: RegisterBlock ;
273280
281+ #[ inline( always) ]
274282 fn deref ( & self ) -> & Self :: Target {
275283 unsafe { & * DCB :: ptr ( ) }
276284 }
@@ -285,6 +293,7 @@ unsafe impl Send for DWT {}
285293
286294impl DWT {
287295 /// Returns a pointer to the register block
296+ #[ inline( always) ]
288297 pub fn ptr ( ) -> * const dwt:: RegisterBlock {
289298 0xE000_1000 as * const _
290299 }
@@ -293,6 +302,7 @@ impl DWT {
293302impl ops:: Deref for DWT {
294303 type Target = self :: dwt:: RegisterBlock ;
295304
305+ #[ inline( always) ]
296306 fn deref ( & self ) -> & Self :: Target {
297307 unsafe { & * Self :: ptr ( ) }
298308 }
@@ -308,6 +318,7 @@ unsafe impl Send for FPB {}
308318#[ cfg( not( armv6m) ) ]
309319impl FPB {
310320 /// Returns a pointer to the register block
321+ #[ inline( always) ]
311322 pub fn ptr ( ) -> * const fpb:: RegisterBlock {
312323 0xE000_2000 as * const _
313324 }
@@ -317,6 +328,7 @@ impl FPB {
317328impl ops:: Deref for FPB {
318329 type Target = self :: fpb:: RegisterBlock ;
319330
331+ #[ inline( always) ]
320332 fn deref ( & self ) -> & Self :: Target {
321333 unsafe { & * Self :: ptr ( ) }
322334 }
@@ -332,6 +344,7 @@ unsafe impl Send for FPU {}
332344#[ cfg( any( has_fpu, target_arch = "x86_64" ) ) ]
333345impl FPU {
334346 /// Returns a pointer to the register block
347+ #[ inline( always) ]
335348 pub fn ptr ( ) -> * const fpu:: RegisterBlock {
336349 0xE000_EF30 as * const _
337350 }
@@ -341,6 +354,7 @@ impl FPU {
341354impl ops:: Deref for FPU {
342355 type Target = self :: fpu:: RegisterBlock ;
343356
357+ #[ inline( always) ]
344358 fn deref ( & self ) -> & Self :: Target {
345359 unsafe { & * Self :: ptr ( ) }
346360 }
@@ -356,6 +370,7 @@ unsafe impl Send for ITM {}
356370#[ cfg( not( armv6m) ) ]
357371impl ITM {
358372 /// Returns a pointer to the register block
373+ #[ inline( always) ]
359374 pub fn ptr ( ) -> * mut itm:: RegisterBlock {
360375 0xE000_0000 as * mut _
361376 }
@@ -365,13 +380,15 @@ impl ITM {
365380impl ops:: Deref for ITM {
366381 type Target = self :: itm:: RegisterBlock ;
367382
383+ #[ inline( always) ]
368384 fn deref ( & self ) -> & Self :: Target {
369385 unsafe { & * Self :: ptr ( ) }
370386 }
371387}
372388
373389#[ cfg( not( armv6m) ) ]
374390impl ops:: DerefMut for ITM {
391+ #[ inline( always) ]
375392 fn deref_mut ( & mut self ) -> & mut Self :: Target {
376393 unsafe { & mut * Self :: ptr ( ) }
377394 }
@@ -386,6 +403,7 @@ unsafe impl Send for MPU {}
386403
387404impl MPU {
388405 /// Returns a pointer to the register block
406+ #[ inline( always) ]
389407 pub fn ptr ( ) -> * const mpu:: RegisterBlock {
390408 0xE000_ED90 as * const _
391409 }
@@ -394,6 +412,7 @@ impl MPU {
394412impl ops:: Deref for MPU {
395413 type Target = self :: mpu:: RegisterBlock ;
396414
415+ #[ inline( always) ]
397416 fn deref ( & self ) -> & Self :: Target {
398417 unsafe { & * Self :: ptr ( ) }
399418 }
@@ -408,6 +427,7 @@ unsafe impl Send for NVIC {}
408427
409428impl NVIC {
410429 /// Returns a pointer to the register block
430+ #[ inline( always) ]
411431 pub fn ptr ( ) -> * const nvic:: RegisterBlock {
412432 0xE000_E100 as * const _
413433 }
@@ -416,6 +436,7 @@ impl NVIC {
416436impl ops:: Deref for NVIC {
417437 type Target = self :: nvic:: RegisterBlock ;
418438
439+ #[ inline( always) ]
419440 fn deref ( & self ) -> & Self :: Target {
420441 unsafe { & * Self :: ptr ( ) }
421442 }
@@ -430,6 +451,7 @@ unsafe impl Send for SCB {}
430451
431452impl SCB {
432453 /// Returns a pointer to the register block
454+ #[ inline( always) ]
433455 pub fn ptr ( ) -> * const scb:: RegisterBlock {
434456 0xE000_ED04 as * const _
435457 }
@@ -438,6 +460,7 @@ impl SCB {
438460impl ops:: Deref for SCB {
439461 type Target = self :: scb:: RegisterBlock ;
440462
463+ #[ inline( always) ]
441464 fn deref ( & self ) -> & Self :: Target {
442465 unsafe { & * Self :: ptr ( ) }
443466 }
@@ -452,6 +475,7 @@ unsafe impl Send for SYST {}
452475
453476impl SYST {
454477 /// Returns a pointer to the register block
478+ #[ inline( always) ]
455479 pub fn ptr ( ) -> * const syst:: RegisterBlock {
456480 0xE000_E010 as * const _
457481 }
@@ -460,6 +484,7 @@ impl SYST {
460484impl ops:: Deref for SYST {
461485 type Target = self :: syst:: RegisterBlock ;
462486
487+ #[ inline( always) ]
463488 fn deref ( & self ) -> & Self :: Target {
464489 unsafe { & * Self :: ptr ( ) }
465490 }
@@ -475,6 +500,7 @@ unsafe impl Send for TPIU {}
475500#[ cfg( not( armv6m) ) ]
476501impl TPIU {
477502 /// Returns a pointer to the register block
503+ #[ inline( always) ]
478504 pub fn ptr ( ) -> * const tpiu:: RegisterBlock {
479505 0xE004_0000 as * const _
480506 }
@@ -484,6 +510,7 @@ impl TPIU {
484510impl ops:: Deref for TPIU {
485511 type Target = self :: tpiu:: RegisterBlock ;
486512
513+ #[ inline( always) ]
487514 fn deref ( & self ) -> & Self :: Target {
488515 unsafe { & * Self :: ptr ( ) }
489516 }
0 commit comments