Normally, it shouldn't even allow you to add a quantity above 2 on the product page.
I think that the problem comes from the fact that you're using a characteristic and that you didn't set the max per product for each variants of the product via the "manage variants" area.
Could you try to change the line:
$checkfields = array('product_name','product_description','prices','images','discount','product_url','product_weight','product_weight_unit','product_keywords','product_meta_description','product_dimension_unit','product_width','product_length','product_height','files','product_contact');
to:
$checkfields = array('product_name','product_description','prices','images','discount','product_url','product_weight','product_weight_unit','product_keywords','product_meta_description','product_dimension_unit','product_width','product_length','product_height','files','product_contact','product_max_per_order');
in the file administrator/components/com_hikashop/classes/product.php ? That should allow the system to dynamically use the value of the main product if not set in each variants.