@@ -243,7 +243,7 @@ impl CBP {
243
243
/// Returns a pointer to the register block (to be deprecated in 0.7)
244
244
#[ inline( always) ]
245
245
pub const fn ptr ( ) -> * const self :: cbp:: RegisterBlock {
246
- 0xE000_EF50 as * const _
246
+ Self :: PTR
247
247
}
248
248
}
249
249
@@ -253,7 +253,7 @@ impl ops::Deref for CBP {
253
253
254
254
#[ inline( always) ]
255
255
fn deref ( & self ) -> & Self :: Target {
256
- unsafe { & * Self :: ptr ( ) }
256
+ unsafe { & * Self :: PTR }
257
257
}
258
258
}
259
259
@@ -271,7 +271,7 @@ impl CPUID {
271
271
/// Returns a pointer to the register block (to be deprecated in 0.7)
272
272
#[ inline( always) ]
273
273
pub const fn ptr ( ) -> * const self :: cpuid:: RegisterBlock {
274
- 0xE000_ED00 as * const _
274
+ Self :: PTR
275
275
}
276
276
}
277
277
@@ -280,7 +280,7 @@ impl ops::Deref for CPUID {
280
280
281
281
#[ inline( always) ]
282
282
fn deref ( & self ) -> & Self :: Target {
283
- unsafe { & * Self :: ptr ( ) }
283
+ unsafe { & * Self :: PTR }
284
284
}
285
285
}
286
286
@@ -298,7 +298,7 @@ impl DCB {
298
298
/// Returns a pointer to the register block (to be deprecated in 0.7)
299
299
#[ inline( always) ]
300
300
pub const fn ptr ( ) -> * const dcb:: RegisterBlock {
301
- 0xE000_EDF0 as * const _
301
+ Self :: PTR
302
302
}
303
303
}
304
304
@@ -307,7 +307,7 @@ impl ops::Deref for DCB {
307
307
308
308
#[ inline( always) ]
309
309
fn deref ( & self ) -> & Self :: Target {
310
- unsafe { & * DCB :: ptr ( ) }
310
+ unsafe { & * DCB :: PTR }
311
311
}
312
312
}
313
313
@@ -325,7 +325,7 @@ impl DWT {
325
325
/// Returns a pointer to the register block (to be deprecated in 0.7)
326
326
#[ inline( always) ]
327
327
pub const fn ptr ( ) -> * const dwt:: RegisterBlock {
328
- 0xE000_1000 as * const _
328
+ Self :: PTR
329
329
}
330
330
}
331
331
@@ -334,7 +334,7 @@ impl ops::Deref for DWT {
334
334
335
335
#[ inline( always) ]
336
336
fn deref ( & self ) -> & Self :: Target {
337
- unsafe { & * Self :: ptr ( ) }
337
+ unsafe { & * Self :: PTR }
338
338
}
339
339
}
340
340
@@ -353,7 +353,7 @@ impl FPB {
353
353
/// Returns a pointer to the register block (to be deprecated in 0.7)
354
354
#[ inline( always) ]
355
355
pub const fn ptr ( ) -> * const fpb:: RegisterBlock {
356
- 0xE000_2000 as * const _
356
+ Self :: PTR
357
357
}
358
358
}
359
359
@@ -363,7 +363,7 @@ impl ops::Deref for FPB {
363
363
364
364
#[ inline( always) ]
365
365
fn deref ( & self ) -> & Self :: Target {
366
- unsafe { & * Self :: ptr ( ) }
366
+ unsafe { & * Self :: PTR }
367
367
}
368
368
}
369
369
@@ -382,7 +382,7 @@ impl FPU {
382
382
/// Returns a pointer to the register block (to be deprecated in 0.7)
383
383
#[ inline( always) ]
384
384
pub const fn ptr ( ) -> * const fpu:: RegisterBlock {
385
- 0xE000_EF30 as * const _
385
+ Self :: PTR
386
386
}
387
387
}
388
388
@@ -392,7 +392,7 @@ impl ops::Deref for FPU {
392
392
393
393
#[ inline( always) ]
394
394
fn deref ( & self ) -> & Self :: Target {
395
- unsafe { & * Self :: ptr ( ) }
395
+ unsafe { & * Self :: PTR }
396
396
}
397
397
}
398
398
@@ -415,7 +415,7 @@ impl ICB {
415
415
/// Returns a pointer to the register block (to be deprecated in 0.7)
416
416
#[ inline( always) ]
417
417
pub const fn ptr ( ) -> * mut icb:: RegisterBlock {
418
- 0xE000_E004 as * mut _
418
+ Self :: PTR
419
419
}
420
420
}
421
421
@@ -424,14 +424,14 @@ impl ops::Deref for ICB {
424
424
425
425
#[ inline( always) ]
426
426
fn deref ( & self ) -> & Self :: Target {
427
- unsafe { & * Self :: ptr ( ) }
427
+ unsafe { & * Self :: PTR }
428
428
}
429
429
}
430
430
431
431
impl ops:: DerefMut for ICB {
432
432
#[ inline( always) ]
433
433
fn deref_mut ( & mut self ) -> & mut Self :: Target {
434
- unsafe { & mut * Self :: ptr ( ) }
434
+ unsafe { & mut * Self :: PTR }
435
435
}
436
436
}
437
437
@@ -450,7 +450,7 @@ impl ITM {
450
450
/// Returns a pointer to the register block (to be deprecated in 0.7)
451
451
#[ inline( always) ]
452
452
pub const fn ptr ( ) -> * mut itm:: RegisterBlock {
453
- 0xE000_0000 as * mut _
453
+ Self :: PTR
454
454
}
455
455
}
456
456
@@ -460,15 +460,15 @@ impl ops::Deref for ITM {
460
460
461
461
#[ inline( always) ]
462
462
fn deref ( & self ) -> & Self :: Target {
463
- unsafe { & * Self :: ptr ( ) }
463
+ unsafe { & * Self :: PTR }
464
464
}
465
465
}
466
466
467
467
#[ cfg( all( not( armv6m) , not( armv8m_base) ) ) ]
468
468
impl ops:: DerefMut for ITM {
469
469
#[ inline( always) ]
470
470
fn deref_mut ( & mut self ) -> & mut Self :: Target {
471
- unsafe { & mut * Self :: ptr ( ) }
471
+ unsafe { & mut * Self :: PTR }
472
472
}
473
473
}
474
474
@@ -486,7 +486,7 @@ impl MPU {
486
486
/// Returns a pointer to the register block (to be deprecated in 0.7)
487
487
#[ inline( always) ]
488
488
pub const fn ptr ( ) -> * const mpu:: RegisterBlock {
489
- 0xE000_ED90 as * const _
489
+ Self :: PTR
490
490
}
491
491
}
492
492
@@ -495,7 +495,7 @@ impl ops::Deref for MPU {
495
495
496
496
#[ inline( always) ]
497
497
fn deref ( & self ) -> & Self :: Target {
498
- unsafe { & * Self :: ptr ( ) }
498
+ unsafe { & * Self :: PTR }
499
499
}
500
500
}
501
501
@@ -513,7 +513,7 @@ impl NVIC {
513
513
/// Returns a pointer to the register block (to be deprecated in 0.7)
514
514
#[ inline( always) ]
515
515
pub const fn ptr ( ) -> * const nvic:: RegisterBlock {
516
- 0xE000_E100 as * const _
516
+ Self :: PTR
517
517
}
518
518
}
519
519
@@ -522,7 +522,7 @@ impl ops::Deref for NVIC {
522
522
523
523
#[ inline( always) ]
524
524
fn deref ( & self ) -> & Self :: Target {
525
- unsafe { & * Self :: ptr ( ) }
525
+ unsafe { & * Self :: PTR }
526
526
}
527
527
}
528
528
@@ -541,7 +541,7 @@ impl SAU {
541
541
/// Returns a pointer to the register block (to be deprecated in 0.7)
542
542
#[ inline( always) ]
543
543
pub const fn ptr ( ) -> * const sau:: RegisterBlock {
544
- 0xE000_EDD0 as * const _
544
+ Self :: PTR
545
545
}
546
546
}
547
547
@@ -551,7 +551,7 @@ impl ops::Deref for SAU {
551
551
552
552
#[ inline( always) ]
553
553
fn deref ( & self ) -> & Self :: Target {
554
- unsafe { & * Self :: ptr ( ) }
554
+ unsafe { & * Self :: PTR }
555
555
}
556
556
}
557
557
@@ -569,7 +569,7 @@ impl SCB {
569
569
/// Returns a pointer to the register block (to be deprecated in 0.7)
570
570
#[ inline( always) ]
571
571
pub const fn ptr ( ) -> * const scb:: RegisterBlock {
572
- 0xE000_ED04 as * const _
572
+ Self :: PTR
573
573
}
574
574
}
575
575
@@ -578,7 +578,7 @@ impl ops::Deref for SCB {
578
578
579
579
#[ inline( always) ]
580
580
fn deref ( & self ) -> & Self :: Target {
581
- unsafe { & * Self :: ptr ( ) }
581
+ unsafe { & * Self :: PTR }
582
582
}
583
583
}
584
584
@@ -596,7 +596,7 @@ impl SYST {
596
596
/// Returns a pointer to the register block (to be deprecated in 0.7)
597
597
#[ inline( always) ]
598
598
pub const fn ptr ( ) -> * const syst:: RegisterBlock {
599
- 0xE000_E010 as * const _
599
+ Self :: PTR
600
600
}
601
601
}
602
602
@@ -605,7 +605,7 @@ impl ops::Deref for SYST {
605
605
606
606
#[ inline( always) ]
607
607
fn deref ( & self ) -> & Self :: Target {
608
- unsafe { & * Self :: ptr ( ) }
608
+ unsafe { & * Self :: PTR }
609
609
}
610
610
}
611
611
@@ -624,7 +624,7 @@ impl TPIU {
624
624
/// Returns a pointer to the register block (to be deprecated in 0.7)
625
625
#[ inline( always) ]
626
626
pub const fn ptr ( ) -> * const tpiu:: RegisterBlock {
627
- 0xE004_0000 as * const _
627
+ Self :: PTR
628
628
}
629
629
}
630
630
@@ -634,6 +634,6 @@ impl ops::Deref for TPIU {
634
634
635
635
#[ inline( always) ]
636
636
fn deref ( & self ) -> & Self :: Target {
637
- unsafe { & * Self :: ptr ( ) }
637
+ unsafe { & * Self :: PTR }
638
638
}
639
639
}
0 commit comments