WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] [PATCH 6/6 V2] log level ia64 DPRINTK

To: xen-devel@xxxxxxxxxxxxxxxxxxx, Keir.Fraser@xxxxxxxxxxxx
Subject: [Xen-devel] [PATCH 6/6 V2] log level ia64 DPRINTK
From: Steven Rostedt <srostedt@xxxxxxxxxx>
Date: Fri, 27 Oct 2006 11:32:32 -0400
Delivery-date: Fri, 27 Oct 2006 08:36:22 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Thunderbird 1.5.0.4 (X11/20060614)
This patch updates the ia64 arch to have DPRINTK use the new log levels.

Signed-off-by: Steven Rostedt <srostedt@xxxxxxxxxx>
diff -r dd0add8effcf xen/arch/ia64/vmx/vlsapic.c
--- a/xen/arch/ia64/vmx/vlsapic.c       Fri Oct 27 11:11:44 2006 -0400
+++ b/xen/arch/ia64/vmx/vlsapic.c       Fri Oct 27 11:11:45 2006 -0400
@@ -410,7 +410,7 @@ void vlsapic_reset(VCPU *vcpu)
     vcpu->arch.arch_vmx.vlapic.vcpu = vcpu;
     hvm_vioapic_add_lapic(&vcpu->arch.arch_vmx.vlapic, vcpu);
 #endif
-    DPRINTK("VLSAPIC inservice base=%p\n", &VLSAPIC_INSVC(vcpu,0) );
+    DPRINTK(XENLOG_INFO "VLSAPIC inservice base=%p\n", &VLSAPIC_INSVC(vcpu,0) 
);
 }
 
 /*
@@ -539,7 +539,7 @@ int vmx_vcpu_pend_interrupt(VCPU *vcpu, 
     int ret;
 
     if (vector & ~0xff) {
-        DPRINTK("vmx_vcpu_pend_interrupt: bad vector\n");
+        DPRINTK(XENLOG_G_INFO "vmx_vcpu_pend_interrupt: bad vector\n");
         return -1;
     }
     local_irq_save(spsr);
diff -r dd0add8effcf xen/arch/ia64/vmx/vmx_hypercall.c
--- a/xen/arch/ia64/vmx/vmx_hypercall.c Fri Oct 27 11:11:44 2006 -0400
+++ b/xen/arch/ia64/vmx/vmx_hypercall.c Fri Oct 27 11:11:45 2006 -0400
@@ -79,7 +79,7 @@ do_hvm_op(unsigned long op, XEN_GUEST_HA
     }
 
     default:
-        DPRINTK("Bad HVM op %ld.\n", op);
+        DPRINTK(XENLOG_G_INFO "Bad HVM op %ld.\n", op);
         rc = -ENOSYS;
     }
     return rc;
diff -r dd0add8effcf xen/arch/ia64/vmx/vmx_init.c
--- a/xen/arch/ia64/vmx/vmx_init.c      Fri Oct 27 11:11:44 2006 -0400
+++ b/xen/arch/ia64/vmx/vmx_init.c      Fri Oct 27 11:11:45 2006 -0400
@@ -277,7 +277,7 @@ static void vmx_create_event_channels(st
                        p = get_vio(v->domain, o->vcpu_id);
                        o->arch.arch_vmx.xen_port = p->vp_eport =
                                        alloc_unbound_xen_event_channel(o, 0);
-                       DPRINTK("Allocated port %d for hvm.\n",
+                       DPRINTK(XENLOG_G_INFO "Allocated port %d for hvm.\n",
                                o->arch.arch_vmx.xen_port);
                }
        }
diff -r dd0add8effcf xen/arch/ia64/xen/dom0_ops.c
--- a/xen/arch/ia64/xen/dom0_ops.c      Fri Oct 27 11:11:44 2006 -0400
+++ b/xen/arch/ia64/xen/dom0_ops.c      Fri Oct 27 11:11:45 2006 -0400
@@ -320,7 +320,8 @@ do_dom0vp_op(unsigned long cmd,
     case IA64_DOM0VP_phystomach:
         ret = ____lookup_domain_mpa(d, arg0 << PAGE_SHIFT);
         if (ret == INVALID_MFN) {
-            DPRINTK("%s:%d INVALID_MFN ret: 0x%lx\n", __func__, __LINE__, ret);
+            DPRINTK(XENLOG_INFO "%s: INVALID_MFN ret: 0x%lx\n",
+                     __func__, ret);
         } else {
             ret = (ret & _PFN_MASK) >> PAGE_SHIFT;//XXX pte_pfn()
         }
diff -r dd0add8effcf xen/arch/ia64/xen/domain.c
--- a/xen/arch/ia64/xen/domain.c        Fri Oct 27 11:11:44 2006 -0400
+++ b/xen/arch/ia64/xen/domain.c        Fri Oct 27 11:11:45 2006 -0400
@@ -682,7 +682,8 @@ int shadow_mode_control(struct domain *d
        //struct vcpu *v;
 
        if (unlikely(d == current->domain)) {
-               DPRINTK("Don't try to do a shadow op on yourself!\n");
+               DPRINTK(XENLOG_G_INFO
+                        "Don't try to do a shadow op on yourself!\n");
                return -EINVAL;
        }   
 
diff -r dd0add8effcf xen/arch/ia64/xen/irq.c
--- a/xen/arch/ia64/xen/irq.c   Fri Oct 27 11:11:44 2006 -0400
+++ b/xen/arch/ia64/xen/irq.c   Fri Oct 27 11:11:45 2006 -0400
@@ -377,7 +377,8 @@ int pirq_guest_bind(struct vcpu *v, int 
     {
         if ( desc->action != NULL )
         {
-            DPRINTK("Cannot bind IRQ %d to guest. In use by '%s'.\n",
+            DPRINTK(XENLOG_G_INFO
+                    "Cannot bind IRQ %d to guest. In use by '%s'.\n",
                     irq, desc->action->name);
             rc = -EBUSY;
             goto out;
@@ -386,7 +387,9 @@ int pirq_guest_bind(struct vcpu *v, int 
         action = xmalloc(irq_guest_action_t);
         if ( (desc->action = (struct irqaction *)action) == NULL )
         {
-            DPRINTK("Cannot bind IRQ %d to guest. Out of memory.\n", irq);
+            DPRINTK(XENLOG_G_INFO
+                    "Cannot bind IRQ %d to guest. Out of memory.\n",
+                    irq);
             rc = -ENOMEM;
             goto out;
         }
@@ -410,7 +413,8 @@ int pirq_guest_bind(struct vcpu *v, int 
     }
     else if ( !will_share || !action->shareable )
     {
-        DPRINTK("Cannot bind IRQ %d to guest. Will not share with others.\n",
+        DPRINTK(XENLOG_G_INFO
+                "Cannot bind IRQ %d to guest. Will not share with others.\n",
                 irq);
         rc = -EBUSY;
         goto out;
@@ -418,7 +422,9 @@ int pirq_guest_bind(struct vcpu *v, int 
 
     if ( action->nr_guests == IRQ_MAX_GUESTS )
     {
-        DPRINTK("Cannot bind IRQ %d to guest. Already at max share.\n", irq);
+        DPRINTK(XENLOG_G_INFO
+                "Cannot bind IRQ %d to guest. Already at max share.\n",
+                irq);
         rc = -EBUSY;
         goto out;
     }
diff -r dd0add8effcf xen/arch/ia64/xen/mm.c
--- a/xen/arch/ia64/xen/mm.c    Fri Oct 27 11:11:44 2006 -0400
+++ b/xen/arch/ia64/xen/mm.c    Fri Oct 27 11:11:45 2006 -0400
@@ -229,7 +229,8 @@ try_to_clear_PGC_allocate(struct domain*
         if (unlikely(!(x & PGC_allocated)) || unlikely(_nd != _d)) {
             struct domain* nd = unpickle_domptr(_nd);
             if (nd == NULL) {
-                DPRINTK("gnttab_transfer: Bad page %p: ed=%p(%u) 0x%x, "
+                DPRINTK(XENLOG_G_INFO "gnttab_transfer: "
+                        "Bad page %p: ed=%p(%u) 0x%x, "
                         "sd=%p 0x%x,"
                         " caf=%016lx, taf=%" PRtype_info "\n",
                         (void *) page_to_mfn(page),
@@ -978,8 +979,8 @@ efi_mmio(unsigned long physaddr, unsigne
 
         if (start <= physaddr && physaddr < end) {
             if ((physaddr + size) > end) {
-                DPRINTK("%s:%d physaddr 0x%lx size = 0x%lx\n",
-                        __func__, __LINE__, physaddr, size);
+                DPRINTK(XENLOG_G_INFO "%s: physaddr 0x%lx size = 0x%lx\n",
+                        __func__, physaddr, size);
                 return 0;
             }
 
@@ -1013,13 +1014,13 @@ assign_domain_mmio_page(struct domain *d
                         unsigned long mpaddr, unsigned long size)
 {
     if (size == 0) {
-        DPRINTK("%s: domain %p mpaddr 0x%lx size = 0x%lx\n",
+        DPRINTK(XENLOG_G_INFO "%s: domain %p mpaddr 0x%lx size = 0x%lx\n",
                 __func__, d, mpaddr, size);
     }
     if (!efi_mmio(mpaddr, size)) {
 #ifndef NDEBUG
-        DPRINTK("%s:%d domain %p mpaddr 0x%lx size = 0x%lx\n",
-                __func__, __LINE__, d, mpaddr, size);
+        DPRINTK(XENLOG_G_INFO "%s: domain %p mpaddr 0x%lx size = 0x%lx\n",
+                __func__, d, mpaddr, size);
 #endif
         return -EINVAL;
     }
@@ -1108,7 +1109,8 @@ assign_domain_page_cmpxchg_rel(struct do
     old_mfn = page_to_mfn(old_page);
     old_pte = pfn_pte(old_mfn, __pgprot(old_prot));
     if (!pte_present(old_pte)) {
-        DPRINTK("%s: old_pte 0x%lx old_prot 0x%lx old_mfn 0x%lx\n",
+        DPRINTK(XENLOG_G_INFO
+                "%s: old_pte 0x%lx old_prot 0x%lx old_mfn 0x%lx\n",
                 __func__, pte_val(old_pte), old_prot, old_mfn);
         return -EINVAL;
     }
@@ -1124,7 +1126,8 @@ assign_domain_page_cmpxchg_rel(struct do
             goto again;
         }
 
-        DPRINTK("%s: old_pte 0x%lx old_prot 0x%lx old_mfn 0x%lx "
+        DPRINTK(XENLOG_G_INFO
+                "%s: old_pte 0x%lx old_prot 0x%lx old_mfn 0x%lx "
                 "ret_pte 0x%lx ret_mfn 0x%lx\n",
                 __func__,
                 pte_val(old_pte), old_prot, old_mfn,
@@ -1184,7 +1187,7 @@ zap_domain_page_one(struct domain *d, un
                 goto again;
             }
 
-            DPRINTK("%s: old_pte 0x%lx old_arflags 0x%lx mfn 0x%lx "
+            DPRINTK(XENLOG_G_INFO "%s: old_pte 0x%lx old_arflags 0x%lx mfn 
0x%lx "
                     "ret_pte 0x%lx ret_mfn 0x%lx\n",
                     __func__,
                     pte_val(old_pte), old_arflags, mfn,
@@ -1252,7 +1255,7 @@ dom0vp_add_physmap(struct domain* d, uns
             rd = dom_io;
             break;
         default:
-            DPRINTK("d 0x%p domid %d "
+            DPRINTK(XENLOG_G_INFO "d 0x%p domid %d "
                     "pgfn 0x%lx mfn 0x%lx flags 0x%lx domid %d\n",
                     d, d->domain_id, gpfn, mfn, flags, domid);
             return -ESRCH;
@@ -1325,14 +1328,16 @@ dom0vp_expose_p2m(struct domain* d,
         (conv_start_gpfn % granule_pfn) != 0 ||
         (assign_start_gpfn % granule_pfn) != 0 ||
         (expose_num_pfn % granule_pfn) != 0) {
-        DPRINTK("%s conv_start_gpfn 0x%016lx assign_start_gpfn 0x%016lx "
+        DPRINTK(XENLOG_G_INFO
+                "%s conv_start_gpfn 0x%016lx assign_start_gpfn 0x%016lx "
                 "expose_size 0x%016lx granulte_pfn 0x%016lx\n", __func__, 
                 conv_start_gpfn, assign_start_gpfn, expose_size, granule_pfn);
         return -EINVAL;
     }
 
     if (granule_pfn != PTRS_PER_PTE) {
-        DPRINTK("%s granule_pfn 0x%016lx PTRS_PER_PTE 0x%016lx\n",
+        DPRINTK(XENLOG_G_INFO
+                "%s granule_pfn 0x%016lx PTRS_PER_PTE 0x%016lx\n",
                 __func__, granule_pfn, PTRS_PER_PTE);
         return -ENOSYS;
     }
@@ -1350,7 +1355,7 @@ dom0vp_expose_p2m(struct domain* d,
         assign_pte = lookup_alloc_domain_pte(d, (assign_start_gpfn <<
                                              PAGE_SHIFT) + i * sizeof(pte_t));
         if (assign_pte == NULL) {
-            DPRINTK("%s failed to allocate pte page\n", __func__);
+            DPRINTK(XENLOG_G_INFO "%s failed to allocate pte page\n", 
__func__);
             return -ENOMEM;
         }
 
@@ -1371,7 +1376,7 @@ dom0vp_expose_p2m(struct domain* d,
 
         if (expose_p2m_page(d, (assign_start_gpfn << PAGE_SHIFT) +
                             i * sizeof(pte_t), virt_to_page(conv_pte)) < 0) {
-            DPRINTK("%s failed to assign page\n", __func__);
+            DPRINTK(XENLOG_G_INFO "%s failed to assign page\n", __func__);
             return -EAGAIN;
         }
 
@@ -1390,7 +1395,7 @@ dom0vp_expose_p2m(struct domain* d,
         }
         if (expose_p2m_page(d, (assign_start_gpfn + i) << PAGE_SHIFT,
                             p2m_pte_zero_page) < 0) {
-            DPRINTK("%s failed to assign zero-pte page\n", __func__);
+            DPRINTK(XENLOG_G_INFO "%s failed to assign zero-pte page\n", 
__func__);
             return -EAGAIN;
         }
     }
@@ -1413,7 +1418,7 @@ create_grant_host_mapping(unsigned long 
 
     if (flags & (GNTMAP_device_map |
                  GNTMAP_application_map | GNTMAP_contains_pte)) {
-        DPRINTK("%s: flags 0x%x\n", __func__, flags);
+        DPRINTK(XENLOG_G_INFO "%s: flags 0x%x\n", __func__, flags);
         return GNTST_general_error;
     }
 
@@ -1447,13 +1452,14 @@ destroy_grant_host_mapping(unsigned long
     struct page_info* page;
 
     if (flags & (GNTMAP_application_map | GNTMAP_contains_pte)) {
-        DPRINTK("%s: flags 0x%x\n", __func__, flags);
+        DPRINTK(XENLOG_G_INFO "%s: flags 0x%x\n", __func__, flags);
         return GNTST_general_error;
     }
 
     pte = lookup_noalloc_domain_pte(d, gpaddr);
     if (pte == NULL) {
-        DPRINTK("%s: gpaddr 0x%lx mfn 0x%lx\n", __func__, gpaddr, mfn);
+        DPRINTK(XENLOG_G_INFO "%s: gpaddr 0x%lx mfn 0x%lx\n",
+                __func__, gpaddr, mfn);
         return GNTST_general_error;
     }
 
@@ -1461,7 +1467,7 @@ destroy_grant_host_mapping(unsigned long
     cur_arflags = pte_val(*pte) & ~_PAGE_PPN_MASK;
     cur_pte = pfn_pte(mfn, __pgprot(cur_arflags));
     if (!pte_present(cur_pte)) {
-        DPRINTK("%s: gpaddr 0x%lx mfn 0x%lx cur_pte 0x%lx\n",
+        DPRINTK(XENLOG_G_INFO "%s: gpaddr 0x%lx mfn 0x%lx cur_pte 0x%lx\n",
                 __func__, gpaddr, mfn, pte_val(cur_pte));
         return GNTST_general_error;
     }
@@ -1469,7 +1475,8 @@ destroy_grant_host_mapping(unsigned long
 
     old_pte = ptep_cmpxchg_rel(&d->arch.mm, gpaddr, pte, cur_pte, new_pte);
     if (unlikely(!pte_present(old_pte))) {
-        DPRINTK("%s: gpaddr 0x%lx mfn 0x%lx cur_pte 0x%lx old_pte 0x%lx\n",
+        DPRINTK(XENLOG_G_INFO "%s: gpaddr 0x%lx mfn 0x%lx"
+                         " cur_pte 0x%lx old_pte 0x%lx\n",
                 __func__, gpaddr, mfn, pte_val(cur_pte), pte_val(old_pte));
         return GNTST_general_error;
     }
@@ -1477,7 +1484,8 @@ destroy_grant_host_mapping(unsigned long
         if (pte_pfn(old_pte) == mfn) {
             goto again;
         }
-        DPRINTK("%s gpaddr 0x%lx mfn 0x%lx cur_pte 0x%lx old_pte 0x%lx\n",
+        DPRINTK(XENLOG_G_INFO "%s gpaddr 0x%lx mfn 0x%lx cur_pte "
+                "0x%lx old_pte 0x%lx\n",
                 __func__, gpaddr, mfn, pte_val(cur_pte), pte_val(old_pte));
         return GNTST_general_error;
     }
@@ -1509,7 +1517,8 @@ steal_page(struct domain *d, struct page
     u64 x, nx, y;
 
     if (page_get_owner(page) != d) {
-        DPRINTK("%s d 0x%p owner 0x%p\n", __func__, d, page_get_owner(page));
+        DPRINTK(XENLOG_G_INFO "%s d 0x%p owner 0x%p\n",
+                __func__, d, page_get_owner(page));
         return -1;
     }
     
@@ -1521,7 +1530,7 @@ steal_page(struct domain *d, struct page
 
         new = alloc_domheap_page(d);
         if (new == NULL) {
-            DPRINTK("alloc_domheap_page() failed\n");
+            DPRINTK(XENLOG_G_INFO "alloc_domheap_page() failed\n");
             return -1;
         }
         // zero out pages for security reasons
@@ -1545,7 +1554,8 @@ steal_page(struct domain *d, struct page
         ret = assign_domain_page_cmpxchg_rel(d, gpfn << PAGE_SHIFT, page, new,
                                              ASSIGN_writable);
         if (ret < 0) {
-            DPRINTK("assign_domain_page_cmpxchg_rel failed %d\n", ret);
+            DPRINTK(XENLOG_G_INFO "assign_domain_page_cmpxchg_rel failed %d\n",
+                    ret);
             set_gpfn_from_mfn(new_mfn, INVALID_M2P_ENTRY);
             free_domheap_page(new);
             return -1;
@@ -1582,7 +1592,8 @@ steal_page(struct domain *d, struct page
             unlikely(_nd != _d)) {
             struct domain* nd = unpickle_domptr(_nd);
             if (nd == NULL) {
-                DPRINTK("gnttab_transfer: Bad page %p: ed=%p(%u) 0x%x, "
+                DPRINTK(XENLOG_G_INFO "gnttab_transfer: "
+                        "Bad page %p: ed=%p(%u) 0x%x, "
                         "sd=%p 0x%x,"
                         " caf=%016lx, taf=%" PRtype_info
                         " memflags 0x%x\n",
@@ -1593,7 +1604,8 @@ steal_page(struct domain *d, struct page
                         page->u.inuse.type_info,
                         memflags);
             } else {
-                DPRINTK("gnttab_transfer: Bad page %p: ed=%p(%u) 0x%x, "
+                DPRINTK(XENLOG_G_WARNING "gnttab_transfer: "
+                        "Bad page %p: ed=%p(%u) 0x%x, "
                         "sd=%p(%u) 0x%x,"
                         " caf=%016lx, taf=%" PRtype_info
                         " memflags 0x%x\n",
@@ -1683,11 +1695,11 @@ domain_page_flush(struct domain* d, unsi
         tlb_track_free_entry(d->arch.tlb_track, entry);
         break;
     case TLB_TRACK_MANY:
-        DPRINTK("%s TLB_TRACK_MANY\n", __func__);
+        DPRINTK(XENLOG_G_INFO "%s TLB_TRACK_MANY\n", __func__);
         domain_flush_vtlb_all();
         break;
     case TLB_TRACK_AGAIN:
-        DPRINTK("%s TLB_TRACK_AGAIN\n", __func__);
+        DPRINTK(XENLOG_G_ERR "%s TLB_TRACK_AGAIN\n", __func__);
         BUG();
         break;
     }
diff -r dd0add8effcf xen/arch/ia64/xen/vcpu.c
--- a/xen/arch/ia64/xen/vcpu.c  Fri Oct 27 11:11:44 2006 -0400
+++ b/xen/arch/ia64/xen/vcpu.c  Fri Oct 27 11:11:45 2006 -0400
@@ -1571,7 +1571,7 @@ vcpu_get_domain_bundle(VCPU * vcpu, REGS
                        set_metaphysical_rr0();
                }
                if (bundle->i64[0] == 0 && bundle->i64[1] == 0) {
-                       DPRINTK("%s gip 0x%lx\n", __func__, gip);
+                       DPRINTK(XENLOG_INFO "%s gip 0x%lx\n", __func__, gip);
                        return 0;
                }
                return 1;
diff -r dd0add8effcf xen/include/asm-ia64/mm.h
--- a/xen/include/asm-ia64/mm.h Fri Oct 27 11:11:44 2006 -0400
+++ b/xen/include/asm-ia64/mm.h Fri Oct 27 11:11:45 2006 -0400
@@ -175,7 +175,7 @@ static inline int get_page(struct page_i
            unlikely((nx & PGC_count_mask) == 0) ||     /* Count overflow? */
            unlikely((x >> 32) != _domain)) {           /* Wrong owner? */
 
-           DPRINTK("Error pfn %lx: rd=%p, od=%p, caf=%016lx, taf=%"
+           DPRINTK(XENLOG_G_INFO "Error pfn %lx: rd=%p, od=%p, caf=%016lx, 
taf=%"
                PRtype_info "\n", page_to_mfn(page), domain,
                unpickle_domptr(x >> 32), x, page->u.inuse.type_info);
            return 0;
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [PATCH 6/6 V2] log level ia64 DPRINTK, Steven Rostedt <=