schakrabarti

Untitled

May 15th, 2023
53
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.84 KB | None | 0 0
  1. diff --git a/sys/dev/hyperv/vmbus/aarch64/vmbus_aarch64.c b/sys/dev/hyperv/vmbus/aarch64/vmbus_aarch64.c
  2. index 1f25037c9ae1..3f8c5c66936f 100644
  3. --- a/sys/dev/hyperv/vmbus/aarch64/vmbus_aarch64.c
  4. +++ b/sys/dev/hyperv/vmbus/aarch64/vmbus_aarch64.c
  5. @@ -116,7 +116,7 @@ vmbus_setup_intr1(struct vmbus_softc *sc)
  6.  
  7. dev = devclass_get_device(devclass_find("vmbus_res"), 0);
  8. sc->ires = bus_alloc_resource_any(dev,
  9. - SYS_RES_IRQ, &sc->vector, RF_ACTIVE | RF_SHAREABLE);
  10. + SYS_RES_IRQ, &sc->vector, RF_ACTIVE);
  11. if (sc->ires == NULL) {
  12. device_printf(sc->vmbus_dev, "bus_alloc_resouce_any failed\n");
  13. return (ENXIO);
  14. diff --git a/sys/dev/hyperv/vmbus/vmbus.c b/sys/dev/hyperv/vmbus/vmbus.c
  15. index c349f862d378..d3379c02bfb5 100644
  16. --- a/sys/dev/hyperv/vmbus/vmbus.c
  17. +++ b/sys/dev/hyperv/vmbus/vmbus.c
  18. @@ -113,7 +113,7 @@ static uint32_t vmbus_get_vcpu_id_method(device_t bus,
  19. device_t dev, int cpu);
  20. static struct taskqueue *vmbus_get_eventtq_method(device_t, device_t,
  21. int);
  22. -#if defined(EARLY_AP_STARTUP) || defined(__aarch64__)
  23. +#if defined(EARLY_AP_STARTUP) //|| defined(__aarch64__)
  24. static void vmbus_intrhook(void *);
  25. #endif
  26.  
  27. @@ -668,7 +668,7 @@ vmbus_handle_intr1(struct vmbus_softc *sc, struct trapframe *frame, int cpu)
  28. {
  29. volatile struct vmbus_message *msg;
  30. struct vmbus_message *msg_base;
  31. -
  32. + device_printf(sc->vmbus_dev,"vmbus_handle_intr1 for cpu %d\n", cpu);
  33. msg_base = VMBUS_PCPU_GET(sc, message, cpu);
  34.  
  35. /*
  36. @@ -1488,7 +1488,7 @@ vmbus_event_proc_dummy(struct vmbus_softc *sc __unused, int cpu __unused)
  37. {
  38. }
  39.  
  40. -#if defined(EARLY_AP_STARTUP) || defined(__aarch64__)
  41. +#if defined(EARLY_AP_STARTUP) //|| defined(__aarch64__)
  42.  
  43. static void
  44. vmbus_intrhook(void *xsc)
  45. @@ -1517,7 +1517,7 @@ vmbus_attach(device_t dev)
  46. */
  47. vmbus_sc->vmbus_event_proc = vmbus_event_proc_dummy;
  48.  
  49. -#if defined(EARLY_AP_STARTUP) || defined(__aarch64__)
  50. +#if defined(EARLY_AP_STARTUP) //|| defined(__aarch64__)
  51. /*
  52. * Defer the real attach until the pause(9) works as expected.
  53. */
  54. @@ -1531,8 +1531,8 @@ vmbus_attach(device_t dev)
  55. * cold set to zero, we just call the driver
  56. * initialization directly.
  57. */
  58. - if (!cold)
  59. - vmbus_doattach(vmbus_sc);
  60. +// if (!cold)
  61. +// vmbus_doattach(vmbus_sc);
  62. #endif /* EARLY_AP_STARTUP and aarch64 */
  63.  
  64. return (0);
  65. @@ -1578,7 +1578,7 @@ vmbus_detach(device_t dev)
  66. return (0);
  67. }
  68.  
  69. -#if !defined(EARLY_AP_STARTUP) && !defined(__aarch64__)
  70. +#if !defined(EARLY_AP_STARTUP) //&& !defined(__aarch64__)
  71.  
  72. static void
  73. vmbus_sysinit(void *arg __unused)
  74. @@ -1602,5 +1602,5 @@ vmbus_sysinit(void *arg __unused)
  75. * We have to start as the last step of SI_SUB_SMP, i.e. after SMP is
  76. * initialized.
  77. */
  78. -SYSINIT(vmbus_initialize, SI_SUB_SMP, SI_ORDER_ANY, vmbus_sysinit, NULL);
  79. +SYSINIT(vmbus_initialize, SI_SUB_SMP + 1, SI_ORDER_FIRST, vmbus_sysinit, NULL);
  80. #endif /* !EARLY_AP_STARTUP */
  81. diff --git a/sys/dev/hyperv/vmbus/vmbus_chan.c b/sys/dev/hyperv/vmbus/vmbus_chan.c
  82. index 032e06c47c95..a5349196cd50 100644
  83. --- a/sys/dev/hyperv/vmbus/vmbus_chan.c
  84. +++ b/sys/dev/hyperv/vmbus/vmbus_chan.c
  85. @@ -1097,7 +1097,7 @@ vmbus_chan_send(struct vmbus_channel *chan, uint16_t type, uint16_t flags,
  86. pad_pktlen = VMBUS_CHANPKT_TOTLEN(pktlen);
  87. KASSERT(pad_pktlen <= vmbus_txbr_maxpktsz(&chan->ch_txbr),
  88. ("invalid packet size %d", pad_pktlen));
  89. -
  90. + device_printf(chan->ch_dev,"chan id %d and cp %d\n",chan->ch_id, chan->ch_vcpuid);
  91. pkt.cp_hdr.cph_type = type;
  92. pkt.cp_hdr.cph_flags = flags;
  93. VMBUS_CHANPKT_SETLEN(pkt.cp_hdr.cph_hlen, hlen);
Advertisement
Add Comment
Please, Sign In to add comment