static int tegra_smmu_add_device(struct device *dev)
 {
        struct device_node *np = dev->of_node;
+       struct iommu_group *group;
        struct of_phandle_args args;
        unsigned int index = 0;
 
                index++;
        }
 
+       group = iommu_group_get_for_dev(dev);
+       if (IS_ERR(group))
+               return PTR_ERR(group);
+
+       iommu_group_put(group);
+
        return 0;
 }
 
 static void tegra_smmu_remove_device(struct device *dev)
 {
        dev->archdata.iommu = NULL;
+       iommu_group_remove_device(dev);
 }
 
 static const struct iommu_ops tegra_smmu_ops = {
        .detach_dev = tegra_smmu_detach_dev,
        .add_device = tegra_smmu_add_device,
        .remove_device = tegra_smmu_remove_device,
+       .device_group = generic_device_group,
        .map = tegra_smmu_map,
        .unmap = tegra_smmu_unmap,
        .map_sg = default_iommu_map_sg,